1; RUN: llc < %s -mtriple=ve-unknown-unknown | FileCheck %s 2 3%struct.a = type { i32, i32 } 4 5@A = common global %struct.a zeroinitializer, align 4 6 7; Function Attrs: norecurse nounwind 8define void @fun(%struct.a* noalias nocapture sret(%struct.a) %a, i32 %p1, i32 %p2) { 9; CHECK-LABEL: fun: 10; CHECK: # %bb.0: 11; CHECK-NEXT: stl %s1, (, %s0) 12; CHECK-NEXT: stl %s2, 4(, %s0) 13; CHECK-NEXT: b.l.t (, %s10) 14 %a.zero = getelementptr inbounds %struct.a, %struct.a* %a, i64 0, i32 0 15 store i32 %p1, i32* %a.zero, align 4 16 %a.one = getelementptr inbounds %struct.a, %struct.a* %a, i64 0, i32 1 17 store i32 %p2, i32* %a.one, align 4 18 ret void 19} 20 21; Function Attrs: nounwind 22define void @caller() { 23; CHECK-LABEL: caller: 24; CHECK: .LBB{{[0-9]+}}_2: 25; CHECK-NEXT: lea %s0, callee@lo 26; CHECK-NEXT: and %s0, %s0, (32)0 27; CHECK-NEXT: lea.sl %s12, callee@hi(, %s0) 28; CHECK-NEXT: lea %s0, 248(, %s11) 29; CHECK-NEXT: or %s1, 3, (0)1 30; CHECK-NEXT: or %s2, 4, (0)1 31; CHECK-NEXT: bsic %s10, (, %s12) 32; CHECK-NEXT: ld %s0, 248(, %s11) 33; CHECK-NEXT: lea %s1, A@lo 34; CHECK-NEXT: and %s1, %s1, (32)0 35; CHECK-NEXT: lea.sl %s1, A@hi(, %s1) 36; CHECK-NEXT: st %s0, (, %s1) 37; CHECK-NEXT: or %s11, 0, %s9 38 %a = alloca i64, align 8 39 %a.bc = bitcast i64* %a to %struct.a* 40 call void @callee(%struct.a* nonnull sret(%struct.a) %a.bc, i32 3, i32 4) 41 %a.val = load i64, i64* %a, align 8 42 store i64 %a.val, i64* bitcast (%struct.a* @A to i64*), align 4 43 ret void 44} 45 46declare void @callee(%struct.a* sret(%struct.a), i32, i32) 47