[clang-tidy][modernize-use-starts-ends-with] Fix operator rewriting false negative...
[llvm-project.git] / lld / test / ELF / vs-diagnostics-dynamic-relocation.s
blob806ed81c438e3f213a9323eb107804e3d046b560
1 // REQUIRES: x86
2 // RUN: llvm-mc -filetype=obj -triple=x86_64-pc-linux %s -o %t.o
3 // RUN: not ld.lld -shared --vs-diagnostics %t.o -o /dev/null 2>&1 | FileCheck %s
5 // CHECK: dyn.s(15): error: relocation R_X86_64_64 cannot be used against local symbol; recompile with -fPIC
6 // CHECK-NEXT: >>> defined in {{.*}}.o
7 // CHECK-NEXT: >>> referenced by dyn.s:15
8 // CHECK-NEXT: >>>{{.*}}.o:(.text+0x{{.+}})
10 // CHECK: /tmp{{/|\\}}dyn.s(20): error: relocation R_X86_64_64 cannot be used against local symbol; recompile with -fPIC
11 // CHECK-NEXT: >>> defined in {{.*}}.o
12 // CHECK-NEXT: >>> referenced by dyn.s:20 (/tmp{{/|\\}}dyn.s:20)
13 // CHECK-NEXT: >>>{{.*}}.o:(.text+0x{{.+}})
15 .file 1 "dyn.s"
16 .loc 1 15
18 foo:
19 .quad foo
21 .file 2 "/tmp" "dyn.s"
22 .loc 2 20
24 bar:
25 .quad bar
27 .section .debug_abbrev,"",@progbits
28 .byte 1 # Abbreviation Code
29 .byte 17 # DW_TAG_compile_unit
30 .byte 0 # DW_CHILDREN_no
31 .byte 16 # DW_AT_stmt_list
32 .byte 23 # DW_FORM_sec_offset
33 .byte 0 # EOM(1)
34 .byte 0 # EOM(2)
35 .byte 0 # EOM(3)
37 .section .debug_info,"",@progbits
38 .long .Lend0 - .Lbegin0 # Length of Unit
39 .Lbegin0:
40 .short 4 # DWARF version number
41 .long .debug_abbrev # Offset Into Abbrev. Section
42 .byte 8 # Address Size (in bytes)
43 .byte 1 # Abbrev [1] 0xb:0x1f DW_TAG_compile_unit
44 .long .debug_line # DW_AT_stmt_list
45 .Lend0:
46 .section .debug_line,"",@progbits