forked from OSchip/llvm-project
[tests] Make 'object-emission' imply 'default_triple'
If 'config.target_triple' is empty, there is no sense to define the 'object-emission' tag. Differential Revision: https://reviews.llvm.org/D121994
This commit is contained in:
parent
d7681d9f77
commit
568404e897
|
@ -1,6 +1,6 @@
|
||||||
; RUN: %llc_dwarf %s -filetype=obj -o %t
|
; RUN: %llc_dwarf %s -filetype=obj -o %t
|
||||||
; RUN: llvm-dwarfdump -debug-info %t | FileCheck %s
|
; RUN: llvm-dwarfdump -debug-info %t | FileCheck %s
|
||||||
; REQUIRES: default_triple, object-emission
|
; REQUIRES: object-emission
|
||||||
|
|
||||||
; Reduced test case from PR35212. Two DISubprogram belong to a different CU but
|
; Reduced test case from PR35212. Two DISubprogram belong to a different CU but
|
||||||
; share a scope. Both are declarations and end up in the scope's CU. We want to
|
; share a scope. Both are declarations and end up in the scope's CU. We want to
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
; On powerpc llvm-nm describes win_func as a global variable, not a function. It breaks the test.
|
; On powerpc llvm-nm describes win_func as a global variable, not a function. It breaks the test.
|
||||||
; It is not essential to DWARF path handling code we're testing here.
|
; It is not essential to DWARF path handling code we're testing here.
|
||||||
; UNSUPPORTED: powerpc
|
; UNSUPPORTED: powerpc
|
||||||
; REQUIRES: default_triple, object-emission
|
; REQUIRES: object-emission
|
||||||
; RUN: %llc_dwarf -O0 -filetype=obj -o %t < %s
|
; RUN: %llc_dwarf -O0 -filetype=obj -o %t < %s
|
||||||
; RUN: llvm-nm --radix=o %t | grep posix_absolute_func > %t.posix_absolute_func
|
; RUN: llvm-nm --radix=o %t | grep posix_absolute_func > %t.posix_absolute_func
|
||||||
; RUN: llvm-nm --radix=o %t | grep posix_relative_func > %t.posix_relative_func
|
; RUN: llvm-nm --radix=o %t | grep posix_relative_func > %t.posix_relative_func
|
||||||
|
@ -72,4 +72,3 @@ define i32 @posix_relative_func() #0 !dbg !44 {
|
||||||
!47 = !DIBasicType(name: "int", size: 32, align: 32, encoding: DW_ATE_signed)
|
!47 = !DIBasicType(name: "int", size: 32, align: 32, encoding: DW_ATE_signed)
|
||||||
!411 = !DILocation(line: 44, column: 2, scope: !44)
|
!411 = !DILocation(line: 44, column: 2, scope: !44)
|
||||||
!412 = !DIFile(filename: "c.c", directory: "/ABSOLUTE/CU/PATH")
|
!412 = !DIFile(filename: "c.c", directory: "/ABSOLUTE/CU/PATH")
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
; RUN: %llc_dwarf %s -filetype=obj -o %t
|
; RUN: %llc_dwarf %s -filetype=obj -o %t
|
||||||
; RUN: llvm-dwarfdump -debug-info %t | FileCheck %s
|
; RUN: llvm-dwarfdump -debug-info %t | FileCheck %s
|
||||||
; REQUIRES: default_triple, object-emission
|
; REQUIRES: object-emission
|
||||||
;
|
;
|
||||||
; CHECK: DW_TAG_compile_unit
|
; CHECK: DW_TAG_compile_unit
|
||||||
; CHECK-NOT: dwo_id
|
; CHECK-NOT: dwo_id
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
; RUN: %llc_dwarf %s -filetype=obj -o - | llvm-objdump -h - | FileCheck %s
|
; RUN: %llc_dwarf %s -filetype=obj -o - | llvm-objdump -h - | FileCheck %s
|
||||||
; REQUIRES: default_triple, object-emission
|
; REQUIRES: object-emission
|
||||||
|
|
||||||
; CHECK-NOT: .debug_
|
; CHECK-NOT: .debug_
|
||||||
|
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
; CHECK: DW_TAG_compile_unit
|
; CHECK: DW_TAG_compile_unit
|
||||||
; CHECK: DW_AT_GNU_dwo_id {{.*}}abcd
|
; CHECK: DW_AT_GNU_dwo_id {{.*}}abcd
|
||||||
; CHECK: DW_AT_GNU_dwo_name {{.*}}"my.dwo"
|
; CHECK: DW_AT_GNU_dwo_name {{.*}}"my.dwo"
|
||||||
; REQUIRES: default_triple, object-emission
|
; REQUIRES: object-emission
|
||||||
|
|
||||||
!llvm.dbg.cu = !{!0}
|
!llvm.dbg.cu = !{!0}
|
||||||
!llvm.module.flags = !{!3, !4}
|
!llvm.module.flags = !{!3, !4}
|
||||||
|
@ -13,4 +13,3 @@
|
||||||
!2 = !{}
|
!2 = !{}
|
||||||
!3 = !{i32 2, !"Dwarf Version", i32 4}
|
!3 = !{i32 2, !"Dwarf Version", i32 4}
|
||||||
!4 = !{i32 2, !"Debug Info Version", i32 3}
|
!4 = !{i32 2, !"Debug Info Version", i32 3}
|
||||||
|
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
; RUN: FileCheck %s -check-prefix=LW -check-prefix=CHECK <%t1
|
; RUN: FileCheck %s -check-prefix=LW -check-prefix=CHECK <%t1
|
||||||
; RUN: llvm-link %S/Inputs/subprogram-linkonce-weak.ll %s -S -o %t2
|
; RUN: llvm-link %S/Inputs/subprogram-linkonce-weak.ll %s -S -o %t2
|
||||||
; RUN: FileCheck %s -check-prefix=WL -check-prefix=CHECK <%t2
|
; RUN: FileCheck %s -check-prefix=WL -check-prefix=CHECK <%t2
|
||||||
; REQUIRES: default_triple
|
; REQUIRES: object-emission
|
||||||
;
|
;
|
||||||
; Bug 47131
|
; Bug 47131
|
||||||
; XFAIL: sparc
|
; XFAIL: sparc
|
||||||
|
@ -86,7 +86,6 @@ entry:
|
||||||
!5 = !DISubroutineType(types: !{})
|
!5 = !DISubroutineType(types: !{})
|
||||||
|
|
||||||
; Crasher for llc.
|
; Crasher for llc.
|
||||||
; REQUIRES: object-emission
|
|
||||||
; RUN: %llc_dwarf -filetype=obj -O0 %t1 -o %t1.o
|
; RUN: %llc_dwarf -filetype=obj -O0 %t1 -o %t1.o
|
||||||
; RUN: llvm-dwarfdump %t1.o --all | FileCheck %s -check-prefix=DWLW -check-prefix=DW
|
; RUN: llvm-dwarfdump %t1.o --all | FileCheck %s -check-prefix=DWLW -check-prefix=DW
|
||||||
; RUN: %llc_dwarf -filetype=obj -O0 %t2 -o %t2.o
|
; RUN: %llc_dwarf -filetype=obj -O0 %t2 -o %t2.o
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
; REQUIRES: default_triple, object-emission
|
; REQUIRES: object-emission
|
||||||
;
|
;
|
||||||
; RUN: llvm-link %s %p/type-unique-odr-b.ll -S -o - \
|
; RUN: llvm-link %s %p/type-unique-odr-b.ll -S -o - \
|
||||||
; RUN: | %llc_dwarf -dwarf-linkage-names=All -filetype=obj -O0 \
|
; RUN: | %llc_dwarf -dwarf-linkage-names=All -filetype=obj -O0 \
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
; REQUIRES: default_triple, object-emission
|
; REQUIRES: object-emission
|
||||||
|
|
||||||
; RUN: llvm-link %s %p/type-unique-simple-b.ll -S -o %t
|
; RUN: llvm-link %s %p/type-unique-simple-b.ll -S -o %t
|
||||||
; RUN: cat %t | FileCheck %s -check-prefix=LINK
|
; RUN: cat %t | FileCheck %s -check-prefix=LINK
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
; REQUIRES: default_triple, object-emission
|
; REQUIRES: object-emission
|
||||||
;
|
;
|
||||||
; RUN: llvm-link %s %p/type-unique-simple2-b.ll -S -o - | %llc_dwarf -filetype=obj -O0 | llvm-dwarfdump -v -debug-info - | FileCheck %s
|
; RUN: llvm-link %s %p/type-unique-simple2-b.ll -S -o - | %llc_dwarf -filetype=obj -O0 | llvm-dwarfdump -v -debug-info - | FileCheck %s
|
||||||
;
|
;
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
; REQUIRES: default_triple, object-emission
|
; REQUIRES: object-emission
|
||||||
|
|
||||||
; RUN: llvm-link %S/Inputs/type-unique-simple2-a.ll %S/Inputs/type-unique-simple2-b.ll -S -o %t
|
; RUN: llvm-link %S/Inputs/type-unique-simple2-a.ll %S/Inputs/type-unique-simple2-b.ll -S -o %t
|
||||||
; RUN: cat %t | FileCheck %S/Inputs/type-unique-simple2-a.ll -check-prefix=LINK
|
; RUN: cat %t | FileCheck %S/Inputs/type-unique-simple2-a.ll -check-prefix=LINK
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
; REQUIRES: default_triple, object-emission
|
; REQUIRES: object-emission
|
||||||
;
|
;
|
||||||
; RUN: llvm-link %s %p/type-unique-type-array-b.ll -S -o - | %llc_dwarf -filetype=obj -O0 | llvm-dwarfdump -v -debug-info - | FileCheck %s
|
; RUN: llvm-link %s %p/type-unique-type-array-b.ll -S -o - | %llc_dwarf -filetype=obj -O0 | llvm-dwarfdump -v -debug-info - | FileCheck %s
|
||||||
;
|
;
|
||||||
|
|
|
@ -294,14 +294,13 @@ if have_cxx_shared_library():
|
||||||
if config.libcxx_used:
|
if config.libcxx_used:
|
||||||
config.available_features.add('libcxx-used')
|
config.available_features.add('libcxx-used')
|
||||||
|
|
||||||
# Direct object generation
|
|
||||||
if not 'xcore' in config.target_triple:
|
|
||||||
config.available_features.add('object-emission')
|
|
||||||
|
|
||||||
# LLVM can be configured with an empty default triple
|
# LLVM can be configured with an empty default triple
|
||||||
# Some tests are "generic" and require a valid default triple
|
# Some tests are "generic" and require a valid default triple
|
||||||
if config.target_triple:
|
if config.target_triple:
|
||||||
config.available_features.add('default_triple')
|
config.available_features.add('default_triple')
|
||||||
|
# Direct object generation
|
||||||
|
if not 'xcore' in config.target_triple:
|
||||||
|
config.available_features.add('object-emission')
|
||||||
|
|
||||||
import subprocess
|
import subprocess
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue