Emit pubtypes only when going for darwin gdb compatibility.
authorEric Christopher <echristo@apple.com>
Thu, 23 Aug 2012 07:10:56 +0000 (07:10 +0000)
committerEric Christopher <echristo@apple.com>
Thu, 23 Aug 2012 07:10:56 +0000 (07:10 +0000)
rdar://10393214

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@162434 91177308-0d34-0410-b5e6-96231b3b80d8

lib/CodeGen/AsmPrinter/DwarfDebug.cpp
test/DebugInfo/2010-04-13-PubType.ll

index 02d86c7ad25d7c13366be6fe81a550b5a368dea8..944c2027ee4489039b7e1aa692284ce6be3b313e 100644 (file)
@@ -832,7 +832,10 @@ void DwarfDebug::endModule() {
   }
   
   // Emit info into a debug pubtypes section.
-  emitDebugPubTypes();
+  // TODO: When we don't need the option anymore we can
+  // remove all of the code that adds to the table.
+  if (DarwinGDBCompat)
+    emitDebugPubTypes();
 
   // Emit info into a debug loc section.
   emitDebugLoc();
index 19bfae4113a5fb9fdd3b02cd01d9bf3a49e285b1..58488e6e9a51ed5ad3fa12f925185f391853737b 100644 (file)
@@ -1,4 +1,4 @@
-; RUN: llc -O0 -asm-verbose < %s | FileCheck %s
+; RUN: llc -O0 -asm-verbose -darwin-gdb-compat < %s | FileCheck %s
 ; CHECK-NOT: .asciz "X" ## External Name
 ; CHECK: .asciz "Y" ## External Name
 ; Test to check type with no definition is listed in pubtypes section.