1 ; RUN: llc -mtriple=arm-eabi %s -o - | FileCheck %s
3 %struct.A = type { i8, i8, i8, i8, i16, i8, i8, %struct.B** }
4 %struct.B = type { float, float, i32, i32, i32, [0 x i8] }
6 define i8 @f1(%struct.A* %d) {
7 %tmp2 = getelementptr %struct.A, %struct.A* %d, i32 0, i32 4
8 %tmp23 = bitcast i16* %tmp2 to i32*
9 %tmp4 = load i32, i32* %tmp23
10 %tmp512 = lshr i32 %tmp4, 24
11 %tmp56 = trunc i32 %tmp512 to i8
15 define i32 @f2(%struct.A* %d) {
16 %tmp2 = getelementptr %struct.A, %struct.A* %d, i32 0, i32 4
17 %tmp23 = bitcast i16* %tmp2 to i32*
18 %tmp4 = load i32, i32* %tmp23
19 %tmp512 = lshr i32 %tmp4, 24
20 %tmp56 = trunc i32 %tmp512 to i8
21 %tmp57 = sext i8 %tmp56 to i32
26 ; CHECK-NOT: ldrb{{.*}}7
29 ; CHECK-NOT: ldrsb{{.*}}7