aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEric Christopher <echristo@apple.com>2012-03-27 18:35:54 +0000
committerEric Christopher <echristo@apple.com>2012-03-27 18:35:54 +0000
commit7f316597cfaf3e8cacf2626559b1aab310f4cb98 (patch)
treed15b0cc40fb312a55486c5696e63d55e75b2d102
parentd23a64cc164529739adaedb397e6279269f78efb (diff)
downloadexternal_llvm-7f316597cfaf3e8cacf2626559b1aab310f4cb98.zip
external_llvm-7f316597cfaf3e8cacf2626559b1aab310f4cb98.tar.gz
external_llvm-7f316597cfaf3e8cacf2626559b1aab310f4cb98.tar.bz2
Use DW_AT_low_pc for a single entry point into a routine.
Fixes PR10105 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@153524 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r--lib/CodeGen/AsmPrinter/DwarfDebug.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/CodeGen/AsmPrinter/DwarfDebug.cpp b/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
index 84fc564..6f15bfe 100644
--- a/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
+++ b/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
@@ -555,9 +555,9 @@ CompileUnit *DwarfDebug::constructCompileUnit(const MDNode *N) {
NewCU->addUInt(Die, dwarf::DW_AT_language, dwarf::DW_FORM_data2,
DIUnit.getLanguage());
NewCU->addString(Die, dwarf::DW_AT_name, FN);
- // Use DW_AT_entry_pc instead of DW_AT_low_pc/DW_AT_high_pc pair. This
- // simplifies debug range entries.
- NewCU->addUInt(Die, dwarf::DW_AT_entry_pc, dwarf::DW_FORM_addr, 0);
+ // 2.17.1 requires that we use DW_AT_low_pc for a single entry point
+ // into an entity.
+ NewCU->addUInt(Die, dwarf::DW_AT_low_pc, dwarf::DW_FORM_addr, 0);
// DW_AT_stmt_list is a offset of line number information for this
// compile unit in debug_line section.
if (Asm->MAI->doesDwarfRequireRelocationForSectionOffset())