diff --git a/bolt/test/X86/Inputs/tailcall_traps.s b/bolt/test/X86/Inputs/tailcall_traps.s --- a/bolt/test/X86/Inputs/tailcall_traps.s +++ b/bolt/test/X86/Inputs/tailcall_traps.s @@ -1,18 +1,18 @@ -.globl main -main: - .globl foo foo: .cfi_startproc jmpq *%rax .cfi_endproc +.size foo, .-foo .globl bar bar: .cfi_startproc jmp moo .cfi_endproc +.size bar, .-bar .globl moo moo: nop +.size moo, .-moo diff --git a/bolt/test/X86/cfi-instrs-count.s b/bolt/test/X86/cfi-instrs-count.s --- a/bolt/test/X86/cfi-instrs-count.s +++ b/bolt/test/X86/cfi-instrs-count.s @@ -109,8 +109,3 @@ .cfi_endproc .size _Z7catchitv, .-_Z7catchitv -.set "_Z5raisev", 0 -.set _ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc, 0 -.set _ZNSolsEPFRSoS_E, 0 -.set __cxa_begin_catch, 0 -.set __cxa_end_catch, 0 diff --git a/bolt/test/X86/false-jump-table.s b/bolt/test/X86/false-jump-table.s --- a/bolt/test/X86/false-jump-table.s +++ b/bolt/test/X86/false-jump-table.s @@ -45,7 +45,7 @@ # CHECK: leaq "JUMP_TABLE{{.*}}"(%rip), %rdx leaq .L4(%rip), %rdx jmp .LJT -# CHECK: leaq DATAat{{.*}}(%rip), %rdx +# CHECK: leaq {{.*}}(%rip), %rdx leaq .LC0(%rip), %rdx jmp .L10 .LJT: diff --git a/bolt/test/X86/inline-debug-info.test b/bolt/test/X86/inline-debug-info.test --- a/bolt/test/X86/inline-debug-info.test +++ b/bolt/test/X86/inline-debug-info.test @@ -10,7 +10,7 @@ # RUN: | FileCheck %s ## The call to puts() should come from inline-foo.c: -# CHECK: callq puts@PLT # debug line {{.*}}inline-foo.c:4:3 +# CHECK: callq {{.*}} # debug line {{.*}}inline-foo.c:4:3 # RUN: llvm-objdump --disassemble-symbols=main -d --line-numbers %t.bolt \ # RUN: | FileCheck %s -check-prefix=CHECK-OBJDUMP diff --git a/bolt/test/X86/issue26.s b/bolt/test/X86/issue26.s --- a/bolt/test/X86/issue26.s +++ b/bolt/test/X86/issue26.s @@ -53,4 +53,7 @@ main: xorq %rax, %rax retq + +# For relocations against .text + call exit .Lend2: diff --git a/bolt/test/X86/lit.local.cfg b/bolt/test/X86/lit.local.cfg --- a/bolt/test/X86/lit.local.cfg +++ b/bolt/test/X86/lit.local.cfg @@ -1,2 +1,7 @@ if config.host_arch not in ['x86', 'X86', 'x86_64']: config.unsupported = True + +config.substitutions.insert( + 0, ('%cflags', + '%cflags --target=x86_64--pc-linux -nostartfiles -nostdlib -fuse-ld=lld' + ' -Wl,--unresolved-symbols=ignore-all')) diff --git a/bolt/test/X86/loop-inversion-pass.s b/bolt/test/X86/loop-inversion-pass.s --- a/bolt/test/X86/loop-inversion-pass.s +++ b/bolt/test/X86/loop-inversion-pass.s @@ -44,4 +44,7 @@ cmp $16, %rax jl .Jloop retq + +# For relocations against .text + call exit .Lend: diff --git a/bolt/test/X86/loop-nest.test b/bolt/test/X86/loop-nest.test --- a/bolt/test/X86/loop-nest.test +++ b/bolt/test/X86/loop-nest.test @@ -9,8 +9,8 @@ RUN: llvm-bolt %t.exe -o %t -data=%t.fdata \ RUN: -print-cfg -print-loops -sequential-disassembly -lite=0 2>&1 | FileCheck %s -CHECK: Binary Function "main" after building cfg -CHECK: Loop Info for Function "main" +CHECK: Binary Function "main{{.*}}" after building cfg +CHECK: Loop Info for Function "main{{.*}}" CHECK: Outer loop header: .Ltmp[[#MAIN_OUTER_HDR:]] CHECK-NEXT: Loop basic blocks: .Ltmp[[#MAIN_OUTER_HDR]], .Ltmp[[#]] diff --git a/bolt/test/X86/split-func-jump-table-fragment-reverse.s b/bolt/test/X86/split-func-jump-table-fragment-reverse.s --- a/bolt/test/X86/split-func-jump-table-fragment-reverse.s +++ b/bolt/test/X86/split-func-jump-table-fragment-reverse.s @@ -12,6 +12,13 @@ # CHECK-NOT: unclaimed PC-relative relocations left in data # CHECK: BOLT-INFO: marking main.cold as a fragment of main .text + .globl _start + .type _start, %function +_start: + callq main.cold + call exit +.size _start, .-_start + .globl main.cold .type main.cold, %function .p2align 2 diff --git a/bolt/test/X86/tail-duplication-jt.s b/bolt/test/X86/tail-duplication-jt.s --- a/bolt/test/X86/tail-duplication-jt.s +++ b/bolt/test/X86/tail-duplication-jt.s @@ -11,7 +11,7 @@ # RUN: llvm-bolt %t.exe -o %t.out -data %t.fdata -relocs \ # RUN: -tail-duplication=1 -tail-duplication-aggressive=1 \ # RUN: -print-cfg | FileCheck %s -# CHECK: Jump table JUMP_TABLE/a.0 for function a at {{.*}} with a total count of 3 +# CHECK: Jump table {{.*}} for function a at {{.*}} with a total count of 3 .globl main main: .globl a diff --git a/bolt/test/X86/tail-duplication-pass.s b/bolt/test/X86/tail-duplication-pass.s --- a/bolt/test/X86/tail-duplication-pass.s +++ b/bolt/test/X86/tail-duplication-pass.s @@ -23,4 +23,6 @@ inc %rax .BB2: retq +# For relocations against .text + call exit .Lend: