http://llvm.org/bugs/show_bug.cgi?id=21761
Bug ID: 21761
Summary: Strange code in DwarfUnit::addRegisterOffset
Product: new-bugs
Version: trunk
Hardware: PC
OS: Linux
Status: NEW
Severity: normal
Priority: P
Component: new bugs
Assignee: [email protected]
Reporter: [email protected]
CC: [email protected]
Classification: Unclassified
DwarfUnit::addRegisterOffset in lib/CodeGen/AsmPrinter/DwarfUnit.cpp has
/// addRegisterOffset - Add register offset.
bool DwarfUnit::addRegisterOffset(DIELoc &TheDie, unsigned Reg,
int64_t Offset) {
const TargetRegisterInfo *RI = Asm->TM.getSubtargetImpl()->getRegisterInfo();
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
int DWReg = RI->getDwarfRegNum(Reg, false);
if (DWReg < 0)
return false;
const TargetRegisterInfo *TRI =
Asm->TM.getSubtargetImpl()->getRegisterInfo();
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
if (Reg == TRI->getFrameRegister(*Asm->MF))
What is the purpose to have RI and TRI. Aren't they the same?
--
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
LLVMbugs mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/llvmbugs