2 // RUN
: llvm-mc
--triple
=armv7a-linux-gnueabihf
-arm-add-build-attributes
-filetype
=obj
-o
%t.o
%s
3 // RUN
: ld.lld
%t.o
-o
%t
4 // RUN
: llvm-objdump
--no-print-imm-hex
--triple
=armv7a-none-linux-gnueabi
-d
--no-show-raw-insn
%t | FileCheck
%s
6 /// A symbol assignment defined alias inherits st_type
and gets the same treatment.
7 // RUN
: llvm-mc
--triple
=armv7a-linux-gnueabihf
-arm-add-build-attributes
-filetype
=obj
--defsym ALIAS
=1 -o
%t1.o
%s
8 // RUN
: ld.lld
--defsym foo
=foo1
%t1.o
-o
%t1
9 // RUN
: llvm-objdump
--no-print-imm-hex
--triple
=armv7a-none-linux-gnueabi
-d
--no-show-raw-insn
%t | FileCheck
%s
11 /// Non-preemptible ifuncs are called via
a PLT entry which is always Arm
12 /// state
, expect the ARM callers to go direct to the PLT entry
, Thumb
13 /// branches are indirected via state change thunks
, the
bl is changed to blx.
19 .type foo1 STT_GNU_IFUNC
23 .type foo STT_GNU_IFUNC
29 .section .text.1, "ax", %progbits
36 .section .text.2, "ax", %progbits
44 // CHECK
: 00021004 <_start
>:
45 // CHECK-NEXT
: b 0x21030
46 // CHECK-NEXT
: bl 0x21030
48 // CHECK
: 0002100c
<thumb_caller
>:
49 // CHECK-NEXT
: b.w
0x21018 <__Thumbv7ABSLongThunk_foo
>
50 // CHECK-NEXT
: b.w
0x21018 <__Thumbv7ABSLongThunk_foo
>
51 // CHECK-NEXT
: blx
0x21030
53 // CHECK
: 00021018 <__Thumbv7ABSLongThunk_foo
>:
54 // CHECK-NEXT
: movw
r12, #4144
55 // CHECK-NEXT
: movt
r12, #2
58 // CHECK
: Disassembly of section
.iplt:
60 // CHECK
: 00021030 <.iplt>:
61 // CHECK-NEXT
: add r12, pc
, #0, #12
62 // CHECK-NEXT
: add r12, r12, #16, #20
63 // CHECK-NEXT
: ldr pc
, [r12, #8]!