|
| 1 | +; NOTE: Assertions have been autogenerated by utils/update_test_checks.py |
| 2 | +; RUN: opt -mtriple=riscv64 -mcpu=sifive-x280 -passes=slp-vectorizer -S -slp-revec -slp-max-reg-size=1024 -slp-threshold=-10 %s | FileCheck %s |
| 3 | + |
| 4 | +define void @test(<4 x float> %load6, <4 x float> %load7, <4 x float> %load8, <4 x float> %load17, <4 x float> %fmuladd7, <4 x float> %fmuladd16, ptr %out_ptr) { |
| 5 | +; CHECK-LABEL: @test( |
| 6 | +; CHECK-NEXT: entry: |
| 7 | +; CHECK-NEXT: [[VEXT165_I:%.*]] = shufflevector <4 x float> [[LOAD6:%.*]], <4 x float> [[LOAD7:%.*]], <4 x i32> <i32 2, i32 3, i32 4, i32 5> |
| 8 | +; CHECK-NEXT: [[VEXT309_I:%.*]] = shufflevector <4 x float> [[LOAD7]], <4 x float> [[LOAD8:%.*]], <4 x i32> <i32 2, i32 3, i32 4, i32 5> |
| 9 | +; CHECK-NEXT: [[FMULADD8:%.*]] = tail call noundef <4 x float> @llvm.fmuladd.v4f32(<4 x float> [[VEXT165_I]], <4 x float> [[LOAD17:%.*]], <4 x float> [[FMULADD7:%.*]]) |
| 10 | +; CHECK-NEXT: [[FMULADD17:%.*]] = tail call noundef <4 x float> @llvm.fmuladd.v4f32(<4 x float> [[VEXT309_I]], <4 x float> [[LOAD17]], <4 x float> [[FMULADD16:%.*]]) |
| 11 | +; CHECK-NEXT: [[ADD_PTR_I_I:%.*]] = getelementptr inbounds i8, ptr [[OUT_PTR:%.*]], i64 16 |
| 12 | +; CHECK-NEXT: store <4 x float> [[FMULADD8]], ptr [[OUT_PTR]], align 4 |
| 13 | +; CHECK-NEXT: store <4 x float> [[FMULADD17]], ptr [[ADD_PTR_I_I]], align 4 |
| 14 | +; CHECK-NEXT: ret void |
| 15 | +; |
| 16 | +entry: |
| 17 | + %vext165.i = shufflevector <4 x float> %load6, <4 x float> %load7, <4 x i32> <i32 2, i32 3, i32 4, i32 5> |
| 18 | + %vext309.i = shufflevector <4 x float> %load7, <4 x float> %load8, <4 x i32> <i32 2, i32 3, i32 4, i32 5> |
| 19 | + %fmuladd8 = tail call noundef <4 x float> @llvm.fmuladd.v4f32(<4 x float> %vext165.i, <4 x float> %load17, <4 x float> %fmuladd7) |
| 20 | + %fmuladd17 = tail call noundef <4 x float> @llvm.fmuladd.v4f32(<4 x float> %vext309.i, <4 x float> %load17, <4 x float> %fmuladd16) |
| 21 | + %add.ptr.i.i = getelementptr inbounds i8, ptr %out_ptr, i64 16 |
| 22 | + store <4 x float> %fmuladd8, ptr %out_ptr, align 4 |
| 23 | + store <4 x float> %fmuladd17, ptr %add.ptr.i.i, align 4 |
| 24 | + ret void |
| 25 | +} |
| 26 | + |
| 27 | +declare <4 x float> @llvm.fmuladd.v4f32(<4 x float>, <4 x float>, <4 x float>) |
0 commit comments