mirror of
https://github.com/RPCSX/llvm.git
synced 2025-01-04 02:40:34 +00:00
9d2f0da138
There is something in link.exe that requires a relocation to use a global symbol. Not doing so breaks the chrome build on windows. This patch sets isWeak for that to work. To compensate, we then need to look past those symbols when not creating relocations. This patch includes an ELF test that matches GNU as behaviour. I am still reducing the chrome build issue and will add a test once that is done. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@233318 91177308-0d34-0410-b5e6-96231b3b80d8
19 lines
340 B
ArmAsm
19 lines
340 B
ArmAsm
// RUN: llvm-mc -filetype=obj -triple x86_64-pc-linux < %s | llvm-readobj -r | FileCheck %s
|
|
|
|
// CHECK: Section (2) .rela.text {
|
|
// CHECK-NEXT: 0x0 R_X86_64_32 d 0x0
|
|
// CHECK-NEXT: }
|
|
|
|
a:
|
|
b = a
|
|
c = a
|
|
d = a
|
|
.weak d
|
|
.long d + (b - c)
|
|
|
|
|
|
a2:
|
|
.weak b2
|
|
b2 = a2
|
|
c2 = b2 - a2
|