1 ; RUN: llc -O0 -march=hexagon < %s | FileCheck %s
3 ; Make sure we generate stack alignment.
4 ; CHECK: [[REG1:r[0-9]*]] = and(r29,#-64)
5 ; CHECK: vmem([[REG1]]+#2) =
6 ; CHECK: vmem([[REG1]]+#1) =
7 ; CHECK: = vmem([[REG1]]+#2)
8 ; CHECK: = vmem([[REG1]]+#1)
10 target triple = "hexagon"
12 @g0 = common global <16 x i32> zeroinitializer, align 64
14 ; Function Attrs: nounwind
17 %v0 = alloca i32, align 4
18 %v1 = alloca <16 x i32>, align 64
19 %v2 = alloca <16 x i32>, align 64
21 %v3 = call i32 @f1(i8 zeroext 0)
22 %v4 = call <16 x i32> @llvm.hexagon.V6.lvsplatw(i32 1)
23 store <16 x i32> %v4, ptr %v1, align 64
24 %v5 = call <16 x i32> @llvm.hexagon.V6.lvsplatw(i32 12)
25 store <16 x i32> %v5, ptr %v2, align 64
26 %v6 = load <16 x i32>, ptr %v1, align 64
27 %v7 = load <16 x i32>, ptr %v2, align 64
28 %v8 = call <16 x i32> @llvm.hexagon.V6.vaddw(<16 x i32> %v6, <16 x i32> %v7)
29 store <16 x i32> %v8, ptr @g0, align 64
34 declare i32 @f1(i8 zeroext) #0
36 ; Function Attrs: nounwind readnone
37 declare <16 x i32> @llvm.hexagon.V6.lvsplatw(i32) #1
39 ; Function Attrs: nounwind readnone
40 declare <16 x i32> @llvm.hexagon.V6.vaddw(<16 x i32>, <16 x i32>) #1
42 declare void @f2(...) #0
44 attributes #0 = { nounwind "target-cpu"="hexagonv65" "target-features"="+hvxv65,+hvx-length64b" }
45 attributes #1 = { nounwind readnone }