diff options
author | Richard Osborne <richard@xmos.com> | 2011-10-11 12:55:35 +0000 |
---|---|---|
committer | Richard Osborne <richard@xmos.com> | 2011-10-11 12:55:35 +0000 |
commit | 6c6f28ffe42d06655f5977bd0d01214e32de93a5 (patch) | |
tree | d69ae8ddeca4984a4d9bcd45b7f97377a76d5d1d /lib/Target/XCore/XCoreInstrInfo.cpp | |
parent | 56354d48bb937cbb23736d24d9ca4d7a0fcc97e0 (diff) |
Implement the emitFrameIndexDebugValue and getDebugValueLocation hooks.
This fixes an assert due to the operands of the DBG_VALUE instruction not
being as expected (PR11105).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@141666 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Target/XCore/XCoreInstrInfo.cpp')
-rw-r--r-- | lib/Target/XCore/XCoreInstrInfo.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/lib/Target/XCore/XCoreInstrInfo.cpp b/lib/Target/XCore/XCoreInstrInfo.cpp index 018d217203..a0946a197a 100644 --- a/lib/Target/XCore/XCoreInstrInfo.cpp +++ b/lib/Target/XCore/XCoreInstrInfo.cpp @@ -386,6 +386,15 @@ void XCoreInstrInfo::loadRegFromStackSlot(MachineBasicBlock &MBB, .addImm(0); } +MachineInstr* +XCoreInstrInfo::emitFrameIndexDebugValue(MachineFunction &MF, int FrameIx, + uint64_t Offset, const MDNode *MDPtr, + DebugLoc DL) const { + MachineInstrBuilder MIB = BuildMI(MF, DL, get(XCore::DBG_VALUE)) + .addFrameIndex(FrameIx).addImm(0).addImm(Offset).addMetadata(MDPtr); + return &*MIB; +} + /// ReverseBranchCondition - Return the inverse opcode of the /// specified Branch instruction. bool XCoreInstrInfo:: |