Add more external types to the pubtypes table. Expand the asm
authorEric Christopher <echristo@gmail.com>
Mon, 23 Sep 2013 23:15:58 +0000 (23:15 +0000)
committerEric Christopher <echristo@gmail.com>
Mon, 23 Sep 2013 23:15:58 +0000 (23:15 +0000)
checking patch until we get full dumping support.

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

lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp
test/DebugInfo/X86/gnu-public-names.ll

index 171c13803c1db4e086b575d00d93707bfed1736b..7d35937ccafbb95c129cfcbcd239a19f9a22cfd4 100644 (file)
@@ -880,7 +880,7 @@ void CompileUnit::addGlobalName(StringRef Name, DIE *Die) {
 ///
 void CompileUnit::addGlobalType(DIType Ty) {
   DIDescriptor Context = DD->resolve(Ty.getContext());
-  if (Ty.isCompositeType() && !Ty.getName().empty() && !Ty.isForwardDecl() &&
+  if (!Ty.getName().empty() && !Ty.isForwardDecl() &&
       (!Context || Context.isCompileUnit() || Context.isFile() ||
        Context.isNameSpace()))
     if (DIEEntry *Entry = getDIEEntry(Ty))
index 54320be7e78aa663ed191ac3e297dc476e66cd5e..bca78c39f087bf0fb89ee588853e2b896f50ad77 100644 (file)
@@ -38,6 +38,9 @@
 
 ; ASM: .section        .debug_gnu_pubtypes
 ; ASM: .byte   16                      # Kind: TYPE, EXTERNAL
+; ASM: .asciz  "C"                     # External Name
+; ASM: .byte   144                     # Kind: TYPE, STATIC
+; ASM: .asciz  "int"                   # External Name
 
 ; CHECK: .debug_info contents:
 ; CHECK: 0x00000046: DW_TAG_subprogram