brintos

brintos / llvm-project-archived public Read only

0
0
Text · 756 B · fd5cc9d Raw
22 lines · plain
1# REQUIRES: x862# RUN: llvm-mc -filetype=obj -triple=x86_64 %s -o %t.o3# RUN: echo 'foo = _start;' > %t.script4# RUN: not ld.lld -shared -T %t.script %t.o -o /dev/null 2>&1 | FileCheck %s5# RUN: not ld.lld -shared --defsym 'foo = _start' %t.o -o /dev/null 2>&1 | FileCheck %s --check-prefix=CHECK26 7## Here we check that symbol 'foo' location is reported properly.8 9# CHECK: error: relocation R_X86_64_PC32 cannot be used against symbol 'foo'10# CHECK: >>> defined in {{.*}}.script:111# CHECK: >>> referenced by {{.*}}.o:(.text+0x1)12 13# CHECK2: error: relocation R_X86_64_PC32 cannot be used against symbol 'foo'14# CHECK2: >>> defined in --defsym{{$}}15# CHECK2: >>> referenced by {{.*}}.o:(.text+0x1)16 17.text18.globl _start19_start:20  .byte 0xe821  .long foo - .22