1@ RUN: not llvm-mc -triple thumbv7-apple-ios -filetype=obj %s -o /dev/null 2>&1 | FileCheck %s 2 @ Size: 2 bytes 3 .thumb_func _f1 4 .thumb 5 .globl _f1 6_f1: 7 bx lr 8 9 @ A misalgined ARM destination. 10 .arm 11 .globl _misaligned 12_misaligned: 13 bx lr 14 15 @ And a properly aligned one. 16 .globl _aligned 17 .p2align 2 18 .arm 19_aligned: 20 bx lr 21 22 @ Align this Thumb function so we can predict the outcome of 23 @ "Align(PC, 4)" during blx operation. 24 .thumb_func _test 25 .thumb 26 .p2align 2 27 .globl _test 28_test: 29 blx _misaligned @ PC=0 (mod 4) 30 movs r0, r0 31 blx _misaligned @ PC=2 (mod 4) 32 movs r0, r0 33 blx _aligned @ PC=0 (mod 4) 34 movs r0, r0 35 blx _aligned @ PC=2 (mod 4) 36 37@ CHECK: error: misaligned ARM call destination 38@ CHECK: blx _misaligned 39@ CHECK: error: misaligned ARM call destination 40@ CHECK: blx _misaligned 41