diff options
author | Sander de Smalen <sander.desmalen@arm.com> | 2018-09-05 08:59:50 +0000 |
---|---|---|
committer | Sander de Smalen <sander.desmalen@arm.com> | 2018-09-05 08:59:50 +0000 |
commit | c91b27d9ee6e3bc49525532680dd636f1d5a1eed (patch) | |
tree | 0e4b8c03217e0279369c309f26d80cd468b82c17 /llvm/lib/CodeGen/LiveDebugValues.cpp | |
parent | 445bdd171ff4268157256923a1f143ec959d9366 (diff) | |
download | llvm-c91b27d9ee6e3bc49525532680dd636f1d5a1eed.zip llvm-c91b27d9ee6e3bc49525532680dd636f1d5a1eed.tar.gz llvm-c91b27d9ee6e3bc49525532680dd636f1d5a1eed.tar.bz2 |
Remove FrameAccess struct from hasLoadFromStackSlot
This removes the FrameAccess struct that was added to the interface
in D51537, since the PseudoValue from the MachineMemoryOperand
can be safely casted to a FixedStackPseudoSourceValue.
Reviewers: MatzeB, thegameg, javed.absar
Reviewed By: thegameg
Differential Revision: https://reviews.llvm.org/D51617
llvm-svn: 341454
Diffstat (limited to 'llvm/lib/CodeGen/LiveDebugValues.cpp')
-rw-r--r-- | llvm/lib/CodeGen/LiveDebugValues.cpp | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/llvm/lib/CodeGen/LiveDebugValues.cpp b/llvm/lib/CodeGen/LiveDebugValues.cpp index 00f5872..fa2cb27 100644 --- a/llvm/lib/CodeGen/LiveDebugValues.cpp +++ b/llvm/lib/CodeGen/LiveDebugValues.cpp @@ -470,7 +470,7 @@ bool LiveDebugValues::isSpillInstruction(const MachineInstr &MI, MachineFunction *MF, unsigned &Reg) { const MachineFrameInfo &FrameInfo = MF->getFrameInfo(); int FI; - SmallVector<TargetInstrInfo::FrameAccess, 1> Accesses; + SmallVector<const MachineMemOperand*, 1> Accesses; // TODO: Handle multiple stores folded into one. if (!MI.hasOneMemOperand()) @@ -480,8 +480,10 @@ bool LiveDebugValues::isSpillInstruction(const MachineInstr &MI, if (!((TII->isStoreToStackSlotPostFE(MI, FI) && FrameInfo.isSpillSlotObjectIndex(FI)) || (TII->hasStoreToStackSlot(MI, Accesses) && - llvm::any_of(Accesses, [&FrameInfo](TargetInstrInfo::FrameAccess &FA) { - return FrameInfo.isSpillSlotObjectIndex(FA.FI); + llvm::any_of(Accesses, [&FrameInfo](const MachineMemOperand *MMO) { + return FrameInfo.isSpillSlotObjectIndex( + cast<FixedStackPseudoSourceValue>(MMO->getPseudoValue()) + ->getFrameIndex()); })))) return false; |