[llvm-readobj] - Simplify stack-sizes.test test case.
[llvm-complete.git] / test / MC / ARM / aligned-blx.s
blob39f335934c4b0b3704be39efb5c6555861e2b190
1 @ RUN: llvm-mc -triple thumbv7-apple-ios -filetype=obj %s -o %t
2 @ RUN: llvm-objdump -macho -d %t | FileCheck %s
4 @ Size: 2 bytes
5 .thumb_func _f1
6 .thumb
7 .globl _f1
8 _f1:
9 bx lr
11 @ A properly aligned ARM function
12 .globl _aligned
13 .p2align 2
14 .arm
15 _aligned:
16 bx lr
18 @ Align this Thumb function so we can predict the outcome of
19 @ "Align(PC, 4)" during blx operation.
20 .thumb_func _test
21 .thumb
22 .p2align 2
23 .globl _test
24 _test:
25 blx _elsewhere
26 blx _aligned @ PC=0 (mod 4)
27 blx _aligned @ PC=0 (mod 4)
28 movs r0, r0
29 blx _aligned @ PC=2 (mod 4)
30 blx _f1
32 @ CHECK: blx _elsewhere
33 @ CHECK: ff f7 fa ef blx _aligned
34 @ CHECK: ff f7 f8 ef blx _aligned
35 @ CHECK: ff f7 f6 ef blx _aligned
36 @ CHECK: ff f7 f2 ef blx _f1