]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - test/ELF/ppc64-weak-undef-call.s
Vendor import of lld trunk r338150:
[FreeBSD/FreeBSD.git] / test / ELF / ppc64-weak-undef-call.s
1 # REQUIRES: ppc
2
3 # RUN: llvm-mc -filetype=obj -triple=powerpc64le-unknown-linux %s -o %t
4 # RUN: ld.lld %t -o %t2
5 # RUN: llvm-objdump -d %t2 | FileCheck %s
6
7 # RUN: llvm-mc -filetype=obj -triple=powerpc64-unknown-linux %s -o %t
8 # RUN: ld.lld %t -o %t2
9 # RUN: llvm-objdump -d %t2 | FileCheck %s
10
11 # CHECK: Disassembly of section .text:
12
13 .text
14 .global _start
15 _start:
16   bl weakfunc
17   nop
18   blr
19
20 .weak weakfunc
21
22 # It does not really matter how we fixup the bl, if at all, because it needs to
23 # be unreachable. But, we should link successfully. We should not, however,
24 # generate a .plt entry (this would be wasted space). For now, we do nothing
25 # (leaving the zero relative offset present in the input).
26 # CHECK: 10010000:       {{.*}}     bl .+0
27 # CHECK: 10010004:       {{.*}}     nop
28 # CHECK: 10010008:       {{.*}}     blr