Use DW_FORM_addr for DW_AT_entry_pc.
[oota-llvm.git] / lib / CodeGen / AsmPrinter / DwarfDebug.cpp
index 9ff929f0b1716fdf64b9a790ce74b254a23b0d8b..2a25cb910100b3d773ecb131b74a9b058e2cbdad 100644 (file)
@@ -1792,7 +1792,7 @@ void DwarfDebug::constructCompileUnit(const MDNode *N) {
   addString(Die, dwarf::DW_AT_name, dwarf::DW_FORM_string, FN);
   // Use DW_AT_entry_pc instead of DW_AT_low_pc/DW_AT_high_pc pair. This
   // simplifies debug range entries.
-  addUInt(Die, dwarf::DW_AT_entry_pc, dwarf::DW_FORM_data4, 0);
+  addUInt(Die, dwarf::DW_AT_entry_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. It is always zero when only one
   // compile unit is emitted in one object file.