summaryrefslogtreecommitdiffstats
path: root/llvm/test/CodeGen
diff options
context:
space:
mode:
authorPeter Collingbourne <peter@pcc.me.uk>2018-05-21 20:16:41 +0000
committerPeter Collingbourne <peter@pcc.me.uk>2018-05-21 20:16:41 +0000
commit9a45114b3cf80a2ffc6b86275da82d3ed91e081b (patch)
treeb8bb197005a82e83c2073d3f058eefd7a401a8ba /llvm/test/CodeGen
parent9b2df56c596b4929938c44e0eb3c54d89d2ba466 (diff)
downloadbcm5719-llvm-9a45114b3cf80a2ffc6b86275da82d3ed91e081b.tar.gz
bcm5719-llvm-9a45114b3cf80a2ffc6b86275da82d3ed91e081b.zip
CodeGen: Add a dwo output file argument to addPassesToEmitFile and hook it up to dwo output.
Part of PR37466. Differential Revision: https://reviews.llvm.org/D47089 llvm-svn: 332881
Diffstat (limited to 'llvm/test/CodeGen')
-rw-r--r--llvm/test/CodeGen/X86/dwarf-headers.ll48
-rw-r--r--llvm/test/CodeGen/X86/dwarf-split-line-1.ll7
-rw-r--r--llvm/test/CodeGen/X86/dwarf-split-line-2.ll7
3 files changed, 34 insertions, 28 deletions
diff --git a/llvm/test/CodeGen/X86/dwarf-headers.ll b/llvm/test/CodeGen/X86/dwarf-headers.ll
index 9aacaca9c76..f30e826a9c1 100644
--- a/llvm/test/CodeGen/X86/dwarf-headers.ll
+++ b/llvm/test/CodeGen/X86/dwarf-headers.ll
@@ -2,17 +2,21 @@
; RUN: -filetype=obj -O0 -mtriple=x86_64-unknown-linux-gnu < %s \
; RUN: | llvm-dwarfdump -v - | FileCheck %s --check-prefix=SINGLE-4
-; RUN: llc -split-dwarf-file=foo.dwo -dwarf-version=4 -generate-type-units \
+; RUN: llc -split-dwarf-file=foo.dwo -split-dwarf-output=%t.dwo \
+; RUN: -dwarf-version=4 -generate-type-units \
; RUN: -filetype=obj -O0 -mtriple=x86_64-unknown-linux-gnu < %s \
-; RUN: | llvm-dwarfdump -v - | FileCheck %s --check-prefix=SPLIT-4
+; RUN: | llvm-dwarfdump -v - | FileCheck %s --check-prefix=O-4
+; RUN: llvm-dwarfdump -v %t.dwo | FileCheck %s --check-prefix=DWO-4
; RUN: llc -dwarf-version=5 -generate-type-units \
; RUN: -filetype=obj -O0 -mtriple=x86_64-unknown-linux-gnu < %s \
; RUN: | llvm-dwarfdump -v - | FileCheck %s --check-prefix=SINGLE-5
-; RUN: llc -split-dwarf-file=foo.dwo -dwarf-version=5 -generate-type-units \
+; RUN: llc -split-dwarf-file=foo.dwo -split-dwarf-output=%t.dwo \
+; RUN: -dwarf-version=5 -generate-type-units \
; RUN: -filetype=obj -O0 -mtriple=x86_64-unknown-linux-gnu < %s \
-; RUN: | llvm-dwarfdump -v - | FileCheck %s --check-prefix=SPLIT-5
+; RUN: | llvm-dwarfdump -v - | FileCheck %s --check-prefix=O-5
+; RUN: llvm-dwarfdump -v %t.dwo | FileCheck %s --check-prefix=DWO-5
; Looking for DWARF headers to be generated correctly.
; There are 7 variants: v4 CU, v4 TU, v5 (normal/skeleton/split) CU,
@@ -42,17 +46,17 @@
; Verify the v4 split headers.
;
-; SPLIT-4: .debug_info contents:
-; SPLIT-4: 0x00000000: Compile Unit: {{.*}} version = 0x0004 abbr_offset
-; SPLIT-4: 0x0000000b: DW_TAG_compile_unit
+; O-4: .debug_info contents:
+; O-4: 0x00000000: Compile Unit: {{.*}} version = 0x0004 abbr_offset
+; O-4: 0x0000000b: DW_TAG_compile_unit
;
-; SPLIT-4: .debug_info.dwo contents:
-; SPLIT-4: 0x00000000: Compile Unit: {{.*}} version = 0x0004 abbr_offset
-; SPLIT-4: 0x0000000b: DW_TAG_compile_unit
+; DWO-4: .debug_info.dwo contents:
+; DWO-4: 0x00000000: Compile Unit: {{.*}} version = 0x0004 abbr_offset
+; DWO-4: 0x0000000b: DW_TAG_compile_unit
;
-; SPLIT-4: .debug_types.dwo contents:
-; SPLIT-4: 0x00000000: Type Unit: {{.*}} version = 0x0004 abbr_offset
-; SPLIT-4: 0x00000017: DW_TAG_type_unit
+; DWO-4: .debug_types.dwo contents:
+; DWO-4: 0x00000000: Type Unit: {{.*}} version = 0x0004 abbr_offset
+; DWO-4: 0x00000017: DW_TAG_type_unit
; Verify the v5 non-split headers.
;
@@ -67,18 +71,18 @@
; Verify the v5 split headers.
;
-; SPLIT-5: .debug_info contents:
-; SPLIT-5: 0x00000000: Compile Unit: {{.*}} version = 0x0005 unit_type = DW_UT_skeleton abbr_offset
-; SPLIT-5: 0x0000000c: DW_TAG_compile_unit
+; O-5: .debug_info contents:
+; O-5: 0x00000000: Compile Unit: {{.*}} version = 0x0005 unit_type = DW_UT_skeleton abbr_offset
+; O-5: 0x0000000c: DW_TAG_compile_unit
;
-; SPLIT-5: .debug_info.dwo contents:
-; SPLIT-5: 0x00000000: Compile Unit: {{.*}} version = 0x0005 unit_type = DW_UT_split_compile abbr_offset
-; SPLIT-5: 0x0000000c: DW_TAG_compile_unit
+; DWO-5: .debug_info.dwo contents:
+; DWO-5: 0x00000000: Compile Unit: {{.*}} version = 0x0005 unit_type = DW_UT_split_compile abbr_offset
+; DWO-5: 0x0000000c: DW_TAG_compile_unit
;
; FIXME: V5 wants type units in .debug_info.dwo not .debug_types.dwo.
-; SPLIT-5: .debug_types.dwo contents:
-; SPLIT-5: 0x00000000: Type Unit: {{.*}} version = 0x0005 unit_type = DW_UT_split_type abbr_offset
-; SPLIT-5: 0x00000018: DW_TAG_type_unit
+; DWO-5: .debug_types.dwo contents:
+; DWO-5: 0x00000000: Type Unit: {{.*}} version = 0x0005 unit_type = DW_UT_split_type abbr_offset
+; DWO-5: 0x00000018: DW_TAG_type_unit
; ModuleID = 't.cpp'
diff --git a/llvm/test/CodeGen/X86/dwarf-split-line-1.ll b/llvm/test/CodeGen/X86/dwarf-split-line-1.ll
index 9bc74c5c943..6a403668d73 100644
--- a/llvm/test/CodeGen/X86/dwarf-split-line-1.ll
+++ b/llvm/test/CodeGen/X86/dwarf-split-line-1.ll
@@ -1,9 +1,10 @@
; Verify that split type units with no source locations don't have a
; DW_AT_stmt_list attribute, and the .debug_line.dwo section is suppressed.
-; RUN: llc -split-dwarf-file=foo.dwo -dwarf-version=5 -generate-type-units \
-; RUN: -filetype=obj -O0 -mtriple=x86_64-unknown-linux-gnu < %s \
-; RUN: | llvm-dwarfdump -v - | FileCheck %s
+; RUN: llc -split-dwarf-file=foo.dwo -split-dwarf-output=%t.dwo \
+; RUN: -dwarf-version=5 -generate-type-units \
+; RUN: -filetype=obj -O0 -mtriple=x86_64-unknown-linux-gnu < %s
+; RUN: llvm-dwarfdump -v %t.dwo | FileCheck %s
; FIXME: V5 wants type units in .debug_info.dwo not .debug_types.dwo.
; CHECK-NOT: .debug_line.dwo
diff --git a/llvm/test/CodeGen/X86/dwarf-split-line-2.ll b/llvm/test/CodeGen/X86/dwarf-split-line-2.ll
index 1124b30d5b6..3cdad4ddac8 100644
--- a/llvm/test/CodeGen/X86/dwarf-split-line-2.ll
+++ b/llvm/test/CodeGen/X86/dwarf-split-line-2.ll
@@ -2,9 +2,10 @@
; one without, the one without locations doesn't have a DW_AT_stmt_list
; attribute, but the other one does and the .debug_line.dwo section is present.
-; RUN: llc -split-dwarf-file=foo.dwo -dwarf-version=5 -generate-type-units \
-; RUN: -filetype=obj -O0 -mtriple=x86_64-unknown-linux-gnu < %s \
-; RUN: | llvm-dwarfdump -v - | FileCheck %s
+; RUN: llc -split-dwarf-file=foo.dwo -split-dwarf-output=%t.dwo \
+; RUN: -dwarf-version=5 -generate-type-units \
+; RUN: -filetype=obj -O0 -mtriple=x86_64-unknown-linux-gnu < %s
+; RUN: llvm-dwarfdump -v %t.dwo | FileCheck %s
; Currently the no-source-location type comes out first.
; FIXME: V5 wants type units in .debug_info.dwo not .debug_types.dwo.
OpenPOWER on IntegriCloud