2 ; RUN: llvm-as < %s | opt -scalarrepl -disable-output &&
3 ; RUN: llvm-as < %s | opt -scalarrepl | llvm-dis | not grep alloca
5 void %test(<4 x float>* %F, float %f) {
7 %G = alloca <4 x float>, align 16 ; <<4 x float>*> [#uses=3]
8 %tmp = load <4 x float>* %F ; <<4 x float>> [#uses=2]
9 %tmp3 = add <4 x float> %tmp, %tmp ; <<4 x float>> [#uses=1]
10 store <4 x float> %tmp3, <4 x float>* %G
11 %G = getelementptr <4 x float>* %G, int 0, int 0 ; <float*> [#uses=1]
12 store float %f, float* %G
13 %tmp4 = load <4 x float>* %G ; <<4 x float>> [#uses=2]
14 %tmp6 = add <4 x float> %tmp4, %tmp4 ; <<4 x float>> [#uses=1]
15 store <4 x float> %tmp6, <4 x float>* %F
19 void %test2(<4 x float>* %F, float %f) {
21 %G = alloca <4 x float>, align 16 ; <<4 x float>*> [#uses=3]
22 %tmp = load <4 x float>* %F ; <<4 x float>> [#uses=2]
23 %tmp3 = add <4 x float> %tmp, %tmp ; <<4 x float>> [#uses=1]
24 store <4 x float> %tmp3, <4 x float>* %G
25 %tmp = getelementptr <4 x float>* %G, int 0, int 2 ; <float*> [#uses=1]
26 store float %f, float* %tmp
27 %tmp4 = load <4 x float>* %G ; <<4 x float>> [#uses=2]
28 %tmp6 = add <4 x float> %tmp4, %tmp4 ; <<4 x float>> [#uses=1]
29 store <4 x float> %tmp6, <4 x float>* %F
33 void %test3(<4 x float>* %F, float* %f) {
35 %G = alloca <4 x float>, align 16 ; <<4 x float>*> [#uses=2]
36 %tmp = load <4 x float>* %F ; <<4 x float>> [#uses=2]
37 %tmp3 = add <4 x float> %tmp, %tmp ; <<4 x float>> [#uses=1]
38 store <4 x float> %tmp3, <4 x float>* %G
39 %tmp = getelementptr <4 x float>* %G, int 0, int 2 ; <float*> [#uses=1]
40 %tmp = load float* %tmp ; <float> [#uses=1]
41 store float %tmp, float* %f
45 void %test4(<4 x float>* %F, float* %f) {
47 %G = alloca <4 x float>, align 16 ; <<4 x float>*> [#uses=2]
48 %tmp = load <4 x float>* %F ; <<4 x float>> [#uses=2]
49 %tmp3 = add <4 x float> %tmp, %tmp ; <<4 x float>> [#uses=1]
50 store <4 x float> %tmp3, <4 x float>* %G
51 %G = getelementptr <4 x float>* %G, int 0, int 0 ; <float*> [#uses=1]
52 %tmp = load float* %G ; <float> [#uses=1]
53 store float %tmp, float* %f