diff options
Diffstat (limited to 'llvm/lib/CodeGen/AsmPrinter')
| -rw-r--r-- | llvm/lib/CodeGen/AsmPrinter/AsmPrinterDwarf.cpp | 71 | 
1 files changed, 0 insertions, 71 deletions
| diff --git a/llvm/lib/CodeGen/AsmPrinter/AsmPrinterDwarf.cpp b/llvm/lib/CodeGen/AsmPrinter/AsmPrinterDwarf.cpp index 6d1708a2ce8..0e9fc261c60 100644 --- a/llvm/lib/CodeGen/AsmPrinter/AsmPrinterDwarf.cpp +++ b/llvm/lib/CodeGen/AsmPrinter/AsmPrinterDwarf.cpp @@ -206,77 +206,6 @@ void AsmPrinter::EmitSectionOffset(const MCSymbol *Label,  // Dwarf Lowering Routines  //===----------------------------------------------------------------------===// - -/// EmitFrameMoves - Emit frame instructions to describe the layout of the -/// frame. -void AsmPrinter::EmitFrameMoves(const std::vector<MachineMove> &Moves, -                                MCSymbol *BaseLabel, bool isEH) const { -  const TargetRegisterInfo *RI = TM.getRegisterInfo(); -   -  int stackGrowth = TM.getTargetData()->getPointerSize(); -  if (TM.getFrameLowering()->getStackGrowthDirection() != -      TargetFrameLowering::StackGrowsUp) -    stackGrowth *= -1; -   -  for (unsigned i = 0, N = Moves.size(); i < N; ++i) { -    const MachineMove &Move = Moves[i]; -    MCSymbol *Label = Move.getLabel(); -    // Throw out move if the label is invalid. -    if (Label && !Label->isDefined()) continue; // Not emitted, in dead code. -     -    const MachineLocation &Dst = Move.getDestination(); -    const MachineLocation &Src = Move.getSource(); -     -    // Advance row if new location. -    if (BaseLabel && Label) { -      MCSymbol *ThisSym = Label; -      if (ThisSym != BaseLabel) { -        EmitCFAByte(dwarf::DW_CFA_advance_loc4); -        EmitLabelDifference(ThisSym, BaseLabel, 4); -        BaseLabel = ThisSym; -      } -    } -     -    // If advancing cfa. -    if (Dst.isReg() && Dst.getReg() == MachineLocation::VirtualFP) { -      assert(!Src.isReg() && "Machine move not supported yet."); -       -      if (Src.getReg() == MachineLocation::VirtualFP) { -        EmitCFAByte(dwarf::DW_CFA_def_cfa_offset); -      } else { -        EmitCFAByte(dwarf::DW_CFA_def_cfa); -        EmitULEB128(RI->getDwarfRegNum(Src.getReg(), isEH), "Register"); -      } -       -      EmitULEB128(-Src.getOffset(), "Offset"); -      continue; -    } -     -    if (Src.isReg() && Src.getReg() == MachineLocation::VirtualFP) { -      assert(Dst.isReg() && "Machine move not supported yet."); -      EmitCFAByte(dwarf::DW_CFA_def_cfa_register); -      EmitULEB128(RI->getDwarfRegNum(Dst.getReg(), isEH), "Register"); -      continue; -    } -     -    unsigned Reg = RI->getDwarfRegNum(Src.getReg(), isEH); -    int Offset = Dst.getOffset() / stackGrowth; -     -    if (Offset < 0) { -      EmitCFAByte(dwarf::DW_CFA_offset_extended_sf); -      EmitULEB128(Reg, "Reg"); -      EmitSLEB128(Offset, "Offset"); -    } else if (Reg < 64) { -      EmitCFAByte(dwarf::DW_CFA_offset + Reg); -      EmitULEB128(Offset, "Offset"); -    } else { -      EmitCFAByte(dwarf::DW_CFA_offset_extended); -      EmitULEB128(Reg, "Reg"); -      EmitULEB128(Offset, "Offset"); -    } -  } -} -  /// EmitFrameMoves - Emit a frame instruction.  void AsmPrinter::EmitCFIFrameMove(const MachineMove &Move) const {    const TargetRegisterInfo *RI = TM.getRegisterInfo(); | 

