[PATCH] D37725: Remove -generate-dwarf-pub-sections flag.
Peter Collingbourne via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Sep 11 17:05:38 PDT 2017
pcc created this revision.
Herald added subscribers: JDevlieghere, hiraditya.
This flag is unnecessary for testing because we can get the coverage
we need by adjusting CU attributes.
Depends on https://reviews.llvm.org/D37655
https://reviews.llvm.org/D37725
Files:
llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp
llvm/test/DebugInfo/Generic/dwarf-public-names.ll
llvm/test/DebugInfo/X86/2010-04-13-PubType.ll
llvm/test/DebugInfo/X86/c-type-units.ll
llvm/test/DebugInfo/X86/gnu-public-names-gmlt.ll
Index: llvm/test/DebugInfo/X86/gnu-public-names-gmlt.ll
===================================================================
--- llvm/test/DebugInfo/X86/gnu-public-names-gmlt.ll
+++ llvm/test/DebugInfo/X86/gnu-public-names-gmlt.ll
@@ -1,5 +1,5 @@
; RUN: sed -e 's/gnuPubnames: false/gnuPubnames: true/' %s | llc -mtriple=x86_64-pc-linux-gnu -filetype=obj | llvm-dwarfdump - | FileCheck --check-prefix=GPUB --check-prefix=CHECK %s
-; RUN: llc -mtriple=x86_64-pc-linux-gnu -filetype=obj < %s -generate-dwarf-pub-sections=Enable | llvm-dwarfdump - | FileCheck --check-prefix=PUB --check-prefix=CHECK %s
+; RUN: sed -e 's/emissionKind: LineTablesOnly/emissionKind: FullDebug/' %s | llc -mtriple=x86_64-pc-linux-gnu -filetype=obj | llvm-dwarfdump - | FileCheck --check-prefix=PUB --check-prefix=CHECK %s
; RUN: llc -mtriple=x86_64-pc-linux-gnu -filetype=obj < %s | llvm-dwarfdump - | FileCheck --check-prefix=NONE %s
; Generated from:
Index: llvm/test/DebugInfo/X86/c-type-units.ll
===================================================================
--- llvm/test/DebugInfo/X86/c-type-units.ll
+++ llvm/test/DebugInfo/X86/c-type-units.ll
@@ -1,6 +1,6 @@
; REQUIRES: object-emission
-; RUN: llc -o - %s -filetype=obj -O0 -generate-dwarf-pub-sections=Disable -generate-type-units -mtriple=x86_64-unknown-linux-gnu | llvm-dwarfdump -debug-dump=types - | FileCheck %s
+; RUN: llc -o - %s -filetype=obj -O0 -debugger-tune=lldb -generate-type-units -mtriple=x86_64-unknown-linux-gnu | llvm-dwarfdump -debug-dump=types - | FileCheck %s
; struct foo {
; } f;
Index: llvm/test/DebugInfo/X86/2010-04-13-PubType.ll
===================================================================
--- llvm/test/DebugInfo/X86/2010-04-13-PubType.ll
+++ llvm/test/DebugInfo/X86/2010-04-13-PubType.ll
@@ -1,4 +1,4 @@
-; RUN: llc -O0 -asm-verbose -mtriple=x86_64-macosx -generate-dwarf-pub-sections=Enable < %s | FileCheck %s
+; RUN: llc -O0 -asm-verbose -mtriple=x86_64-macosx -debugger-tune=gdb < %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.
Index: llvm/test/DebugInfo/Generic/dwarf-public-names.ll
===================================================================
--- llvm/test/DebugInfo/Generic/dwarf-public-names.ll
+++ llvm/test/DebugInfo/Generic/dwarf-public-names.ll
@@ -1,6 +1,6 @@
; REQUIRES: object-emission
-; RUN: %llc_dwarf -generate-dwarf-pub-sections=Enable -filetype=obj -o %t.o < %s
+; RUN: %llc_dwarf -debugger-tune=gdb -filetype=obj -o %t.o < %s
; RUN: llvm-dwarfdump -debug-dump=pubnames %t.o | FileCheck %s
; ModuleID = 'dwarf-public-names.cpp'
;
Index: llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp
===================================================================
--- llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp
+++ llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp
@@ -52,16 +52,6 @@
using namespace llvm;
-enum DefaultOnOff { Default, Enable, Disable };
-
-static cl::opt<DefaultOnOff>
-DwarfPubSections("generate-dwarf-pub-sections", cl::Hidden,
- cl::desc("Generate DWARF pubnames and pubtypes sections"),
- cl::values(clEnumVal(Default, "Default for platform"),
- clEnumVal(Enable, "Enabled"),
- clEnumVal(Disable, "Disabled")),
- cl::init(Default));
-
DwarfCompileUnit::DwarfCompileUnit(unsigned UID, const DICompileUnit *Node,
AsmPrinter *A, DwarfDebug *DW,
DwarfFile *DWU)
@@ -771,10 +761,7 @@
if (CUNode->getGnuPubnames())
return true;
- if (DwarfPubSections == Default)
- return DD->tuneForGDB() && !includeMinimalInlineScopes();
-
- return DwarfPubSections == Enable;
+ return DD->tuneForGDB() && !includeMinimalInlineScopes();
}
/// addGlobalName - Add a new global name to the compile unit.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D37725.114739.patch
Type: text/x-patch
Size: 3946 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20170912/10de07a8/attachment.bin>
More information about the llvm-commits
mailing list