1; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py 2; RUN: llc -mtriple=thumbv8.1m.main-none-none-eabi -mattr=+mve.fp -verify-machineinstrs %s -o - | FileCheck %s 3 4define arm_aapcs_vfpcc void @test_fadd(float* noalias nocapture readonly %A, float %B, float* noalias nocapture %C, i32 %n) { 5; CHECK-LABEL: test_fadd: 6; CHECK: @ %bb.0: @ %entry 7; CHECK-NEXT: cmp r2, #1 8; CHECK-NEXT: it lt 9; CHECK-NEXT: bxlt lr 10; CHECK-NEXT: .LBB0_1: @ %vector.ph 11; CHECK-NEXT: vmov r3, s0 12; CHECK-NEXT: .LBB0_2: @ %vector.body 13; CHECK-NEXT: @ =>This Inner Loop Header: Depth=1 14; CHECK-NEXT: vldrw.u32 q0, [r0], #16 15; CHECK-NEXT: subs r2, #4 16; CHECK-NEXT: vadd.f32 q0, q0, r3 17; CHECK-NEXT: vstrb.8 q0, [r1], #16 18; CHECK-NEXT: bne .LBB0_2 19; CHECK-NEXT: @ %bb.3: @ %for.cond.cleanup 20; CHECK-NEXT: bx lr 21entry: 22 %0 = and i32 %n, 7 23 %cmp = icmp eq i32 %0, 0 24 tail call void @llvm.assume(i1 %cmp) 25 %cmp18 = icmp sgt i32 %n, 0 26 br i1 %cmp18, label %vector.ph, label %for.cond.cleanup 27 28vector.ph: ; preds = %entry 29 %broadcast.splatinsert10 = insertelement <4 x float> undef, float %B, i32 0 30 %broadcast.splat11 = shufflevector <4 x float> %broadcast.splatinsert10, <4 x float> undef, <4 x i32> zeroinitializer 31 br label %vector.body 32 33vector.body: ; preds = %vector.body, %vector.ph 34 %index = phi i32 [ 0, %vector.ph ], [ %index.next, %vector.body ] 35 %1 = getelementptr inbounds float, float* %A, i32 %index 36 %2 = bitcast float* %1 to <4 x float>* 37 %wide.load = load <4 x float>, <4 x float>* %2, align 4 38 %3 = fadd fast <4 x float> %wide.load, %broadcast.splat11 39 %4 = getelementptr inbounds float, float* %C, i32 %index 40 %5 = bitcast float* %4 to <4 x float>* 41 store <4 x float> %3, <4 x float>* %5, align 4 42 %index.next = add i32 %index, 4 43 %6 = icmp eq i32 %index.next, %n 44 br i1 %6, label %for.cond.cleanup, label %vector.body 45 46for.cond.cleanup: ; preds = %vector.body, %entry 47 ret void 48} 49 50define arm_aapcs_vfpcc void @test_fadd_r(float* noalias nocapture readonly %A, float %B, float* noalias nocapture %C, i32 %n) { 51; CHECK-LABEL: test_fadd_r: 52; CHECK: @ %bb.0: @ %entry 53; CHECK-NEXT: cmp r2, #1 54; CHECK-NEXT: it lt 55; CHECK-NEXT: bxlt lr 56; CHECK-NEXT: .LBB1_1: @ %vector.ph 57; CHECK-NEXT: vmov r3, s0 58; CHECK-NEXT: .LBB1_2: @ %vector.body 59; CHECK-NEXT: @ =>This Inner Loop Header: Depth=1 60; CHECK-NEXT: vldrw.u32 q0, [r0], #16 61; CHECK-NEXT: subs r2, #4 62; CHECK-NEXT: vadd.f32 q0, q0, r3 63; CHECK-NEXT: vstrb.8 q0, [r1], #16 64; CHECK-NEXT: bne .LBB1_2 65; CHECK-NEXT: @ %bb.3: @ %for.cond.cleanup 66; CHECK-NEXT: bx lr 67entry: 68 %0 = and i32 %n, 7 69 %cmp = icmp eq i32 %0, 0 70 tail call void @llvm.assume(i1 %cmp) 71 %cmp18 = icmp sgt i32 %n, 0 72 br i1 %cmp18, label %vector.ph, label %for.cond.cleanup 73 74vector.ph: ; preds = %entry 75 %broadcast.splatinsert10 = insertelement <4 x float> undef, float %B, i32 0 76 %broadcast.splat11 = shufflevector <4 x float> %broadcast.splatinsert10, <4 x float> undef, <4 x i32> zeroinitializer 77 br label %vector.body 78 79vector.body: ; preds = %vector.body, %vector.ph 80 %index = phi i32 [ 0, %vector.ph ], [ %index.next, %vector.body ] 81 %1 = getelementptr inbounds float, float* %A, i32 %index 82 %2 = bitcast float* %1 to <4 x float>* 83 %wide.load = load <4 x float>, <4 x float>* %2, align 4 84 %3 = fadd fast <4 x float> %broadcast.splat11, %wide.load 85 %4 = getelementptr inbounds float, float* %C, i32 %index 86 %5 = bitcast float* %4 to <4 x float>* 87 store <4 x float> %3, <4 x float>* %5, align 4 88 %index.next = add i32 %index, 4 89 %6 = icmp eq i32 %index.next, %n 90 br i1 %6, label %for.cond.cleanup, label %vector.body 91 92for.cond.cleanup: ; preds = %vector.body, %entry 93 ret void 94} 95 96define arm_aapcs_vfpcc void @test_fmul(float* noalias nocapture readonly %A, float %B, float* noalias nocapture %C, i32 %n) { 97; CHECK-LABEL: test_fmul: 98; CHECK: @ %bb.0: @ %entry 99; CHECK-NEXT: cmp r2, #1 100; CHECK-NEXT: it lt 101; CHECK-NEXT: bxlt lr 102; CHECK-NEXT: .LBB2_1: @ %vector.ph 103; CHECK-NEXT: vmov r3, s0 104; CHECK-NEXT: .LBB2_2: @ %vector.body 105; CHECK-NEXT: @ =>This Inner Loop Header: Depth=1 106; CHECK-NEXT: vldrw.u32 q0, [r0], #16 107; CHECK-NEXT: subs r2, #4 108; CHECK-NEXT: vmul.f32 q0, q0, r3 109; CHECK-NEXT: vstrb.8 q0, [r1], #16 110; CHECK-NEXT: bne .LBB2_2 111; CHECK-NEXT: @ %bb.3: @ %for.cond.cleanup 112; CHECK-NEXT: bx lr 113entry: 114 %0 = and i32 %n, 7 115 %cmp = icmp eq i32 %0, 0 116 tail call void @llvm.assume(i1 %cmp) 117 %cmp18 = icmp sgt i32 %n, 0 118 br i1 %cmp18, label %vector.ph, label %for.cond.cleanup 119 120vector.ph: ; preds = %entry 121 %broadcast.splatinsert10 = insertelement <4 x float> undef, float %B, i32 0 122 %broadcast.splat11 = shufflevector <4 x float> %broadcast.splatinsert10, <4 x float> undef, <4 x i32> zeroinitializer 123 br label %vector.body 124 125vector.body: ; preds = %vector.body, %vector.ph 126 %index = phi i32 [ 0, %vector.ph ], [ %index.next, %vector.body ] 127 %1 = getelementptr inbounds float, float* %A, i32 %index 128 %2 = bitcast float* %1 to <4 x float>* 129 %wide.load = load <4 x float>, <4 x float>* %2, align 4 130 %3 = fmul fast <4 x float> %wide.load, %broadcast.splat11 131 %4 = getelementptr inbounds float, float* %C, i32 %index 132 %5 = bitcast float* %4 to <4 x float>* 133 store <4 x float> %3, <4 x float>* %5, align 4 134 %index.next = add i32 %index, 4 135 %6 = icmp eq i32 %index.next, %n 136 br i1 %6, label %for.cond.cleanup, label %vector.body 137 138for.cond.cleanup: ; preds = %vector.body, %entry 139 ret void 140} 141 142define arm_aapcs_vfpcc void @test_fmul_r(float* noalias nocapture readonly %A, float %B, float* noalias nocapture %C, i32 %n) { 143; CHECK-LABEL: test_fmul_r: 144; CHECK: @ %bb.0: @ %entry 145; CHECK-NEXT: cmp r2, #1 146; CHECK-NEXT: it lt 147; CHECK-NEXT: bxlt lr 148; CHECK-NEXT: .LBB3_1: @ %vector.ph 149; CHECK-NEXT: vmov r3, s0 150; CHECK-NEXT: .LBB3_2: @ %vector.body 151; CHECK-NEXT: @ =>This Inner Loop Header: Depth=1 152; CHECK-NEXT: vldrw.u32 q0, [r0], #16 153; CHECK-NEXT: subs r2, #4 154; CHECK-NEXT: vmul.f32 q0, q0, r3 155; CHECK-NEXT: vstrb.8 q0, [r1], #16 156; CHECK-NEXT: bne .LBB3_2 157; CHECK-NEXT: @ %bb.3: @ %for.cond.cleanup 158; CHECK-NEXT: bx lr 159entry: 160 %0 = and i32 %n, 7 161 %cmp = icmp eq i32 %0, 0 162 tail call void @llvm.assume(i1 %cmp) 163 %cmp18 = icmp sgt i32 %n, 0 164 br i1 %cmp18, label %vector.ph, label %for.cond.cleanup 165 166vector.ph: ; preds = %entry 167 %broadcast.splatinsert10 = insertelement <4 x float> undef, float %B, i32 0 168 %broadcast.splat11 = shufflevector <4 x float> %broadcast.splatinsert10, <4 x float> undef, <4 x i32> zeroinitializer 169 br label %vector.body 170 171vector.body: ; preds = %vector.body, %vector.ph 172 %index = phi i32 [ 0, %vector.ph ], [ %index.next, %vector.body ] 173 %1 = getelementptr inbounds float, float* %A, i32 %index 174 %2 = bitcast float* %1 to <4 x float>* 175 %wide.load = load <4 x float>, <4 x float>* %2, align 4 176 %3 = fmul fast <4 x float> %broadcast.splat11, %wide.load 177 %4 = getelementptr inbounds float, float* %C, i32 %index 178 %5 = bitcast float* %4 to <4 x float>* 179 store <4 x float> %3, <4 x float>* %5, align 4 180 %index.next = add i32 %index, 4 181 %6 = icmp eq i32 %index.next, %n 182 br i1 %6, label %for.cond.cleanup, label %vector.body 183 184for.cond.cleanup: ; preds = %vector.body, %entry 185 ret void 186} 187 188define arm_aapcs_vfpcc void @test_fsub(float* noalias nocapture readonly %A, float %B, float* noalias nocapture %C, i32 %n) { 189; CHECK-LABEL: test_fsub: 190; CHECK: @ %bb.0: @ %entry 191; CHECK-NEXT: cmp r2, #1 192; CHECK-NEXT: it lt 193; CHECK-NEXT: bxlt lr 194; CHECK-NEXT: .LBB4_1: @ %vector.ph 195; CHECK-NEXT: vmov r3, s0 196; CHECK-NEXT: .LBB4_2: @ %vector.body 197; CHECK-NEXT: @ =>This Inner Loop Header: Depth=1 198; CHECK-NEXT: vldrw.u32 q0, [r0], #16 199; CHECK-NEXT: subs r2, #4 200; CHECK-NEXT: vsub.f32 q0, q0, r3 201; CHECK-NEXT: vstrb.8 q0, [r1], #16 202; CHECK-NEXT: bne .LBB4_2 203; CHECK-NEXT: @ %bb.3: @ %for.cond.cleanup 204; CHECK-NEXT: bx lr 205entry: 206 %0 = and i32 %n, 7 207 %cmp = icmp eq i32 %0, 0 208 tail call void @llvm.assume(i1 %cmp) 209 %cmp18 = icmp sgt i32 %n, 0 210 br i1 %cmp18, label %vector.ph, label %for.cond.cleanup 211 212vector.ph: ; preds = %entry 213 %broadcast.splatinsert10 = insertelement <4 x float> undef, float %B, i32 0 214 %broadcast.splat11 = shufflevector <4 x float> %broadcast.splatinsert10, <4 x float> undef, <4 x i32> zeroinitializer 215 br label %vector.body 216 217vector.body: ; preds = %vector.body, %vector.ph 218 %index = phi i32 [ 0, %vector.ph ], [ %index.next, %vector.body ] 219 %1 = getelementptr inbounds float, float* %A, i32 %index 220 %2 = bitcast float* %1 to <4 x float>* 221 %wide.load = load <4 x float>, <4 x float>* %2, align 4 222 %3 = fsub fast <4 x float> %wide.load, %broadcast.splat11 223 %4 = getelementptr inbounds float, float* %C, i32 %index 224 %5 = bitcast float* %4 to <4 x float>* 225 store <4 x float> %3, <4 x float>* %5, align 4 226 %index.next = add i32 %index, 4 227 %6 = icmp eq i32 %index.next, %n 228 br i1 %6, label %for.cond.cleanup, label %vector.body 229 230for.cond.cleanup: ; preds = %vector.body, %entry 231 ret void 232} 233 234define arm_aapcs_vfpcc void @test_fsub_r(float* noalias nocapture readonly %A, float %B, float* noalias nocapture %C, i32 %n) { 235; CHECK-LABEL: test_fsub_r: 236; CHECK: @ %bb.0: @ %entry 237; CHECK-NEXT: cmp r2, #1 238; CHECK-NEXT: it lt 239; CHECK-NEXT: bxlt lr 240; CHECK-NEXT: .LBB5_1: @ %vector.ph 241; CHECK-NEXT: vmov r3, s0 242; CHECK-NEXT: vdup.32 q0, r3 243; CHECK-NEXT: .LBB5_2: @ %vector.body 244; CHECK-NEXT: @ =>This Inner Loop Header: Depth=1 245; CHECK-NEXT: vldrw.u32 q1, [r0], #16 246; CHECK-NEXT: subs r2, #4 247; CHECK-NEXT: vsub.f32 q1, q0, q1 248; CHECK-NEXT: vstrb.8 q1, [r1], #16 249; CHECK-NEXT: bne .LBB5_2 250; CHECK-NEXT: @ %bb.3: @ %for.cond.cleanup 251; CHECK-NEXT: bx lr 252entry: 253 %0 = and i32 %n, 7 254 %cmp = icmp eq i32 %0, 0 255 tail call void @llvm.assume(i1 %cmp) 256 %cmp18 = icmp sgt i32 %n, 0 257 br i1 %cmp18, label %vector.ph, label %for.cond.cleanup 258 259vector.ph: ; preds = %entry 260 %broadcast.splatinsert10 = insertelement <4 x float> undef, float %B, i32 0 261 %broadcast.splat11 = shufflevector <4 x float> %broadcast.splatinsert10, <4 x float> undef, <4 x i32> zeroinitializer 262 br label %vector.body 263 264vector.body: ; preds = %vector.body, %vector.ph 265 %index = phi i32 [ 0, %vector.ph ], [ %index.next, %vector.body ] 266 %1 = getelementptr inbounds float, float* %A, i32 %index 267 %2 = bitcast float* %1 to <4 x float>* 268 %wide.load = load <4 x float>, <4 x float>* %2, align 4 269 %3 = fsub fast <4 x float> %broadcast.splat11, %wide.load 270 %4 = getelementptr inbounds float, float* %C, i32 %index 271 %5 = bitcast float* %4 to <4 x float>* 272 store <4 x float> %3, <4 x float>* %5, align 4 273 %index.next = add i32 %index, 4 274 %6 = icmp eq i32 %index.next, %n 275 br i1 %6, label %for.cond.cleanup, label %vector.body 276 277for.cond.cleanup: ; preds = %vector.body, %entry 278 ret void 279} 280 281 282define arm_aapcs_vfpcc void @test_fmas(float* noalias nocapture readonly %A, float* noalias nocapture readonly %B, float %C, float* noalias nocapture %D, i32 %n) { 283; CHECK-LABEL: test_fmas: 284; CHECK: @ %bb.0: @ %entry 285; CHECK-NEXT: cmp r3, #1 286; CHECK-NEXT: it lt 287; CHECK-NEXT: bxlt lr 288; CHECK-NEXT: .LBB6_1: @ %vector.ph 289; CHECK-NEXT: vmov r12, s0 290; CHECK-NEXT: .LBB6_2: @ %vector.body 291; CHECK-NEXT: @ =>This Inner Loop Header: Depth=1 292; CHECK-NEXT: vldrw.u32 q0, [r0], #16 293; CHECK-NEXT: vldrw.u32 q1, [r1], #16 294; CHECK-NEXT: subs r3, #4 295; CHECK-NEXT: vfmas.f32 q1, q0, r12 296; CHECK-NEXT: vstrb.8 q1, [r2], #16 297; CHECK-NEXT: bne .LBB6_2 298; CHECK-NEXT: @ %bb.3: @ %for.cond.cleanup 299; CHECK-NEXT: bx lr 300entry: 301 %0 = and i32 %n, 7 302 %cmp = icmp eq i32 %0, 0 303 tail call void @llvm.assume(i1 %cmp) 304 %cmp110 = icmp sgt i32 %n, 0 305 br i1 %cmp110, label %vector.ph, label %for.cond.cleanup 306 307vector.ph: ; preds = %entry 308 %broadcast.splatinsert13 = insertelement <4 x float> undef, float %C, i32 0 309 %broadcast.splat14 = shufflevector <4 x float> %broadcast.splatinsert13, <4 x float> undef, <4 x i32> zeroinitializer 310 br label %vector.body 311 312vector.body: ; preds = %vector.body, %vector.ph 313 %index = phi i32 [ 0, %vector.ph ], [ %index.next, %vector.body ] 314 %1 = getelementptr inbounds float, float* %A, i32 %index 315 %2 = bitcast float* %1 to <4 x float>* 316 %wide.load = load <4 x float>, <4 x float>* %2, align 4 317 %3 = getelementptr inbounds float, float* %B, i32 %index 318 %4 = bitcast float* %3 to <4 x float>* 319 %wide.load12 = load <4 x float>, <4 x float>* %4, align 4 320 %5 = fmul fast <4 x float> %wide.load12, %wide.load 321 %6 = fadd fast <4 x float> %5, %broadcast.splat14 322 %7 = getelementptr inbounds float, float* %D, i32 %index 323 %8 = bitcast float* %7 to <4 x float>* 324 store <4 x float> %6, <4 x float>* %8, align 4 325 %index.next = add i32 %index, 4 326 %9 = icmp eq i32 %index.next, %n 327 br i1 %9, label %for.cond.cleanup, label %vector.body 328 329for.cond.cleanup: ; preds = %vector.body, %entry 330 ret void 331} 332 333define arm_aapcs_vfpcc void @test_fmas_r(float* noalias nocapture readonly %A, float* noalias nocapture readonly %B, float %C, float* noalias nocapture %D, i32 %n) { 334; CHECK-LABEL: test_fmas_r: 335; CHECK: @ %bb.0: @ %entry 336; CHECK-NEXT: cmp r3, #1 337; CHECK-NEXT: it lt 338; CHECK-NEXT: bxlt lr 339; CHECK-NEXT: .LBB7_1: @ %vector.ph 340; CHECK-NEXT: vmov r12, s0 341; CHECK-NEXT: .LBB7_2: @ %vector.body 342; CHECK-NEXT: @ =>This Inner Loop Header: Depth=1 343; CHECK-NEXT: vldrw.u32 q0, [r0], #16 344; CHECK-NEXT: vldrw.u32 q1, [r1], #16 345; CHECK-NEXT: subs r3, #4 346; CHECK-NEXT: vfmas.f32 q1, q0, r12 347; CHECK-NEXT: vstrb.8 q1, [r2], #16 348; CHECK-NEXT: bne .LBB7_2 349; CHECK-NEXT: @ %bb.3: @ %for.cond.cleanup 350; CHECK-NEXT: bx lr 351entry: 352 %0 = and i32 %n, 7 353 %cmp = icmp eq i32 %0, 0 354 tail call void @llvm.assume(i1 %cmp) 355 %cmp110 = icmp sgt i32 %n, 0 356 br i1 %cmp110, label %vector.ph, label %for.cond.cleanup 357 358vector.ph: ; preds = %entry 359 %broadcast.splatinsert13 = insertelement <4 x float> undef, float %C, i32 0 360 %broadcast.splat14 = shufflevector <4 x float> %broadcast.splatinsert13, <4 x float> undef, <4 x i32> zeroinitializer 361 br label %vector.body 362 363vector.body: ; preds = %vector.body, %vector.ph 364 %index = phi i32 [ 0, %vector.ph ], [ %index.next, %vector.body ] 365 %1 = getelementptr inbounds float, float* %A, i32 %index 366 %2 = bitcast float* %1 to <4 x float>* 367 %wide.load = load <4 x float>, <4 x float>* %2, align 4 368 %3 = getelementptr inbounds float, float* %B, i32 %index 369 %4 = bitcast float* %3 to <4 x float>* 370 %wide.load12 = load <4 x float>, <4 x float>* %4, align 4 371 %5 = fmul fast <4 x float> %wide.load12, %wide.load 372 %6 = fadd fast <4 x float> %broadcast.splat14, %5 373 %7 = getelementptr inbounds float, float* %D, i32 %index 374 %8 = bitcast float* %7 to <4 x float>* 375 store <4 x float> %6, <4 x float>* %8, align 4 376 %index.next = add i32 %index, 4 377 %9 = icmp eq i32 %index.next, %n 378 br i1 %9, label %for.cond.cleanup, label %vector.body 379 380for.cond.cleanup: ; preds = %vector.body, %entry 381 ret void 382} 383 384define arm_aapcs_vfpcc void @test_fma(float* noalias nocapture readonly %A, float* noalias nocapture readonly %B, float %C, float* noalias nocapture %D, i32 %n) { 385; CHECK-LABEL: test_fma: 386; CHECK: @ %bb.0: @ %entry 387; CHECK-NEXT: cmp r3, #1 388; CHECK-NEXT: it lt 389; CHECK-NEXT: bxlt lr 390; CHECK-NEXT: .LBB8_1: @ %vector.ph 391; CHECK-NEXT: vmov r12, s0 392; CHECK-NEXT: .LBB8_2: @ %vector.body 393; CHECK-NEXT: @ =>This Inner Loop Header: Depth=1 394; CHECK-NEXT: vldrw.u32 q0, [r0], #16 395; CHECK-NEXT: vldrw.u32 q1, [r1], #16 396; CHECK-NEXT: subs r3, #4 397; CHECK-NEXT: vfma.f32 q1, q0, r12 398; CHECK-NEXT: vstrb.8 q1, [r2], #16 399; CHECK-NEXT: bne .LBB8_2 400; CHECK-NEXT: @ %bb.3: @ %for.cond.cleanup 401; CHECK-NEXT: bx lr 402entry: 403 %0 = and i32 %n, 7 404 %cmp = icmp eq i32 %0, 0 405 tail call void @llvm.assume(i1 %cmp) 406 %cmp110 = icmp sgt i32 %n, 0 407 br i1 %cmp110, label %vector.ph, label %for.cond.cleanup 408 409vector.ph: ; preds = %entry 410 %broadcast.splatinsert12 = insertelement <4 x float> undef, float %C, i32 0 411 %broadcast.splat13 = shufflevector <4 x float> %broadcast.splatinsert12, <4 x float> undef, <4 x i32> zeroinitializer 412 br label %vector.body 413 414vector.body: ; preds = %vector.body, %vector.ph 415 %index = phi i32 [ 0, %vector.ph ], [ %index.next, %vector.body ] 416 %1 = getelementptr inbounds float, float* %A, i32 %index 417 %2 = bitcast float* %1 to <4 x float>* 418 %wide.load = load <4 x float>, <4 x float>* %2, align 4 419 %3 = fmul fast <4 x float> %wide.load, %broadcast.splat13 420 %4 = getelementptr inbounds float, float* %B, i32 %index 421 %5 = bitcast float* %4 to <4 x float>* 422 %wide.load14 = load <4 x float>, <4 x float>* %5, align 4 423 %6 = fadd fast <4 x float> %3, %wide.load14 424 %7 = getelementptr inbounds float, float* %D, i32 %index 425 %8 = bitcast float* %7 to <4 x float>* 426 store <4 x float> %6, <4 x float>* %8, align 4 427 %index.next = add i32 %index, 4 428 %9 = icmp eq i32 %index.next, %n 429 br i1 %9, label %for.cond.cleanup, label %vector.body 430 431for.cond.cleanup: ; preds = %vector.body, %entry 432 ret void 433} 434 435define arm_aapcs_vfpcc void @test_fma_r(float* noalias nocapture readonly %A, float* noalias nocapture readonly %B, float %C, float* noalias nocapture %D, i32 %n) { 436; CHECK-LABEL: test_fma_r: 437; CHECK: @ %bb.0: @ %entry 438; CHECK-NEXT: cmp r3, #1 439; CHECK-NEXT: it lt 440; CHECK-NEXT: bxlt lr 441; CHECK-NEXT: .LBB9_1: @ %vector.ph 442; CHECK-NEXT: vmov r12, s0 443; CHECK-NEXT: .LBB9_2: @ %vector.body 444; CHECK-NEXT: @ =>This Inner Loop Header: Depth=1 445; CHECK-NEXT: vldrw.u32 q0, [r0], #16 446; CHECK-NEXT: vldrw.u32 q1, [r1], #16 447; CHECK-NEXT: subs r3, #4 448; CHECK-NEXT: vfma.f32 q1, q0, r12 449; CHECK-NEXT: vstrb.8 q1, [r2], #16 450; CHECK-NEXT: bne .LBB9_2 451; CHECK-NEXT: @ %bb.3: @ %for.cond.cleanup 452; CHECK-NEXT: bx lr 453entry: 454 %0 = and i32 %n, 7 455 %cmp = icmp eq i32 %0, 0 456 tail call void @llvm.assume(i1 %cmp) 457 %cmp110 = icmp sgt i32 %n, 0 458 br i1 %cmp110, label %vector.ph, label %for.cond.cleanup 459 460vector.ph: ; preds = %entry 461 %broadcast.splatinsert12 = insertelement <4 x float> undef, float %C, i32 0 462 %broadcast.splat13 = shufflevector <4 x float> %broadcast.splatinsert12, <4 x float> undef, <4 x i32> zeroinitializer 463 br label %vector.body 464 465vector.body: ; preds = %vector.body, %vector.ph 466 %index = phi i32 [ 0, %vector.ph ], [ %index.next, %vector.body ] 467 %1 = getelementptr inbounds float, float* %A, i32 %index 468 %2 = bitcast float* %1 to <4 x float>* 469 %wide.load = load <4 x float>, <4 x float>* %2, align 4 470 %3 = fmul fast <4 x float> %broadcast.splat13, %wide.load 471 %4 = getelementptr inbounds float, float* %B, i32 %index 472 %5 = bitcast float* %4 to <4 x float>* 473 %wide.load14 = load <4 x float>, <4 x float>* %5, align 4 474 %6 = fadd fast <4 x float> %3, %wide.load14 475 %7 = getelementptr inbounds float, float* %D, i32 %index 476 %8 = bitcast float* %7 to <4 x float>* 477 store <4 x float> %6, <4 x float>* %8, align 4 478 %index.next = add i32 %index, 4 479 %9 = icmp eq i32 %index.next, %n 480 br i1 %9, label %for.cond.cleanup, label %vector.body 481 482for.cond.cleanup: ; preds = %vector.body, %entry 483 ret void 484} 485 486 487define arm_aapcs_vfpcc void @test_fmss(float* noalias nocapture readonly %A, float* noalias nocapture readonly %B, float %C, float* noalias nocapture %D, i32 %n) { 488; CHECK-LABEL: test_fmss: 489; CHECK: @ %bb.0: @ %entry 490; CHECK-NEXT: cmp r3, #1 491; CHECK-NEXT: it lt 492; CHECK-NEXT: bxlt lr 493; CHECK-NEXT: .LBB10_1: @ %vector.ph 494; CHECK-NEXT: vmov r12, s0 495; CHECK-NEXT: vdup.32 q0, r12 496; CHECK-NEXT: vneg.f32 q0, q0 497; CHECK-NEXT: .LBB10_2: @ %vector.body 498; CHECK-NEXT: @ =>This Inner Loop Header: Depth=1 499; CHECK-NEXT: vldrw.u32 q1, [r0], #16 500; CHECK-NEXT: vldrw.u32 q2, [r1], #16 501; CHECK-NEXT: vmov q3, q0 502; CHECK-NEXT: subs r3, #4 503; CHECK-NEXT: vfma.f32 q3, q2, q1 504; CHECK-NEXT: vstrb.8 q3, [r2], #16 505; CHECK-NEXT: bne .LBB10_2 506; CHECK-NEXT: @ %bb.3: @ %for.cond.cleanup 507; CHECK-NEXT: bx lr 508entry: 509 %0 = and i32 %n, 7 510 %cmp = icmp eq i32 %0, 0 511 tail call void @llvm.assume(i1 %cmp) 512 %cmp110 = icmp sgt i32 %n, 0 513 br i1 %cmp110, label %vector.ph, label %for.cond.cleanup 514 515vector.ph: ; preds = %entry 516 %broadcast.splatinsert13 = insertelement <4 x float> undef, float %C, i32 0 517 %broadcast.splat14 = shufflevector <4 x float> %broadcast.splatinsert13, <4 x float> undef, <4 x i32> zeroinitializer 518 br label %vector.body 519 520vector.body: ; preds = %vector.body, %vector.ph 521 %index = phi i32 [ 0, %vector.ph ], [ %index.next, %vector.body ] 522 %1 = getelementptr inbounds float, float* %A, i32 %index 523 %2 = bitcast float* %1 to <4 x float>* 524 %wide.load = load <4 x float>, <4 x float>* %2, align 4 525 %3 = getelementptr inbounds float, float* %B, i32 %index 526 %4 = bitcast float* %3 to <4 x float>* 527 %wide.load12 = load <4 x float>, <4 x float>* %4, align 4 528 %5 = fmul fast <4 x float> %wide.load12, %wide.load 529 %6 = fsub fast <4 x float> %5, %broadcast.splat14 530 %7 = getelementptr inbounds float, float* %D, i32 %index 531 %8 = bitcast float* %7 to <4 x float>* 532 store <4 x float> %6, <4 x float>* %8, align 4 533 %index.next = add i32 %index, 4 534 %9 = icmp eq i32 %index.next, %n 535 br i1 %9, label %for.cond.cleanup, label %vector.body 536 537for.cond.cleanup: ; preds = %vector.body, %entry 538 ret void 539} 540 541define arm_aapcs_vfpcc void @test_fmss_r(float* noalias nocapture readonly %A, float* noalias nocapture readonly %B, float %C, float* noalias nocapture %D, i32 %n) { 542; CHECK-LABEL: test_fmss_r: 543; CHECK: @ %bb.0: @ %entry 544; CHECK-NEXT: cmp r3, #1 545; CHECK-NEXT: it lt 546; CHECK-NEXT: bxlt lr 547; CHECK-NEXT: .LBB11_1: @ %vector.ph 548; CHECK-NEXT: vmov r12, s0 549; CHECK-NEXT: vdup.32 q0, r12 550; CHECK-NEXT: .LBB11_2: @ %vector.body 551; CHECK-NEXT: @ =>This Inner Loop Header: Depth=1 552; CHECK-NEXT: vldrw.u32 q1, [r0], #16 553; CHECK-NEXT: vldrw.u32 q2, [r1], #16 554; CHECK-NEXT: vmov q3, q0 555; CHECK-NEXT: subs r3, #4 556; CHECK-NEXT: vfms.f32 q3, q2, q1 557; CHECK-NEXT: vstrb.8 q3, [r2], #16 558; CHECK-NEXT: bne .LBB11_2 559; CHECK-NEXT: @ %bb.3: @ %for.cond.cleanup 560; CHECK-NEXT: bx lr 561entry: 562 %0 = and i32 %n, 7 563 %cmp = icmp eq i32 %0, 0 564 tail call void @llvm.assume(i1 %cmp) 565 %cmp110 = icmp sgt i32 %n, 0 566 br i1 %cmp110, label %vector.ph, label %for.cond.cleanup 567 568vector.ph: ; preds = %entry 569 %broadcast.splatinsert13 = insertelement <4 x float> undef, float %C, i32 0 570 %broadcast.splat14 = shufflevector <4 x float> %broadcast.splatinsert13, <4 x float> undef, <4 x i32> zeroinitializer 571 br label %vector.body 572 573vector.body: ; preds = %vector.body, %vector.ph 574 %index = phi i32 [ 0, %vector.ph ], [ %index.next, %vector.body ] 575 %1 = getelementptr inbounds float, float* %A, i32 %index 576 %2 = bitcast float* %1 to <4 x float>* 577 %wide.load = load <4 x float>, <4 x float>* %2, align 4 578 %3 = getelementptr inbounds float, float* %B, i32 %index 579 %4 = bitcast float* %3 to <4 x float>* 580 %wide.load12 = load <4 x float>, <4 x float>* %4, align 4 581 %5 = fmul fast <4 x float> %wide.load12, %wide.load 582 %6 = fsub fast <4 x float> %broadcast.splat14, %5 583 %7 = getelementptr inbounds float, float* %D, i32 %index 584 %8 = bitcast float* %7 to <4 x float>* 585 store <4 x float> %6, <4 x float>* %8, align 4 586 %index.next = add i32 %index, 4 587 %9 = icmp eq i32 %index.next, %n 588 br i1 %9, label %for.cond.cleanup, label %vector.body 589 590for.cond.cleanup: ; preds = %vector.body, %entry 591 ret void 592} 593 594define arm_aapcs_vfpcc void @test_fms(float* noalias nocapture readonly %A, float* noalias nocapture readonly %B, float %C, float* noalias nocapture %D, i32 %n) { 595; CHECK-LABEL: test_fms: 596; CHECK: @ %bb.0: @ %entry 597; CHECK-NEXT: cmp r3, #1 598; CHECK-NEXT: it lt 599; CHECK-NEXT: bxlt lr 600; CHECK-NEXT: .LBB12_1: @ %vector.ph 601; CHECK-NEXT: vmov r12, s0 602; CHECK-NEXT: .LBB12_2: @ %vector.body 603; CHECK-NEXT: @ =>This Inner Loop Header: Depth=1 604; CHECK-NEXT: vldrw.u32 q0, [r1], #16 605; CHECK-NEXT: vldrw.u32 q1, [r0], #16 606; CHECK-NEXT: subs r3, #4 607; CHECK-NEXT: vneg.f32 q0, q0 608; CHECK-NEXT: vfma.f32 q0, q1, r12 609; CHECK-NEXT: vstrb.8 q0, [r2], #16 610; CHECK-NEXT: bne .LBB12_2 611; CHECK-NEXT: @ %bb.3: @ %for.cond.cleanup 612; CHECK-NEXT: bx lr 613entry: 614 %0 = and i32 %n, 7 615 %cmp = icmp eq i32 %0, 0 616 tail call void @llvm.assume(i1 %cmp) 617 %cmp110 = icmp sgt i32 %n, 0 618 br i1 %cmp110, label %vector.ph, label %for.cond.cleanup 619 620vector.ph: ; preds = %entry 621 %broadcast.splatinsert12 = insertelement <4 x float> undef, float %C, i32 0 622 %broadcast.splat13 = shufflevector <4 x float> %broadcast.splatinsert12, <4 x float> undef, <4 x i32> zeroinitializer 623 br label %vector.body 624 625vector.body: ; preds = %vector.body, %vector.ph 626 %index = phi i32 [ 0, %vector.ph ], [ %index.next, %vector.body ] 627 %1 = getelementptr inbounds float, float* %A, i32 %index 628 %2 = bitcast float* %1 to <4 x float>* 629 %wide.load = load <4 x float>, <4 x float>* %2, align 4 630 %3 = fmul fast <4 x float> %wide.load, %broadcast.splat13 631 %4 = getelementptr inbounds float, float* %B, i32 %index 632 %5 = bitcast float* %4 to <4 x float>* 633 %wide.load14 = load <4 x float>, <4 x float>* %5, align 4 634 %6 = fsub fast <4 x float> %3, %wide.load14 635 %7 = getelementptr inbounds float, float* %D, i32 %index 636 %8 = bitcast float* %7 to <4 x float>* 637 store <4 x float> %6, <4 x float>* %8, align 4 638 %index.next = add i32 %index, 4 639 %9 = icmp eq i32 %index.next, %n 640 br i1 %9, label %for.cond.cleanup, label %vector.body 641 642for.cond.cleanup: ; preds = %vector.body, %entry 643 ret void 644} 645 646define arm_aapcs_vfpcc void @test_fms_r(float* noalias nocapture readonly %A, float* noalias nocapture readonly %B, float %C, float* noalias nocapture %D, i32 %n) { 647; CHECK-LABEL: test_fms_r: 648; CHECK: @ %bb.0: @ %entry 649; CHECK-NEXT: cmp r3, #1 650; CHECK-NEXT: it lt 651; CHECK-NEXT: bxlt lr 652; CHECK-NEXT: .LBB13_1: @ %vector.ph 653; CHECK-NEXT: vmov r12, s0 654; CHECK-NEXT: .LBB13_2: @ %vector.body 655; CHECK-NEXT: @ =>This Inner Loop Header: Depth=1 656; CHECK-NEXT: vldrw.u32 q0, [r1], #16 657; CHECK-NEXT: vldrw.u32 q1, [r0], #16 658; CHECK-NEXT: subs r3, #4 659; CHECK-NEXT: vneg.f32 q0, q0 660; CHECK-NEXT: vfma.f32 q0, q1, r12 661; CHECK-NEXT: vstrb.8 q0, [r2], #16 662; CHECK-NEXT: bne .LBB13_2 663; CHECK-NEXT: @ %bb.3: @ %for.cond.cleanup 664; CHECK-NEXT: bx lr 665entry: 666 %0 = and i32 %n, 7 667 %cmp = icmp eq i32 %0, 0 668 tail call void @llvm.assume(i1 %cmp) 669 %cmp110 = icmp sgt i32 %n, 0 670 br i1 %cmp110, label %vector.ph, label %for.cond.cleanup 671 672vector.ph: ; preds = %entry 673 %broadcast.splatinsert12 = insertelement <4 x float> undef, float %C, i32 0 674 %broadcast.splat13 = shufflevector <4 x float> %broadcast.splatinsert12, <4 x float> undef, <4 x i32> zeroinitializer 675 br label %vector.body 676 677vector.body: ; preds = %vector.body, %vector.ph 678 %index = phi i32 [ 0, %vector.ph ], [ %index.next, %vector.body ] 679 %1 = getelementptr inbounds float, float* %A, i32 %index 680 %2 = bitcast float* %1 to <4 x float>* 681 %wide.load = load <4 x float>, <4 x float>* %2, align 4 682 %3 = fmul fast <4 x float> %broadcast.splat13, %wide.load 683 %4 = getelementptr inbounds float, float* %B, i32 %index 684 %5 = bitcast float* %4 to <4 x float>* 685 %wide.load14 = load <4 x float>, <4 x float>* %5, align 4 686 %6 = fsub fast <4 x float> %3, %wide.load14 687 %7 = getelementptr inbounds float, float* %D, i32 %index 688 %8 = bitcast float* %7 to <4 x float>* 689 store <4 x float> %6, <4 x float>* %8, align 4 690 %index.next = add i32 %index, 4 691 %9 = icmp eq i32 %index.next, %n 692 br i1 %9, label %for.cond.cleanup, label %vector.body 693 694for.cond.cleanup: ; preds = %vector.body, %entry 695 ret void 696} 697 698 699define dso_local void @test_nested(float* noalias nocapture %pInT1, float* noalias nocapture readonly %pOutT1, float* noalias nocapture readonly %pPRT_in, float* noalias nocapture readnone %pPRT_pDst, i32 %numRows, i32 %numCols, i32 %l) local_unnamed_addr #0 { 700; CHECK-LABEL: test_nested: 701; CHECK: @ %bb.0: @ %for.body.us.preheader 702; CHECK-NEXT: .save {r4, r5, r6, lr} 703; CHECK-NEXT: push {r4, r5, r6, lr} 704; CHECK-NEXT: ldrd lr, r12, [sp, #16] 705; CHECK-NEXT: lsl.w r3, r12, #2 706; CHECK-NEXT: .LBB14_1: @ %for.body.us 707; CHECK-NEXT: @ =>This Loop Header: Depth=1 708; CHECK-NEXT: @ Child Loop BB14_2 Depth 2 709; CHECK-NEXT: ldr r4, [r1] 710; CHECK-NEXT: mov r5, r2 711; CHECK-NEXT: mov r6, r12 712; CHECK-NEXT: vdup.32 q0, r4 713; CHECK-NEXT: mov r4, r0 714; CHECK-NEXT: .LBB14_2: @ %vector.body 715; CHECK-NEXT: @ Parent Loop BB14_1 Depth=1 716; CHECK-NEXT: @ => This Inner Loop Header: Depth=2 717; CHECK-NEXT: vldrw.u32 q1, [r5], #16 718; CHECK-NEXT: vldrw.u32 q2, [r4] 719; CHECK-NEXT: subs r6, #4 720; CHECK-NEXT: vfms.f32 q2, q1, q0 721; CHECK-NEXT: vstrb.8 q2, [r4], #16 722; CHECK-NEXT: bne .LBB14_2 723; CHECK-NEXT: @ %bb.3: @ %for.cond6.for.end_crit_edge.us 724; CHECK-NEXT: @ in Loop: Header=BB14_1 Depth=1 725; CHECK-NEXT: add r0, r3 726; CHECK-NEXT: add r2, r3 727; CHECK-NEXT: adds r1, #4 728; CHECK-NEXT: le lr, .LBB14_1 729; CHECK-NEXT: @ %bb.4: @ %for.end14 730; CHECK-NEXT: pop {r4, r5, r6, pc} 731for.body.us.preheader: 732 %cmp = icmp sgt i32 %numRows, 0 733 tail call void @llvm.assume(i1 %cmp) 734 %cmp1 = icmp sgt i32 %numCols, 0 735 tail call void @llvm.assume(i1 %cmp1) 736 %rem = and i32 %numCols, 7 737 %cmp2 = icmp eq i32 %rem, 0 738 tail call void @llvm.assume(i1 %cmp2) 739 %cmp3 = icmp slt i32 %l, %numCols 740 tail call void @llvm.assume(i1 %cmp3) 741 br label %for.body.us 742 743for.body.us: ; preds = %for.cond6.for.end_crit_edge.us, %for.body.us.preheader 744 %pInT1.addr.038.us = phi float* [ %scevgep40, %for.cond6.for.end_crit_edge.us ], [ %pInT1, %for.body.us.preheader ] 745 %i.037.us = phi i32 [ %inc13.us, %for.cond6.for.end_crit_edge.us ], [ 0, %for.body.us.preheader ] 746 %pOutT1.addr.036.us = phi float* [ %incdec.ptr.us, %for.cond6.for.end_crit_edge.us ], [ %pOutT1, %for.body.us.preheader ] 747 %pPRT_in.addr.035.us = phi float* [ %scevgep, %for.cond6.for.end_crit_edge.us ], [ %pPRT_in, %for.body.us.preheader ] 748 %scevgep = getelementptr float, float* %pPRT_in.addr.035.us, i32 %numCols 749 %0 = load float, float* %pOutT1.addr.036.us, align 4 750 %broadcast.splatinsert47 = insertelement <4 x float> undef, float %0, i32 0 751 %broadcast.splat48 = shufflevector <4 x float> %broadcast.splatinsert47, <4 x float> undef, <4 x i32> zeroinitializer 752 br label %vector.body 753 754vector.body: ; preds = %vector.body, %for.body.us 755 %index = phi i32 [ 0, %for.body.us ], [ %index.next, %vector.body ] 756 %next.gep = getelementptr float, float* %pInT1.addr.038.us, i32 %index 757 %next.gep45 = getelementptr float, float* %pPRT_in.addr.035.us, i32 %index 758 %1 = bitcast float* %next.gep to <4 x float>* 759 %wide.load = load <4 x float>, <4 x float>* %1, align 4 760 %2 = bitcast float* %next.gep45 to <4 x float>* 761 %wide.load46 = load <4 x float>, <4 x float>* %2, align 4 762 %3 = fmul fast <4 x float> %wide.load46, %broadcast.splat48 763 %4 = fsub fast <4 x float> %wide.load, %3 764 store <4 x float> %4, <4 x float>* %1, align 4 765 %index.next = add i32 %index, 4 766 %5 = icmp eq i32 %index.next, %numCols 767 br i1 %5, label %for.cond6.for.end_crit_edge.us, label %vector.body 768 769for.cond6.for.end_crit_edge.us: ; preds = %vector.body 770 %incdec.ptr.us = getelementptr inbounds float, float* %pOutT1.addr.036.us, i32 1 771 %scevgep40 = getelementptr float, float* %pInT1.addr.038.us, i32 %numCols 772 %inc13.us = add nuw nsw i32 %i.037.us, 1 773 %exitcond41 = icmp eq i32 %inc13.us, %numRows 774 br i1 %exitcond41, label %for.end14, label %for.body.us 775 776for.end14: ; preds = %for.cond6.for.end_crit_edge.us 777 ret void 778} 779 780%struct.arm_fir_instance_f32 = type { i16, float*, float* } 781define void @arm_fir_f32_1_4_mve(%struct.arm_fir_instance_f32* nocapture readonly %S, float* nocapture readonly %pSrc, float* %pDst, i32 %blockSize) { 782; CHECK-LABEL: arm_fir_f32_1_4_mve: 783; CHECK: @ %bb.0: @ %entry 784; CHECK-NEXT: .save {r4, r5, r6, r7, r8, r9, r10, r11, lr} 785; CHECK-NEXT: push.w {r4, r5, r6, r7, r8, r9, r10, r11, lr} 786; CHECK-NEXT: .pad #8 787; CHECK-NEXT: sub sp, #8 788; CHECK-NEXT: ldrh.w r10, [r0] 789; CHECK-NEXT: mov r11, r1 790; CHECK-NEXT: ldr.w r12, [r0, #4] 791; CHECK-NEXT: sub.w r1, r10, #1 792; CHECK-NEXT: cmp r1, #3 793; CHECK-NEXT: bhi .LBB15_6 794; CHECK-NEXT: @ %bb.1: @ %if.then 795; CHECK-NEXT: ldr r4, [r0, #8] 796; CHECK-NEXT: ldrd r7, r6, [r4] 797; CHECK-NEXT: ldrd r5, r8, [r4, #8] 798; CHECK-NEXT: add.w r4, r12, r1, lsl #2 799; CHECK-NEXT: lsrs r1, r3, #2 800; CHECK-NEXT: wls lr, r1, .LBB15_5 801; CHECK-NEXT: @ %bb.2: @ %while.body.lr.ph 802; CHECK-NEXT: bic r1, r3, #3 803; CHECK-NEXT: str r1, [sp] @ 4-byte Spill 804; CHECK-NEXT: add.w r9, r12, #4 805; CHECK-NEXT: add.w r1, r2, r1, lsl #2 806; CHECK-NEXT: str r1, [sp, #4] @ 4-byte Spill 807; CHECK-NEXT: mov r1, r11 808; CHECK-NEXT: .LBB15_3: @ %while.body 809; CHECK-NEXT: @ =>This Inner Loop Header: Depth=1 810; CHECK-NEXT: vldrw.u32 q0, [r1], #16 811; CHECK-NEXT: vstrb.8 q0, [r4], #16 812; CHECK-NEXT: vldrw.u32 q0, [r9, #-4] 813; CHECK-NEXT: vldrw.u32 q1, [r9], #16 814; CHECK-NEXT: vmul.f32 q0, q0, r7 815; CHECK-NEXT: vldrw.u32 q2, [r9, #-8] 816; CHECK-NEXT: vfma.f32 q0, q1, r6 817; CHECK-NEXT: vldrw.u32 q1, [r9, #-12] 818; CHECK-NEXT: vfma.f32 q0, q1, r5 819; CHECK-NEXT: vfma.f32 q0, q2, r8 820; CHECK-NEXT: vstrb.8 q0, [r2], #16 821; CHECK-NEXT: le lr, .LBB15_3 822; CHECK-NEXT: @ %bb.4: @ %while.end.loopexit 823; CHECK-NEXT: ldr r1, [sp] @ 4-byte Reload 824; CHECK-NEXT: ldr r2, [sp, #4] @ 4-byte Reload 825; CHECK-NEXT: add.w r12, r12, r1, lsl #2 826; CHECK-NEXT: add.w r11, r11, r1, lsl #2 827; CHECK-NEXT: .LBB15_5: @ %while.end 828; CHECK-NEXT: and r1, r3, #3 829; CHECK-NEXT: vldrw.u32 q0, [r11] 830; CHECK-NEXT: vctp.32 r1 831; CHECK-NEXT: vpst 832; CHECK-NEXT: vstrwt.32 q0, [r4] 833; CHECK-NEXT: vldrw.u32 q0, [r12] 834; CHECK-NEXT: vldrw.u32 q1, [r12, #4] 835; CHECK-NEXT: vmul.f32 q0, q0, r7 836; CHECK-NEXT: vfma.f32 q0, q1, r6 837; CHECK-NEXT: vldrw.u32 q1, [r12, #8] 838; CHECK-NEXT: vfma.f32 q0, q1, r5 839; CHECK-NEXT: vldrw.u32 q1, [r12, #12] 840; CHECK-NEXT: vfma.f32 q0, q1, r8 841; CHECK-NEXT: vpst 842; CHECK-NEXT: vstrwt.32 q0, [r2] 843; CHECK-NEXT: ldr.w r12, [r0, #4] 844; CHECK-NEXT: .LBB15_6: @ %if.end 845; CHECK-NEXT: add.w r0, r12, r3, lsl #2 846; CHECK-NEXT: lsr.w r1, r10, #2 847; CHECK-NEXT: wls lr, r1, .LBB15_10 848; CHECK-NEXT: @ %bb.7: @ %while.body51.preheader 849; CHECK-NEXT: bic r2, r10, #3 850; CHECK-NEXT: adds r1, r2, r3 851; CHECK-NEXT: mov r3, r12 852; CHECK-NEXT: add.w r1, r12, r1, lsl #2 853; CHECK-NEXT: .LBB15_8: @ %while.body51 854; CHECK-NEXT: @ =>This Inner Loop Header: Depth=1 855; CHECK-NEXT: vldrw.u32 q0, [r0], #16 856; CHECK-NEXT: vstrb.8 q0, [r3], #16 857; CHECK-NEXT: le lr, .LBB15_8 858; CHECK-NEXT: @ %bb.9: @ %while.end55.loopexit 859; CHECK-NEXT: add.w r12, r12, r2, lsl #2 860; CHECK-NEXT: mov r0, r1 861; CHECK-NEXT: .LBB15_10: @ %while.end55 862; CHECK-NEXT: ands r1, r10, #3 863; CHECK-NEXT: beq .LBB15_12 864; CHECK-NEXT: @ %bb.11: @ %if.then59 865; CHECK-NEXT: vldrw.u32 q0, [r0] 866; CHECK-NEXT: vctp.32 r1 867; CHECK-NEXT: vpst 868; CHECK-NEXT: vstrwt.32 q0, [r12] 869; CHECK-NEXT: .LBB15_12: @ %if.end61 870; CHECK-NEXT: add sp, #8 871; CHECK-NEXT: pop.w {r4, r5, r6, r7, r8, r9, r10, r11, pc} 872entry: 873 %pState1 = getelementptr inbounds %struct.arm_fir_instance_f32, %struct.arm_fir_instance_f32* %S, i32 0, i32 1 874 %0 = load float*, float** %pState1, align 4 875 %pCoeffs2 = getelementptr inbounds %struct.arm_fir_instance_f32, %struct.arm_fir_instance_f32* %S, i32 0, i32 2 876 %1 = load float*, float** %pCoeffs2, align 4 877 %numTaps3 = getelementptr inbounds %struct.arm_fir_instance_f32, %struct.arm_fir_instance_f32* %S, i32 0, i32 0 878 %2 = load i16, i16* %numTaps3, align 4 879 %conv = zext i16 %2 to i32 880 %sub = add nsw i32 %conv, -1 881 %cmp = icmp ult i32 %sub, 4 882 br i1 %cmp, label %if.then, label %if.end 883 884if.then: ; preds = %entry 885 %arrayidx = getelementptr inbounds float, float* %0, i32 %sub 886 %incdec.ptr = getelementptr inbounds float, float* %1, i32 1 887 %3 = load float, float* %1, align 4 888 %incdec.ptr6 = getelementptr inbounds float, float* %1, i32 2 889 %4 = load float, float* %incdec.ptr, align 4 890 %incdec.ptr7 = getelementptr inbounds float, float* %1, i32 3 891 %5 = load float, float* %incdec.ptr6, align 4 892 %6 = load float, float* %incdec.ptr7, align 4 893 %shr = lshr i32 %blockSize, 2 894 %cmp9146 = icmp eq i32 %shr, 0 895 %.pre161 = insertelement <4 x float> undef, float %3, i32 0 896 %.pre162 = shufflevector <4 x float> %.pre161, <4 x float> undef, <4 x i32> zeroinitializer 897 %.pre163 = insertelement <4 x float> undef, float %4, i32 0 898 %.pre164 = shufflevector <4 x float> %.pre163, <4 x float> undef, <4 x i32> zeroinitializer 899 %.pre165 = insertelement <4 x float> undef, float %5, i32 0 900 %.pre166 = shufflevector <4 x float> %.pre165, <4 x float> undef, <4 x i32> zeroinitializer 901 %.pre167 = insertelement <4 x float> undef, float %6, i32 0 902 %.pre168 = shufflevector <4 x float> %.pre167, <4 x float> undef, <4 x i32> zeroinitializer 903 br i1 %cmp9146, label %while.end, label %while.body.lr.ph 904 905while.body.lr.ph: ; preds = %if.then 906 %7 = and i32 %blockSize, -4 907 %scevgep158 = getelementptr float, float* %pDst, i32 %7 908 br label %while.body 909 910while.body: ; preds = %while.body.lr.ph, %while.body 911 %pStateCur.0151 = phi float* [ %arrayidx, %while.body.lr.ph ], [ %add.ptr, %while.body ] 912 %pSamples.0150 = phi float* [ %0, %while.body.lr.ph ], [ %add.ptr24, %while.body ] 913 %pOutput.0149 = phi float* [ %pDst, %while.body.lr.ph ], [ %add.ptr23, %while.body ] 914 %pTempSrc.0148 = phi float* [ %pSrc, %while.body.lr.ph ], [ %add.ptr11, %while.body ] 915 %blkCnt.0147 = phi i32 [ %shr, %while.body.lr.ph ], [ %dec, %while.body ] 916 %8 = bitcast float* %pTempSrc.0148 to <4 x float>* 917 %9 = load <4 x float>, <4 x float>* %8, align 4 918 %10 = bitcast float* %pStateCur.0151 to <4 x float>* 919 store <4 x float> %9, <4 x float>* %10, align 4 920 %add.ptr = getelementptr inbounds float, float* %pStateCur.0151, i32 4 921 %add.ptr11 = getelementptr inbounds float, float* %pTempSrc.0148, i32 4 922 %11 = bitcast float* %pSamples.0150 to <4 x float>* 923 %12 = load <4 x float>, <4 x float>* %11, align 4 924 %13 = fmul fast <4 x float> %12, %.pre162 925 %arrayidx12 = getelementptr inbounds float, float* %pSamples.0150, i32 1 926 %14 = bitcast float* %arrayidx12 to <4 x float>* 927 %15 = load <4 x float>, <4 x float>* %14, align 4 928 %mul = fmul fast <4 x float> %15, %.pre164 929 %add = fadd fast <4 x float> %mul, %13 930 %arrayidx13 = getelementptr inbounds float, float* %pSamples.0150, i32 2 931 %16 = bitcast float* %arrayidx13 to <4 x float>* 932 %17 = load <4 x float>, <4 x float>* %16, align 4 933 %mul16 = fmul fast <4 x float> %17, %.pre166 934 %add17 = fadd fast <4 x float> %add, %mul16 935 %arrayidx18 = getelementptr inbounds float, float* %pSamples.0150, i32 3 936 %18 = bitcast float* %arrayidx18 to <4 x float>* 937 %19 = load <4 x float>, <4 x float>* %18, align 4 938 %mul21 = fmul fast <4 x float> %19, %.pre168 939 %add22 = fadd fast <4 x float> %add17, %mul21 940 %20 = bitcast float* %pOutput.0149 to <4 x float>* 941 store <4 x float> %add22, <4 x float>* %20, align 4 942 %add.ptr23 = getelementptr inbounds float, float* %pOutput.0149, i32 4 943 %add.ptr24 = getelementptr inbounds float, float* %pSamples.0150, i32 4 944 %dec = add nsw i32 %blkCnt.0147, -1 945 %cmp9 = icmp eq i32 %dec, 0 946 br i1 %cmp9, label %while.end.loopexit, label %while.body 947 948while.end.loopexit: ; preds = %while.body 949 %scevgep157 = getelementptr float, float* %pSrc, i32 %7 950 %scevgep159 = getelementptr float, float* %0, i32 %7 951 br label %while.end 952 953while.end: ; preds = %if.then, %while.end.loopexit 954 %pTempSrc.0.lcssa = phi float* [ %scevgep157, %while.end.loopexit ], [ %pSrc, %if.then ] 955 %pOutput.0.lcssa = phi float* [ %scevgep158, %while.end.loopexit ], [ %pDst, %if.then ] 956 %pSamples.0.lcssa = phi float* [ %scevgep159, %while.end.loopexit ], [ %0, %if.then ] 957 %pStateCur.0.lcssa = phi float* [ %add.ptr, %while.end.loopexit ], [ %arrayidx, %if.then ] 958 %and = and i32 %blockSize, 3 959 %21 = tail call <4 x i1> @llvm.arm.mve.vctp32(i32 %and) 960 %22 = bitcast float* %pTempSrc.0.lcssa to <4 x float>* 961 %23 = load <4 x float>, <4 x float>* %22, align 4 962 %24 = bitcast float* %pStateCur.0.lcssa to <4 x float>* 963 tail call void @llvm.masked.store.v4f32.p0v4f32(<4 x float> %23, <4 x float>* %24, i32 4, <4 x i1> %21) 964 %25 = bitcast float* %pSamples.0.lcssa to <4 x float>* 965 %26 = load <4 x float>, <4 x float>* %25, align 4 966 %27 = fmul fast <4 x float> %26, %.pre162 967 %arrayidx29 = getelementptr inbounds float, float* %pSamples.0.lcssa, i32 1 968 %28 = bitcast float* %arrayidx29 to <4 x float>* 969 %29 = load <4 x float>, <4 x float>* %28, align 4 970 %mul32 = fmul fast <4 x float> %29, %.pre164 971 %add33 = fadd fast <4 x float> %mul32, %27 972 %arrayidx34 = getelementptr inbounds float, float* %pSamples.0.lcssa, i32 2 973 %30 = bitcast float* %arrayidx34 to <4 x float>* 974 %31 = load <4 x float>, <4 x float>* %30, align 4 975 %mul37 = fmul fast <4 x float> %31, %.pre166 976 %add38 = fadd fast <4 x float> %add33, %mul37 977 %arrayidx39 = getelementptr inbounds float, float* %pSamples.0.lcssa, i32 3 978 %32 = bitcast float* %arrayidx39 to <4 x float>* 979 %33 = load <4 x float>, <4 x float>* %32, align 4 980 %mul42 = fmul fast <4 x float> %33, %.pre168 981 %add43 = fadd fast <4 x float> %add38, %mul42 982 %34 = bitcast float* %pOutput.0.lcssa to <4 x float>* 983 tail call void @llvm.masked.store.v4f32.p0v4f32(<4 x float> %add43, <4 x float>* %34, i32 4, <4 x i1> %21) 984 %.pre = load float*, float** %pState1, align 4 985 br label %if.end 986 987if.end: ; preds = %while.end, %entry 988 %35 = phi float* [ %.pre, %while.end ], [ %0, %entry ] 989 %arrayidx45 = getelementptr inbounds float, float* %35, i32 %blockSize 990 %shr47 = lshr i32 %conv, 2 991 %cmp49141 = icmp eq i32 %shr47, 0 992 br i1 %cmp49141, label %while.end55, label %while.body51.preheader 993 994while.body51.preheader: ; preds = %if.end 995 %36 = and i32 %conv, 65532 996 %37 = add i32 %36, %blockSize 997 %scevgep = getelementptr float, float* %35, i32 %37 998 br label %while.body51 999 1000while.body51: ; preds = %while.body51.preheader, %while.body51 1001 %pTempSrc.1144 = phi float* [ %add.ptr52, %while.body51 ], [ %arrayidx45, %while.body51.preheader ] 1002 %pTempDest.0143 = phi float* [ %add.ptr53, %while.body51 ], [ %35, %while.body51.preheader ] 1003 %blkCnt.1142 = phi i32 [ %dec54, %while.body51 ], [ %shr47, %while.body51.preheader ] 1004 %38 = bitcast float* %pTempSrc.1144 to <4 x float>* 1005 %39 = load <4 x float>, <4 x float>* %38, align 4 1006 %40 = bitcast float* %pTempDest.0143 to <4 x float>* 1007 store <4 x float> %39, <4 x float>* %40, align 4 1008 %add.ptr52 = getelementptr inbounds float, float* %pTempSrc.1144, i32 4 1009 %add.ptr53 = getelementptr inbounds float, float* %pTempDest.0143, i32 4 1010 %dec54 = add nsw i32 %blkCnt.1142, -1 1011 %cmp49 = icmp eq i32 %dec54, 0 1012 br i1 %cmp49, label %while.end55.loopexit, label %while.body51 1013 1014while.end55.loopexit: ; preds = %while.body51 1015 %scevgep156 = getelementptr float, float* %35, i32 %36 1016 br label %while.end55 1017 1018while.end55: ; preds = %while.end55.loopexit, %if.end 1019 %pTempDest.0.lcssa = phi float* [ %35, %if.end ], [ %scevgep156, %while.end55.loopexit ] 1020 %pTempSrc.1.lcssa = phi float* [ %arrayidx45, %if.end ], [ %scevgep, %while.end55.loopexit ] 1021 %and56 = and i32 %conv, 3 1022 %cmp57 = icmp eq i32 %and56, 0 1023 br i1 %cmp57, label %if.end61, label %if.then59 1024 1025if.then59: ; preds = %while.end55 1026 %41 = tail call <4 x i1> @llvm.arm.mve.vctp32(i32 %and56) 1027 %42 = bitcast float* %pTempSrc.1.lcssa to <4 x float>* 1028 %43 = load <4 x float>, <4 x float>* %42, align 4 1029 %44 = bitcast float* %pTempDest.0.lcssa to <4 x float>* 1030 tail call void @llvm.masked.store.v4f32.p0v4f32(<4 x float> %43, <4 x float>* %44, i32 4, <4 x i1> %41) 1031 br label %if.end61 1032 1033if.end61: ; preds = %while.end55, %if.then59 1034 ret void 1035} 1036 1037 1038define void @fir(%struct.arm_fir_instance_f32* nocapture readonly %S, float* nocapture readonly %pSrc, float* nocapture %pDst, i32 %blockSize) { 1039; CHECK-LABEL: fir: 1040; CHECK: @ %bb.0: @ %entry 1041; CHECK-NEXT: .save {r4, r5, r6, r7, r8, r9, r10, r11, lr} 1042; CHECK-NEXT: push.w {r4, r5, r6, r7, r8, r9, r10, r11, lr} 1043; CHECK-NEXT: .pad #4 1044; CHECK-NEXT: sub sp, #4 1045; CHECK-NEXT: .vsave {d8, d9, d10, d11, d12, d13} 1046; CHECK-NEXT: vpush {d8, d9, d10, d11, d12, d13} 1047; CHECK-NEXT: .pad #32 1048; CHECK-NEXT: sub sp, #32 1049; CHECK-NEXT: cmp r3, #8 1050; CHECK-NEXT: blo.w .LBB16_12 1051; CHECK-NEXT: @ %bb.1: @ %if.then 1052; CHECK-NEXT: lsrs.w r12, r3, #2 1053; CHECK-NEXT: beq.w .LBB16_12 1054; CHECK-NEXT: @ %bb.2: @ %while.body.lr.ph 1055; CHECK-NEXT: ldrh r6, [r0] 1056; CHECK-NEXT: movs r5, #1 1057; CHECK-NEXT: ldrd r4, r10, [r0, #4] 1058; CHECK-NEXT: sub.w r0, r6, #8 1059; CHECK-NEXT: add.w r3, r0, r0, lsr #29 1060; CHECK-NEXT: and r0, r0, #7 1061; CHECK-NEXT: asrs r7, r3, #3 1062; CHECK-NEXT: cmp r7, #1 1063; CHECK-NEXT: it gt 1064; CHECK-NEXT: asrgt r5, r3, #3 1065; CHECK-NEXT: add.w r3, r4, r6, lsl #2 1066; CHECK-NEXT: sub.w r9, r3, #4 1067; CHECK-NEXT: rsbs r3, r6, #0 1068; CHECK-NEXT: str r3, [sp, #12] @ 4-byte Spill 1069; CHECK-NEXT: add.w r3, r10, #32 1070; CHECK-NEXT: str r5, [sp, #4] @ 4-byte Spill 1071; CHECK-NEXT: str r6, [sp, #16] @ 4-byte Spill 1072; CHECK-NEXT: str r3, [sp, #8] @ 4-byte Spill 1073; CHECK-NEXT: str r0, [sp, #20] @ 4-byte Spill 1074; CHECK-NEXT: b .LBB16_5 1075; CHECK-NEXT: .LBB16_3: @ %for.end 1076; CHECK-NEXT: @ in Loop: Header=BB16_5 Depth=1 1077; CHECK-NEXT: ldr r1, [sp, #28] @ 4-byte Reload 1078; CHECK-NEXT: ldrd r0, r9, [sp, #20] @ 8-byte Folded Reload 1079; CHECK-NEXT: wls lr, r0, .LBB16_4 1080; CHECK-NEXT: b .LBB16_9 1081; CHECK-NEXT: .LBB16_4: @ %while.end 1082; CHECK-NEXT: @ in Loop: Header=BB16_5 Depth=1 1083; CHECK-NEXT: ldr r0, [sp, #12] @ 4-byte Reload 1084; CHECK-NEXT: subs.w r12, r12, #1 1085; CHECK-NEXT: vstrb.8 q0, [r2], #16 1086; CHECK-NEXT: add.w r0, r4, r0, lsl #2 1087; CHECK-NEXT: add.w r4, r0, #16 1088; CHECK-NEXT: beq .LBB16_12 1089; CHECK-NEXT: .LBB16_5: @ %while.body 1090; CHECK-NEXT: @ =>This Loop Header: Depth=1 1091; CHECK-NEXT: @ Child Loop BB16_7 Depth 2 1092; CHECK-NEXT: @ Child Loop BB16_10 Depth 2 1093; CHECK-NEXT: add.w lr, r10, #8 1094; CHECK-NEXT: vldrw.u32 q0, [r1], #16 1095; CHECK-NEXT: ldrd r3, r7, [r10] 1096; CHECK-NEXT: ldm.w lr, {r0, r5, r6, lr} 1097; CHECK-NEXT: ldrd r11, r8, [r10, #24] 1098; CHECK-NEXT: vstrb.8 q0, [r9], #16 1099; CHECK-NEXT: vldrw.u32 q0, [r4], #32 1100; CHECK-NEXT: strd r9, r1, [sp, #24] @ 8-byte Folded Spill 1101; CHECK-NEXT: vldrw.u32 q1, [r4, #-28] 1102; CHECK-NEXT: vmul.f32 q0, q0, r3 1103; CHECK-NEXT: vldrw.u32 q6, [r4, #-24] 1104; CHECK-NEXT: vldrw.u32 q4, [r4, #-20] 1105; CHECK-NEXT: vfma.f32 q0, q1, r7 1106; CHECK-NEXT: vldrw.u32 q5, [r4, #-16] 1107; CHECK-NEXT: vfma.f32 q0, q6, r0 1108; CHECK-NEXT: vldrw.u32 q2, [r4, #-12] 1109; CHECK-NEXT: vfma.f32 q0, q4, r5 1110; CHECK-NEXT: vldrw.u32 q3, [r4, #-8] 1111; CHECK-NEXT: vfma.f32 q0, q5, r6 1112; CHECK-NEXT: ldr r0, [sp, #16] @ 4-byte Reload 1113; CHECK-NEXT: vfma.f32 q0, q2, lr 1114; CHECK-NEXT: vldrw.u32 q1, [r4, #-4] 1115; CHECK-NEXT: vfma.f32 q0, q3, r11 1116; CHECK-NEXT: cmp r0, #16 1117; CHECK-NEXT: vfma.f32 q0, q1, r8 1118; CHECK-NEXT: blo .LBB16_8 1119; CHECK-NEXT: @ %bb.6: @ %for.body.preheader 1120; CHECK-NEXT: @ in Loop: Header=BB16_5 Depth=1 1121; CHECK-NEXT: ldr r0, [sp, #4] @ 4-byte Reload 1122; CHECK-NEXT: dls lr, r0 1123; CHECK-NEXT: ldr r7, [sp, #8] @ 4-byte Reload 1124; CHECK-NEXT: .LBB16_7: @ %for.body 1125; CHECK-NEXT: @ Parent Loop BB16_5 Depth=1 1126; CHECK-NEXT: @ => This Inner Loop Header: Depth=2 1127; CHECK-NEXT: ldm.w r7, {r0, r3, r5, r6, r8, r11} 1128; CHECK-NEXT: vldrw.u32 q1, [r4], #32 1129; CHECK-NEXT: vldrw.u32 q6, [r4, #-24] 1130; CHECK-NEXT: vldrw.u32 q4, [r4, #-20] 1131; CHECK-NEXT: vfma.f32 q0, q1, r0 1132; CHECK-NEXT: vldrw.u32 q1, [r4, #-28] 1133; CHECK-NEXT: vldrw.u32 q5, [r4, #-16] 1134; CHECK-NEXT: vldrw.u32 q2, [r4, #-12] 1135; CHECK-NEXT: vfma.f32 q0, q1, r3 1136; CHECK-NEXT: ldrd r9, r1, [r7, #24] 1137; CHECK-NEXT: vfma.f32 q0, q6, r5 1138; CHECK-NEXT: vldrw.u32 q3, [r4, #-8] 1139; CHECK-NEXT: vfma.f32 q0, q4, r6 1140; CHECK-NEXT: vldrw.u32 q1, [r4, #-4] 1141; CHECK-NEXT: vfma.f32 q0, q5, r8 1142; CHECK-NEXT: adds r7, #32 1143; CHECK-NEXT: vfma.f32 q0, q2, r11 1144; CHECK-NEXT: vfma.f32 q0, q3, r9 1145; CHECK-NEXT: vfma.f32 q0, q1, r1 1146; CHECK-NEXT: le lr, .LBB16_7 1147; CHECK-NEXT: b .LBB16_3 1148; CHECK-NEXT: .LBB16_8: @ in Loop: Header=BB16_5 Depth=1 1149; CHECK-NEXT: ldr r7, [sp, #8] @ 4-byte Reload 1150; CHECK-NEXT: b .LBB16_3 1151; CHECK-NEXT: .LBB16_9: @ %while.body76.preheader 1152; CHECK-NEXT: @ in Loop: Header=BB16_5 Depth=1 1153; CHECK-NEXT: mov r3, r4 1154; CHECK-NEXT: .LBB16_10: @ %while.body76 1155; CHECK-NEXT: @ Parent Loop BB16_5 Depth=1 1156; CHECK-NEXT: @ => This Inner Loop Header: Depth=2 1157; CHECK-NEXT: ldr r0, [r7], #4 1158; CHECK-NEXT: vldrw.u32 q1, [r3], #4 1159; CHECK-NEXT: vfma.f32 q0, q1, r0 1160; CHECK-NEXT: le lr, .LBB16_10 1161; CHECK-NEXT: @ %bb.11: @ %while.end.loopexit 1162; CHECK-NEXT: @ in Loop: Header=BB16_5 Depth=1 1163; CHECK-NEXT: ldr r0, [sp, #20] @ 4-byte Reload 1164; CHECK-NEXT: add.w r4, r4, r0, lsl #2 1165; CHECK-NEXT: b .LBB16_4 1166; CHECK-NEXT: .LBB16_12: @ %if.end 1167; CHECK-NEXT: add sp, #32 1168; CHECK-NEXT: vpop {d8, d9, d10, d11, d12, d13} 1169; CHECK-NEXT: add sp, #4 1170; CHECK-NEXT: pop.w {r4, r5, r6, r7, r8, r9, r10, r11, pc} 1171entry: 1172 %pState1 = getelementptr inbounds %struct.arm_fir_instance_f32, %struct.arm_fir_instance_f32* %S, i32 0, i32 1 1173 %0 = load float*, float** %pState1, align 4 1174 %pCoeffs2 = getelementptr inbounds %struct.arm_fir_instance_f32, %struct.arm_fir_instance_f32* %S, i32 0, i32 2 1175 %1 = load float*, float** %pCoeffs2, align 4 1176 %numTaps3 = getelementptr inbounds %struct.arm_fir_instance_f32, %struct.arm_fir_instance_f32* %S, i32 0, i32 0 1177 %2 = load i16, i16* %numTaps3, align 4 1178 %conv = zext i16 %2 to i32 1179 %cmp = icmp ugt i32 %blockSize, 7 1180 br i1 %cmp, label %if.then, label %if.end 1181 1182if.then: ; preds = %entry 1183 %shr = lshr i32 %blockSize, 2 1184 %cmp5217 = icmp eq i32 %shr, 0 1185 br i1 %cmp5217, label %if.end, label %while.body.lr.ph 1186 1187while.body.lr.ph: ; preds = %if.then 1188 %sub = add nsw i32 %conv, -1 1189 %arrayidx = getelementptr inbounds float, float* %0, i32 %sub 1190 %incdec.ptr = getelementptr inbounds float, float* %1, i32 1 1191 %incdec.ptr7 = getelementptr inbounds float, float* %1, i32 2 1192 %incdec.ptr8 = getelementptr inbounds float, float* %1, i32 3 1193 %incdec.ptr9 = getelementptr inbounds float, float* %1, i32 4 1194 %incdec.ptr10 = getelementptr inbounds float, float* %1, i32 5 1195 %incdec.ptr11 = getelementptr inbounds float, float* %1, i32 6 1196 %incdec.ptr12 = getelementptr inbounds float, float* %1, i32 7 1197 %sub37 = add nsw i32 %conv, -8 1198 %div = sdiv i32 %sub37, 8 1199 %pCoeffsCur.0199 = getelementptr inbounds float, float* %1, i32 8 1200 %cmp38201 = icmp ugt i16 %2, 15 1201 %and = and i32 %sub37, 7 1202 %cmp74210 = icmp eq i32 %and, 0 1203 %idx.neg = sub nsw i32 0, %conv 1204 %3 = icmp sgt i32 %div, 1 1205 %smax = select i1 %3, i32 %div, i32 1 1206 br label %while.body 1207 1208while.body: ; preds = %while.body.lr.ph, %while.end 1209 %blkCnt.0222 = phi i32 [ %shr, %while.body.lr.ph ], [ %dec84, %while.end ] 1210 %pStateCur.0221 = phi float* [ %arrayidx, %while.body.lr.ph ], [ %add.ptr, %while.end ] 1211 %pSamples.0220 = phi float* [ %0, %while.body.lr.ph ], [ %add.ptr83, %while.end ] 1212 %pTempSrc.0219 = phi float* [ %pSrc, %while.body.lr.ph ], [ %add.ptr14, %while.end ] 1213 %pOutput.0218 = phi float* [ %pDst, %while.body.lr.ph ], [ %add.ptr81, %while.end ] 1214 %4 = load float, float* %1, align 4 1215 %5 = load float, float* %incdec.ptr, align 4 1216 %6 = load float, float* %incdec.ptr7, align 4 1217 %7 = load float, float* %incdec.ptr8, align 4 1218 %8 = load float, float* %incdec.ptr9, align 4 1219 %9 = load float, float* %incdec.ptr10, align 4 1220 %10 = load float, float* %incdec.ptr11, align 4 1221 %11 = load float, float* %incdec.ptr12, align 4 1222 %12 = bitcast float* %pTempSrc.0219 to <4 x float>* 1223 %13 = load <4 x float>, <4 x float>* %12, align 4 1224 %14 = bitcast float* %pStateCur.0221 to <4 x float>* 1225 store <4 x float> %13, <4 x float>* %14, align 4 1226 %add.ptr = getelementptr inbounds float, float* %pStateCur.0221, i32 4 1227 %add.ptr14 = getelementptr inbounds float, float* %pTempSrc.0219, i32 4 1228 %15 = bitcast float* %pSamples.0220 to <4 x float>* 1229 %16 = load <4 x float>, <4 x float>* %15, align 4 1230 %.splatinsert = insertelement <4 x float> undef, float %4, i32 0 1231 %.splat = shufflevector <4 x float> %.splatinsert, <4 x float> undef, <4 x i32> zeroinitializer 1232 %17 = fmul fast <4 x float> %16, %.splat 1233 %arrayidx15 = getelementptr inbounds float, float* %pSamples.0220, i32 1 1234 %18 = bitcast float* %arrayidx15 to <4 x float>* 1235 %19 = load <4 x float>, <4 x float>* %18, align 4 1236 %.splatinsert16 = insertelement <4 x float> undef, float %5, i32 0 1237 %.splat17 = shufflevector <4 x float> %.splatinsert16, <4 x float> undef, <4 x i32> zeroinitializer 1238 %20 = tail call fast <4 x float> @llvm.fma.v4f32(<4 x float> %19, <4 x float> %.splat17, <4 x float> %17) 1239 %arrayidx18 = getelementptr inbounds float, float* %pSamples.0220, i32 2 1240 %21 = bitcast float* %arrayidx18 to <4 x float>* 1241 %22 = load <4 x float>, <4 x float>* %21, align 4 1242 %.splatinsert19 = insertelement <4 x float> undef, float %6, i32 0 1243 %.splat20 = shufflevector <4 x float> %.splatinsert19, <4 x float> undef, <4 x i32> zeroinitializer 1244 %23 = tail call fast <4 x float> @llvm.fma.v4f32(<4 x float> %22, <4 x float> %.splat20, <4 x float> %20) 1245 %arrayidx21 = getelementptr inbounds float, float* %pSamples.0220, i32 3 1246 %24 = bitcast float* %arrayidx21 to <4 x float>* 1247 %25 = load <4 x float>, <4 x float>* %24, align 4 1248 %.splatinsert22 = insertelement <4 x float> undef, float %7, i32 0 1249 %.splat23 = shufflevector <4 x float> %.splatinsert22, <4 x float> undef, <4 x i32> zeroinitializer 1250 %26 = tail call fast <4 x float> @llvm.fma.v4f32(<4 x float> %25, <4 x float> %.splat23, <4 x float> %23) 1251 %arrayidx24 = getelementptr inbounds float, float* %pSamples.0220, i32 4 1252 %27 = bitcast float* %arrayidx24 to <4 x float>* 1253 %28 = load <4 x float>, <4 x float>* %27, align 4 1254 %.splatinsert25 = insertelement <4 x float> undef, float %8, i32 0 1255 %.splat26 = shufflevector <4 x float> %.splatinsert25, <4 x float> undef, <4 x i32> zeroinitializer 1256 %29 = tail call fast <4 x float> @llvm.fma.v4f32(<4 x float> %28, <4 x float> %.splat26, <4 x float> %26) 1257 %arrayidx27 = getelementptr inbounds float, float* %pSamples.0220, i32 5 1258 %30 = bitcast float* %arrayidx27 to <4 x float>* 1259 %31 = load <4 x float>, <4 x float>* %30, align 4 1260 %.splatinsert28 = insertelement <4 x float> undef, float %9, i32 0 1261 %.splat29 = shufflevector <4 x float> %.splatinsert28, <4 x float> undef, <4 x i32> zeroinitializer 1262 %32 = tail call fast <4 x float> @llvm.fma.v4f32(<4 x float> %31, <4 x float> %.splat29, <4 x float> %29) 1263 %arrayidx30 = getelementptr inbounds float, float* %pSamples.0220, i32 6 1264 %33 = bitcast float* %arrayidx30 to <4 x float>* 1265 %34 = load <4 x float>, <4 x float>* %33, align 4 1266 %.splatinsert31 = insertelement <4 x float> undef, float %10, i32 0 1267 %.splat32 = shufflevector <4 x float> %.splatinsert31, <4 x float> undef, <4 x i32> zeroinitializer 1268 %35 = tail call fast <4 x float> @llvm.fma.v4f32(<4 x float> %34, <4 x float> %.splat32, <4 x float> %32) 1269 %arrayidx33 = getelementptr inbounds float, float* %pSamples.0220, i32 7 1270 %36 = bitcast float* %arrayidx33 to <4 x float>* 1271 %37 = load <4 x float>, <4 x float>* %36, align 4 1272 %.splatinsert34 = insertelement <4 x float> undef, float %11, i32 0 1273 %.splat35 = shufflevector <4 x float> %.splatinsert34, <4 x float> undef, <4 x i32> zeroinitializer 1274 %38 = tail call fast <4 x float> @llvm.fma.v4f32(<4 x float> %37, <4 x float> %.splat35, <4 x float> %35) 1275 %pSamples.1200 = getelementptr inbounds float, float* %pSamples.0220, i32 8 1276 br i1 %cmp38201, label %for.body, label %for.end 1277 1278for.body: ; preds = %while.body, %for.body 1279 %pSamples.1207 = phi float* [ %pSamples.1, %for.body ], [ %pSamples.1200, %while.body ] 1280 %pCoeffsCur.0206 = phi float* [ %pCoeffsCur.0, %for.body ], [ %pCoeffsCur.0199, %while.body ] 1281 %.pn205 = phi float* [ %pCoeffsCur.0206, %for.body ], [ %1, %while.body ] 1282 %i.0204 = phi i32 [ %inc, %for.body ], [ 0, %while.body ] 1283 %vecAcc0.0203 = phi <4 x float> [ %70, %for.body ], [ %38, %while.body ] 1284 %pSamples.0.pn202 = phi float* [ %pSamples.1207, %for.body ], [ %pSamples.0220, %while.body ] 1285 %incdec.ptr40 = getelementptr inbounds float, float* %.pn205, i32 9 1286 %39 = load float, float* %pCoeffsCur.0206, align 4 1287 %incdec.ptr41 = getelementptr inbounds float, float* %.pn205, i32 10 1288 %40 = load float, float* %incdec.ptr40, align 4 1289 %incdec.ptr42 = getelementptr inbounds float, float* %.pn205, i32 11 1290 %41 = load float, float* %incdec.ptr41, align 4 1291 %incdec.ptr43 = getelementptr inbounds float, float* %.pn205, i32 12 1292 %42 = load float, float* %incdec.ptr42, align 4 1293 %incdec.ptr44 = getelementptr inbounds float, float* %.pn205, i32 13 1294 %43 = load float, float* %incdec.ptr43, align 4 1295 %incdec.ptr45 = getelementptr inbounds float, float* %.pn205, i32 14 1296 %44 = load float, float* %incdec.ptr44, align 4 1297 %incdec.ptr46 = getelementptr inbounds float, float* %.pn205, i32 15 1298 %45 = load float, float* %incdec.ptr45, align 4 1299 %46 = load float, float* %incdec.ptr46, align 4 1300 %47 = bitcast float* %pSamples.1207 to <4 x float>* 1301 %48 = load <4 x float>, <4 x float>* %47, align 4 1302 %.splatinsert48 = insertelement <4 x float> undef, float %39, i32 0 1303 %.splat49 = shufflevector <4 x float> %.splatinsert48, <4 x float> undef, <4 x i32> zeroinitializer 1304 %49 = tail call fast <4 x float> @llvm.fma.v4f32(<4 x float> %48, <4 x float> %.splat49, <4 x float> %vecAcc0.0203) 1305 %arrayidx50 = getelementptr inbounds float, float* %pSamples.0.pn202, i32 9 1306 %50 = bitcast float* %arrayidx50 to <4 x float>* 1307 %51 = load <4 x float>, <4 x float>* %50, align 4 1308 %.splatinsert51 = insertelement <4 x float> undef, float %40, i32 0 1309 %.splat52 = shufflevector <4 x float> %.splatinsert51, <4 x float> undef, <4 x i32> zeroinitializer 1310 %52 = tail call fast <4 x float> @llvm.fma.v4f32(<4 x float> %51, <4 x float> %.splat52, <4 x float> %49) 1311 %arrayidx53 = getelementptr inbounds float, float* %pSamples.0.pn202, i32 10 1312 %53 = bitcast float* %arrayidx53 to <4 x float>* 1313 %54 = load <4 x float>, <4 x float>* %53, align 4 1314 %.splatinsert54 = insertelement <4 x float> undef, float %41, i32 0 1315 %.splat55 = shufflevector <4 x float> %.splatinsert54, <4 x float> undef, <4 x i32> zeroinitializer 1316 %55 = tail call fast <4 x float> @llvm.fma.v4f32(<4 x float> %54, <4 x float> %.splat55, <4 x float> %52) 1317 %arrayidx56 = getelementptr inbounds float, float* %pSamples.0.pn202, i32 11 1318 %56 = bitcast float* %arrayidx56 to <4 x float>* 1319 %57 = load <4 x float>, <4 x float>* %56, align 4 1320 %.splatinsert57 = insertelement <4 x float> undef, float %42, i32 0 1321 %.splat58 = shufflevector <4 x float> %.splatinsert57, <4 x float> undef, <4 x i32> zeroinitializer 1322 %58 = tail call fast <4 x float> @llvm.fma.v4f32(<4 x float> %57, <4 x float> %.splat58, <4 x float> %55) 1323 %arrayidx59 = getelementptr inbounds float, float* %pSamples.0.pn202, i32 12 1324 %59 = bitcast float* %arrayidx59 to <4 x float>* 1325 %60 = load <4 x float>, <4 x float>* %59, align 4 1326 %.splatinsert60 = insertelement <4 x float> undef, float %43, i32 0 1327 %.splat61 = shufflevector <4 x float> %.splatinsert60, <4 x float> undef, <4 x i32> zeroinitializer 1328 %61 = tail call fast <4 x float> @llvm.fma.v4f32(<4 x float> %60, <4 x float> %.splat61, <4 x float> %58) 1329 %arrayidx62 = getelementptr inbounds float, float* %pSamples.0.pn202, i32 13 1330 %62 = bitcast float* %arrayidx62 to <4 x float>* 1331 %63 = load <4 x float>, <4 x float>* %62, align 4 1332 %.splatinsert63 = insertelement <4 x float> undef, float %44, i32 0 1333 %.splat64 = shufflevector <4 x float> %.splatinsert63, <4 x float> undef, <4 x i32> zeroinitializer 1334 %64 = tail call fast <4 x float> @llvm.fma.v4f32(<4 x float> %63, <4 x float> %.splat64, <4 x float> %61) 1335 %arrayidx65 = getelementptr inbounds float, float* %pSamples.0.pn202, i32 14 1336 %65 = bitcast float* %arrayidx65 to <4 x float>* 1337 %66 = load <4 x float>, <4 x float>* %65, align 4 1338 %.splatinsert66 = insertelement <4 x float> undef, float %45, i32 0 1339 %.splat67 = shufflevector <4 x float> %.splatinsert66, <4 x float> undef, <4 x i32> zeroinitializer 1340 %67 = tail call fast <4 x float> @llvm.fma.v4f32(<4 x float> %66, <4 x float> %.splat67, <4 x float> %64) 1341 %arrayidx68 = getelementptr inbounds float, float* %pSamples.0.pn202, i32 15 1342 %68 = bitcast float* %arrayidx68 to <4 x float>* 1343 %69 = load <4 x float>, <4 x float>* %68, align 4 1344 %.splatinsert69 = insertelement <4 x float> undef, float %46, i32 0 1345 %.splat70 = shufflevector <4 x float> %.splatinsert69, <4 x float> undef, <4 x i32> zeroinitializer 1346 %70 = tail call fast <4 x float> @llvm.fma.v4f32(<4 x float> %69, <4 x float> %.splat70, <4 x float> %67) 1347 %inc = add nuw nsw i32 %i.0204, 1 1348 %pCoeffsCur.0 = getelementptr inbounds float, float* %pCoeffsCur.0206, i32 8 1349 %pSamples.1 = getelementptr inbounds float, float* %pSamples.1207, i32 8 1350 %exitcond = icmp eq i32 %inc, %smax 1351 br i1 %exitcond, label %for.end, label %for.body 1352 1353for.end: ; preds = %for.body, %while.body 1354 %vecAcc0.0.lcssa = phi <4 x float> [ %38, %while.body ], [ %70, %for.body ] 1355 %pCoeffsCur.0.lcssa = phi float* [ %pCoeffsCur.0199, %while.body ], [ %pCoeffsCur.0, %for.body ] 1356 %pSamples.1.lcssa = phi float* [ %pSamples.1200, %while.body ], [ %pSamples.1, %for.body ] 1357 br i1 %cmp74210, label %while.end, label %while.body76 1358 1359while.body76: ; preds = %for.end, %while.body76 1360 %pCoeffsCur.1214 = phi float* [ %incdec.ptr77, %while.body76 ], [ %pCoeffsCur.0.lcssa, %for.end ] 1361 %vecAcc0.1213 = phi <4 x float> [ %74, %while.body76 ], [ %vecAcc0.0.lcssa, %for.end ] 1362 %numCnt.0212 = phi i32 [ %dec, %while.body76 ], [ %and, %for.end ] 1363 %pSamples.2211 = phi float* [ %incdec.ptr80, %while.body76 ], [ %pSamples.1.lcssa, %for.end ] 1364 %incdec.ptr77 = getelementptr inbounds float, float* %pCoeffsCur.1214, i32 1 1365 %71 = load float, float* %pCoeffsCur.1214, align 4 1366 %72 = bitcast float* %pSamples.2211 to <4 x float>* 1367 %73 = load <4 x float>, <4 x float>* %72, align 4 1368 %.splatinsert78 = insertelement <4 x float> undef, float %71, i32 0 1369 %.splat79 = shufflevector <4 x float> %.splatinsert78, <4 x float> undef, <4 x i32> zeroinitializer 1370 %74 = tail call fast <4 x float> @llvm.fma.v4f32(<4 x float> %73, <4 x float> %.splat79, <4 x float> %vecAcc0.1213) 1371 %incdec.ptr80 = getelementptr inbounds float, float* %pSamples.2211, i32 1 1372 %dec = add nsw i32 %numCnt.0212, -1 1373 %cmp74 = icmp sgt i32 %numCnt.0212, 1 1374 br i1 %cmp74, label %while.body76, label %while.end.loopexit 1375 1376while.end.loopexit: ; preds = %while.body76 1377 %scevgep = getelementptr float, float* %pSamples.1.lcssa, i32 %and 1378 br label %while.end 1379 1380while.end: ; preds = %while.end.loopexit, %for.end 1381 %pSamples.2.lcssa = phi float* [ %pSamples.1.lcssa, %for.end ], [ %scevgep, %while.end.loopexit ] 1382 %vecAcc0.1.lcssa = phi <4 x float> [ %vecAcc0.0.lcssa, %for.end ], [ %74, %while.end.loopexit ] 1383 %75 = bitcast float* %pOutput.0218 to <4 x float>* 1384 store <4 x float> %vecAcc0.1.lcssa, <4 x float>* %75, align 4 1385 %add.ptr81 = getelementptr inbounds float, float* %pOutput.0218, i32 4 1386 %add.ptr82 = getelementptr inbounds float, float* %pSamples.2.lcssa, i32 4 1387 %add.ptr83 = getelementptr inbounds float, float* %add.ptr82, i32 %idx.neg 1388 %dec84 = add nsw i32 %blkCnt.0222, -1 1389 %cmp5 = icmp eq i32 %dec84, 0 1390 br i1 %cmp5, label %if.end, label %while.body 1391 1392if.end: ; preds = %while.end, %if.then, %entry 1393 ret void 1394} 1395 1396%struct.arm_biquad_cascade_stereo_df2T_instance_f32 = type { i8, float*, float* } 1397define arm_aapcs_vfpcc void @arm_biquad_cascade_stereo_df2T_f32(%struct.arm_biquad_cascade_stereo_df2T_instance_f32* nocapture readonly %0, float* %1, float* %2, i32 %3) { 1398; CHECK-LABEL: arm_biquad_cascade_stereo_df2T_f32: 1399; CHECK: @ %bb.0: 1400; CHECK-NEXT: .save {r4, r5, r6, r7, r8, lr} 1401; CHECK-NEXT: push.w {r4, r5, r6, r7, r8, lr} 1402; CHECK-NEXT: .vsave {d8, d9, d10, d11} 1403; CHECK-NEXT: vpush {d8, d9, d10, d11} 1404; CHECK-NEXT: .pad #24 1405; CHECK-NEXT: sub sp, #24 1406; CHECK-NEXT: mov r8, r3 1407; CHECK-NEXT: ldrb.w r12, [r0] 1408; CHECK-NEXT: ldrd r3, r0, [r0, #4] 1409; CHECK-NEXT: movs r4, #0 1410; CHECK-NEXT: cmp.w r8, #0 1411; CHECK-NEXT: strd r4, r4, [sp, #16] 1412; CHECK-NEXT: beq .LBB17_5 1413; CHECK-NEXT: @ %bb.1: 1414; CHECK-NEXT: movs r5, #2 1415; CHECK-NEXT: viwdup.u32 q0, r4, r5, #1 1416; CHECK-NEXT: mov r4, sp 1417; CHECK-NEXT: .LBB17_2: @ =>This Loop Header: Depth=1 1418; CHECK-NEXT: @ Child Loop BB17_3 Depth 2 1419; CHECK-NEXT: ldrd r5, r7, [r0] 1420; CHECK-NEXT: vldrw.u32 q1, [r3] 1421; CHECK-NEXT: vldr s8, [r0, #8] 1422; CHECK-NEXT: ldr r6, [r0, #12] 1423; CHECK-NEXT: vstrw.32 q1, [r4] 1424; CHECK-NEXT: vdup.32 q1, r7 1425; CHECK-NEXT: vldr s12, [r0, #16] 1426; CHECK-NEXT: vmov.f32 s6, s8 1427; CHECK-NEXT: dls lr, r8 1428; CHECK-NEXT: vmov.f32 s7, s8 1429; CHECK-NEXT: vdup.32 q2, r6 1430; CHECK-NEXT: vmov.f32 s10, s12 1431; CHECK-NEXT: mov r7, r2 1432; CHECK-NEXT: vmov.f32 s11, s12 1433; CHECK-NEXT: .LBB17_3: @ Parent Loop BB17_2 Depth=1 1434; CHECK-NEXT: @ => This Inner Loop Header: Depth=2 1435; CHECK-NEXT: vldrw.u32 q4, [r1, q0, uxtw #2] 1436; CHECK-NEXT: vldrw.u32 q5, [r4, q0, uxtw #2] 1437; CHECK-NEXT: vldrw.u32 q3, [sp, #8] 1438; CHECK-NEXT: adds r1, #8 1439; CHECK-NEXT: vfma.f32 q5, q4, r5 1440; CHECK-NEXT: vfma.f32 q3, q5, q2 1441; CHECK-NEXT: vstmia r7!, {s20, s21} 1442; CHECK-NEXT: vfma.f32 q3, q4, q1 1443; CHECK-NEXT: vstrw.32 q3, [r4] 1444; CHECK-NEXT: le lr, .LBB17_3 1445; CHECK-NEXT: @ %bb.4: @ in Loop: Header=BB17_2 Depth=1 1446; CHECK-NEXT: subs.w r12, r12, #1 1447; CHECK-NEXT: add.w r0, r0, #20 1448; CHECK-NEXT: vstrb.8 q3, [r3], #16 1449; CHECK-NEXT: mov r1, r2 1450; CHECK-NEXT: bne .LBB17_2 1451; CHECK-NEXT: b .LBB17_7 1452; CHECK-NEXT: .LBB17_5: @ %.preheader 1453; CHECK-NEXT: dls lr, r12 1454; CHECK-NEXT: mov r0, sp 1455; CHECK-NEXT: .LBB17_6: @ =>This Inner Loop Header: Depth=1 1456; CHECK-NEXT: vldrw.u32 q0, [r3], #16 1457; CHECK-NEXT: vstrw.32 q0, [r0] 1458; CHECK-NEXT: le lr, .LBB17_6 1459; CHECK-NEXT: .LBB17_7: 1460; CHECK-NEXT: add sp, #24 1461; CHECK-NEXT: vpop {d8, d9, d10, d11} 1462; CHECK-NEXT: pop.w {r4, r5, r6, r7, r8, pc} 1463 %5 = alloca [6 x float], align 4 1464 %6 = getelementptr inbounds %struct.arm_biquad_cascade_stereo_df2T_instance_f32, %struct.arm_biquad_cascade_stereo_df2T_instance_f32* %0, i32 0, i32 1 1465 %7 = load float*, float** %6, align 4 1466 %8 = getelementptr inbounds %struct.arm_biquad_cascade_stereo_df2T_instance_f32, %struct.arm_biquad_cascade_stereo_df2T_instance_f32* %0, i32 0, i32 2 1467 %9 = load float*, float** %8, align 4 1468 %10 = getelementptr inbounds %struct.arm_biquad_cascade_stereo_df2T_instance_f32, %struct.arm_biquad_cascade_stereo_df2T_instance_f32* %0, i32 0, i32 0 1469 %11 = load i8, i8* %10, align 4 1470 %12 = zext i8 %11 to i32 1471 %13 = bitcast [6 x float]* %5 to i8* 1472 call void @llvm.lifetime.start.p0i8(i64 24, i8* nonnull %13) #5 1473 %14 = tail call { <4 x i32>, i32 } @llvm.arm.mve.viwdup.v4i32(i32 0, i32 2, i32 1) 1474 %15 = extractvalue { <4 x i32>, i32 } %14, 0 1475 %16 = getelementptr inbounds [6 x float], [6 x float]* %5, i32 0, i32 4 1476 store float 0.000000e+00, float* %16, align 4 1477 %17 = getelementptr inbounds [6 x float], [6 x float]* %5, i32 0, i32 5 1478 store float 0.000000e+00, float* %17, align 4 1479 %18 = bitcast [6 x float]* %5 to <4 x float>* 1480 %19 = icmp eq i32 %3, 0 1481 %20 = bitcast [6 x float]* %5 to i32* 1482 %21 = getelementptr inbounds [6 x float], [6 x float]* %5, i32 0, i32 2 1483 %22 = bitcast float* %21 to <4 x float>* 1484 br i1 %19, label %23, label %31 1485 148623: ; preds = %4, %23 1487 %24 = phi i32 [ %29, %23 ], [ %12, %4 ] 1488 %25 = phi float* [ %28, %23 ], [ %7, %4 ] 1489 %26 = bitcast float* %25 to <4 x float>* 1490 %27 = load <4 x float>, <4 x float>* %26, align 8 1491 store <4 x float> %27, <4 x float>* %18, align 4 1492 %28 = getelementptr inbounds float, float* %25, i32 4 1493 %29 = add i32 %24, -1 1494 %30 = icmp eq i32 %29, 0 1495 br i1 %30, label %82, label %23 1496 149731: ; preds = %4, %77 1498 %32 = phi i32 [ %80, %77 ], [ %12, %4 ] 1499 %33 = phi float* [ %78, %77 ], [ %9, %4 ] 1500 %34 = phi float* [ %79, %77 ], [ %7, %4 ] 1501 %35 = phi float* [ %2, %77 ], [ %1, %4 ] 1502 %36 = getelementptr inbounds float, float* %33, i32 1 1503 %37 = load float, float* %33, align 4 1504 %38 = getelementptr inbounds float, float* %33, i32 2 1505 %39 = load float, float* %36, align 4 1506 %40 = getelementptr inbounds float, float* %33, i32 3 1507 %41 = load float, float* %38, align 4 1508 %42 = getelementptr inbounds float, float* %33, i32 4 1509 %43 = load float, float* %40, align 4 1510 %44 = load float, float* %42, align 4 1511 %45 = insertelement <4 x float> undef, float %43, i32 0 1512 %46 = shufflevector <4 x float> %45, <4 x float> undef, <4 x i32> <i32 0, i32 0, i32 undef, i32 undef> 1513 %47 = insertelement <4 x float> %46, float %44, i32 2 1514 %48 = insertelement <4 x float> %47, float %44, i32 3 1515 %49 = insertelement <4 x float> undef, float %39, i32 0 1516 %50 = shufflevector <4 x float> %49, <4 x float> undef, <4 x i32> <i32 0, i32 0, i32 undef, i32 undef> 1517 %51 = insertelement <4 x float> %50, float %41, i32 2 1518 %52 = insertelement <4 x float> %51, float %41, i32 3 1519 %53 = bitcast float* %34 to <4 x float>* 1520 %54 = load <4 x float>, <4 x float>* %53, align 8 1521 store <4 x float> %54, <4 x float>* %18, align 4 1522 %55 = insertelement <4 x float> undef, float %37, i32 0 1523 %56 = shufflevector <4 x float> %55, <4 x float> undef, <4 x i32> zeroinitializer 1524 br label %57 1525 152657: ; preds = %31, %57 1527 %58 = phi float* [ %35, %31 ], [ %74, %57 ] 1528 %59 = phi float* [ %2, %31 ], [ %70, %57 ] 1529 %60 = phi i32 [ %3, %31 ], [ %75, %57 ] 1530 %61 = call <4 x i32> @llvm.arm.mve.vldr.gather.offset.v4i32.p0i32.v4i32(i32* nonnull %20, <4 x i32> %15, i32 32, i32 2, i32 1) 1531 %62 = bitcast <4 x i32> %61 to <4 x float> 1532 %63 = bitcast float* %58 to i32* 1533 %64 = call <4 x i32> @llvm.arm.mve.vldr.gather.offset.v4i32.p0i32.v4i32(i32* %63, <4 x i32> %15, i32 32, i32 2, i32 1) 1534 %65 = bitcast <4 x i32> %64 to <4 x float> 1535 %66 = call fast <4 x float> @llvm.fma.v4f32(<4 x float> %65, <4 x float> %56, <4 x float> %62) 1536 %67 = extractelement <4 x float> %66, i32 0 1537 %68 = getelementptr inbounds float, float* %59, i32 1 1538 store float %67, float* %59, align 4 1539 %69 = extractelement <4 x float> %66, i32 1 1540 %70 = getelementptr inbounds float, float* %59, i32 2 1541 store float %69, float* %68, align 4 1542 %71 = load <4 x float>, <4 x float>* %22, align 4 1543 %72 = call fast <4 x float> @llvm.fma.v4f32(<4 x float> %66, <4 x float> %48, <4 x float> %71) 1544 %73 = call fast <4 x float> @llvm.fma.v4f32(<4 x float> %65, <4 x float> %52, <4 x float> %72) 1545 store <4 x float> %73, <4 x float>* %18, align 4 1546 %74 = getelementptr inbounds float, float* %58, i32 2 1547 %75 = add i32 %60, -1 1548 %76 = icmp eq i32 %75, 0 1549 br i1 %76, label %77, label %57 1550 155177: ; preds = %57 1552 %78 = getelementptr inbounds float, float* %33, i32 5 1553 store <4 x float> %73, <4 x float>* %53, align 4 1554 %79 = getelementptr inbounds float, float* %34, i32 4 1555 %80 = add i32 %32, -1 1556 %81 = icmp eq i32 %80, 0 1557 br i1 %81, label %82, label %31 1558 155982: ; preds = %77, %23 1560 call void @llvm.lifetime.end.p0i8(i64 24, i8* nonnull %13) #5 1561 ret void 1562} 1563 1564define arm_aapcs_vfpcc void @fms(float* nocapture readonly %pSrc1, float* nocapture readonly %pSrc2, float* nocapture readonly %pSrc3, float* nocapture %pDst, i32 %N, i32 %M) { 1565; CHECK-LABEL: fms: 1566; CHECK: @ %bb.0: @ %entry 1567; CHECK-NEXT: .save {r4, r5, r7, lr} 1568; CHECK-NEXT: push {r4, r5, r7, lr} 1569; CHECK-NEXT: ldr r4, [sp, #16] 1570; CHECK-NEXT: lsrs r5, r4, #2 1571; CHECK-NEXT: beq .LBB18_5 1572; CHECK-NEXT: @ %bb.1: @ %do.body.preheader 1573; CHECK-NEXT: ldr.w r12, [sp, #20] 1574; CHECK-NEXT: .LBB18_2: @ %do.body 1575; CHECK-NEXT: @ =>This Loop Header: Depth=1 1576; CHECK-NEXT: @ Child Loop BB18_3 Depth 2 1577; CHECK-NEXT: ldr r4, [r2] 1578; CHECK-NEXT: dls lr, r5 1579; CHECK-NEXT: vdup.32 q0, r4 1580; CHECK-NEXT: .LBB18_3: @ %while.body 1581; CHECK-NEXT: @ Parent Loop BB18_2 Depth=1 1582; CHECK-NEXT: @ => This Inner Loop Header: Depth=2 1583; CHECK-NEXT: vldrw.u32 q1, [r1], #16 1584; CHECK-NEXT: vldrw.u32 q2, [r0], #16 1585; CHECK-NEXT: vfms.f32 q2, q1, q0 1586; CHECK-NEXT: vstrb.8 q2, [r3], #16 1587; CHECK-NEXT: le lr, .LBB18_3 1588; CHECK-NEXT: @ %bb.4: @ %while.end 1589; CHECK-NEXT: @ in Loop: Header=BB18_2 Depth=1 1590; CHECK-NEXT: subs.w r12, r12, #1 1591; CHECK-NEXT: add.w r2, r2, #4 1592; CHECK-NEXT: bne .LBB18_2 1593; CHECK-NEXT: .LBB18_5: @ %do.end 1594; CHECK-NEXT: pop {r4, r5, r7, pc} 1595entry: 1596 %shr = lshr i32 %N, 2 1597 %cmp15 = icmp eq i32 %shr, 0 1598 br i1 %cmp15, label %do.end, label %do.body 1599 1600do.body: ; preds = %entry, %while.end 1601 %pDst.addr.0 = phi float* [ %add.ptr2, %while.end ], [ %pDst, %entry ] 1602 %M.addr.0 = phi i32 [ %dec3, %while.end ], [ %M, %entry ] 1603 %pSrc3.addr.0 = phi float* [ %incdec.ptr, %while.end ], [ %pSrc3, %entry ] 1604 %pSrc2.addr.0 = phi float* [ %add.ptr1, %while.end ], [ %pSrc2, %entry ] 1605 %pSrc1.addr.0 = phi float* [ %add.ptr, %while.end ], [ %pSrc1, %entry ] 1606 %0 = load float, float* %pSrc3.addr.0, align 4 1607 %.splatinsert = insertelement <4 x float> undef, float %0, i32 0 1608 %.splat = shufflevector <4 x float> %.splatinsert, <4 x float> undef, <4 x i32> zeroinitializer 1609 br label %while.body 1610 1611while.body: ; preds = %do.body, %while.body 1612 %pSrc1.addr.119 = phi float* [ %pSrc1.addr.0, %do.body ], [ %add.ptr, %while.body ] 1613 %pSrc2.addr.118 = phi float* [ %pSrc2.addr.0, %do.body ], [ %add.ptr1, %while.body ] 1614 %blkCnt.017 = phi i32 [ %shr, %do.body ], [ %dec, %while.body ] 1615 %pDst.addr.116 = phi float* [ %pDst.addr.0, %do.body ], [ %add.ptr2, %while.body ] 1616 %1 = bitcast float* %pSrc1.addr.119 to <4 x float>* 1617 %2 = load <4 x float>, <4 x float>* %1, align 4 1618 %3 = bitcast float* %pSrc2.addr.118 to <4 x float>* 1619 %4 = load <4 x float>, <4 x float>* %3, align 4 1620 %5 = fneg fast <4 x float> %4 1621 %6 = tail call fast <4 x float> @llvm.fma.v4f32(<4 x float> %.splat, <4 x float> %5, <4 x float> %2) 1622 %7 = bitcast float* %pDst.addr.116 to <4 x float>* 1623 store <4 x float> %6, <4 x float>* %7, align 4 1624 %add.ptr = getelementptr inbounds float, float* %pSrc1.addr.119, i32 4 1625 %add.ptr1 = getelementptr inbounds float, float* %pSrc2.addr.118, i32 4 1626 %add.ptr2 = getelementptr inbounds float, float* %pDst.addr.116, i32 4 1627 %dec = add nsw i32 %blkCnt.017, -1 1628 %cmp = icmp eq i32 %dec, 0 1629 br i1 %cmp, label %while.end, label %while.body 1630 1631while.end: ; preds = %while.body 1632 %incdec.ptr = getelementptr inbounds float, float* %pSrc3.addr.0, i32 1 1633 %dec3 = add i32 %M.addr.0, -1 1634 %cmp4 = icmp eq i32 %dec3, 0 1635 br i1 %cmp4, label %do.end, label %do.body 1636 1637do.end: ; preds = %while.end, %entry 1638 ret void 1639} 1640 1641 1642%struct.arm_biquad_casd_df1_inst_f32 = type { i32, float*, float* } 1643define arm_aapcs_vfpcc void @arm_biquad_cascade_df1_f32(%struct.arm_biquad_casd_df1_inst_f32* nocapture readonly %S, float* nocapture readonly %pSrc, float* nocapture %pDst, i32 %blockSize) { 1644; CHECK-LABEL: arm_biquad_cascade_df1_f32: 1645; CHECK: @ %bb.0: @ %entry 1646; CHECK-NEXT: .save {r4, r5, r6, r7, r8, r9, r10, r11, lr} 1647; CHECK-NEXT: push.w {r4, r5, r6, r7, r8, r9, r10, r11, lr} 1648; CHECK-NEXT: .pad #4 1649; CHECK-NEXT: sub sp, #4 1650; CHECK-NEXT: .vsave {d8, d9, d10, d11, d12, d13, d14, d15} 1651; CHECK-NEXT: vpush {d8, d9, d10, d11, d12, d13, d14, d15} 1652; CHECK-NEXT: .pad #64 1653; CHECK-NEXT: sub sp, #64 1654; CHECK-NEXT: ldrd r12, r10, [r0] 1655; CHECK-NEXT: @ implicit-def: $s2 1656; CHECK-NEXT: and r7, r3, #3 1657; CHECK-NEXT: ldr.w r9, [r0, #8] 1658; CHECK-NEXT: lsrs r0, r3, #2 1659; CHECK-NEXT: str r0, [sp] @ 4-byte Spill 1660; CHECK-NEXT: str r7, [sp, #4] @ 4-byte Spill 1661; CHECK-NEXT: str r2, [sp, #44] @ 4-byte Spill 1662; CHECK-NEXT: b .LBB19_3 1663; CHECK-NEXT: .LBB19_1: @ in Loop: Header=BB19_3 Depth=1 1664; CHECK-NEXT: vmov.f32 s14, s7 1665; CHECK-NEXT: ldr r2, [sp, #44] @ 4-byte Reload 1666; CHECK-NEXT: vmov.f32 s0, s10 1667; CHECK-NEXT: vmov.f32 s7, s6 1668; CHECK-NEXT: .LBB19_2: @ %if.end69 1669; CHECK-NEXT: @ in Loop: Header=BB19_3 Depth=1 1670; CHECK-NEXT: vstr s8, [r10] 1671; CHECK-NEXT: subs.w r12, r12, #1 1672; CHECK-NEXT: vstr s0, [r10, #4] 1673; CHECK-NEXT: add.w r9, r9, #128 1674; CHECK-NEXT: vstr s14, [r10, #8] 1675; CHECK-NEXT: mov r1, r2 1676; CHECK-NEXT: vstr s7, [r10, #12] 1677; CHECK-NEXT: add.w r10, r10, #16 1678; CHECK-NEXT: beq.w .LBB19_13 1679; CHECK-NEXT: .LBB19_3: @ %do.body 1680; CHECK-NEXT: @ =>This Loop Header: Depth=1 1681; CHECK-NEXT: @ Child Loop BB19_5 Depth 2 1682; CHECK-NEXT: vldr s7, [r10, #8] 1683; CHECK-NEXT: mov r5, r2 1684; CHECK-NEXT: ldr r0, [sp] @ 4-byte Reload 1685; CHECK-NEXT: vldr s8, [r10] 1686; CHECK-NEXT: vldr s10, [r10, #4] 1687; CHECK-NEXT: vldr s6, [r10, #12] 1688; CHECK-NEXT: wls lr, r0, .LBB19_6 1689; CHECK-NEXT: @ %bb.4: @ %while.body.lr.ph 1690; CHECK-NEXT: @ in Loop: Header=BB19_3 Depth=1 1691; CHECK-NEXT: ldr r5, [sp, #44] @ 4-byte Reload 1692; CHECK-NEXT: .LBB19_5: @ %while.body 1693; CHECK-NEXT: @ Parent Loop BB19_3 Depth=1 1694; CHECK-NEXT: @ => This Inner Loop Header: Depth=2 1695; CHECK-NEXT: vmov r4, s8 1696; CHECK-NEXT: vldr s8, [r1, #12] 1697; CHECK-NEXT: vldrw.u32 q0, [r9, #112] 1698; CHECK-NEXT: vmov r3, s10 1699; CHECK-NEXT: vldr s10, [r1, #8] 1700; CHECK-NEXT: vmov r7, s7 1701; CHECK-NEXT: vmov r11, s6 1702; CHECK-NEXT: vldrw.u32 q1, [r9] 1703; CHECK-NEXT: vstrw.32 q0, [sp, #48] @ 16-byte Spill 1704; CHECK-NEXT: vmov r8, s8 1705; CHECK-NEXT: vldrw.u32 q0, [r9, #16] 1706; CHECK-NEXT: ldr r6, [r1, #4] 1707; CHECK-NEXT: vldrw.u32 q7, [r9, #32] 1708; CHECK-NEXT: vmul.f32 q1, q1, r8 1709; CHECK-NEXT: vmov r0, s10 1710; CHECK-NEXT: vldrw.u32 q3, [r9, #48] 1711; CHECK-NEXT: vfma.f32 q1, q0, r0 1712; CHECK-NEXT: ldr r0, [r1], #16 1713; CHECK-NEXT: vfma.f32 q1, q7, r6 1714; CHECK-NEXT: vldrw.u32 q6, [r9, #64] 1715; CHECK-NEXT: vfma.f32 q1, q3, r0 1716; CHECK-NEXT: vldrw.u32 q5, [r9, #80] 1717; CHECK-NEXT: vfma.f32 q1, q6, r4 1718; CHECK-NEXT: vldrw.u32 q4, [r9, #96] 1719; CHECK-NEXT: vfma.f32 q1, q5, r3 1720; CHECK-NEXT: vldrw.u32 q0, [sp, #48] @ 16-byte Reload 1721; CHECK-NEXT: vfma.f32 q1, q4, r7 1722; CHECK-NEXT: vfma.f32 q1, q0, r11 1723; CHECK-NEXT: vmov.f32 s2, s8 1724; CHECK-NEXT: vstrb.8 q1, [r5], #16 1725; CHECK-NEXT: le lr, .LBB19_5 1726; CHECK-NEXT: .LBB19_6: @ %while.end 1727; CHECK-NEXT: @ in Loop: Header=BB19_3 Depth=1 1728; CHECK-NEXT: ldr r7, [sp, #4] @ 4-byte Reload 1729; CHECK-NEXT: cmp r7, #0 1730; CHECK-NEXT: beq .LBB19_1 1731; CHECK-NEXT: @ %bb.7: @ %if.then 1732; CHECK-NEXT: @ in Loop: Header=BB19_3 Depth=1 1733; CHECK-NEXT: vldr s24, [r1] 1734; CHECK-NEXT: vmov r0, s8 1735; CHECK-NEXT: vldr s0, [r1, #4] 1736; CHECK-NEXT: vldrw.u32 q3, [r9] 1737; CHECK-NEXT: vldr s3, [r1, #12] 1738; CHECK-NEXT: vldrw.u32 q4, [r9, #32] 1739; CHECK-NEXT: vldr s1, [r1, #8] 1740; CHECK-NEXT: vmov r1, s10 1741; CHECK-NEXT: vldrw.u32 q2, [r9, #96] 1742; CHECK-NEXT: vmov r6, s3 1743; CHECK-NEXT: vmul.f32 q3, q3, r6 1744; CHECK-NEXT: vmov r6, s1 1745; CHECK-NEXT: vstrw.32 q2, [sp, #24] @ 16-byte Spill 1746; CHECK-NEXT: vldrw.u32 q2, [r9, #112] 1747; CHECK-NEXT: vldrw.u32 q5, [r9, #48] 1748; CHECK-NEXT: vmov r4, s0 1749; CHECK-NEXT: vstrw.32 q2, [sp, #48] @ 16-byte Spill 1750; CHECK-NEXT: vldrw.u32 q2, [r9, #80] 1751; CHECK-NEXT: vldrw.u32 q7, [r9, #64] 1752; CHECK-NEXT: vmov r3, s24 1753; CHECK-NEXT: vstrw.32 q2, [sp, #8] @ 16-byte Spill 1754; CHECK-NEXT: vldrw.u32 q2, [r9, #16] 1755; CHECK-NEXT: vmov r2, s7 1756; CHECK-NEXT: cmp r7, #1 1757; CHECK-NEXT: vfma.f32 q3, q2, r6 1758; CHECK-NEXT: vldrw.u32 q2, [sp, #8] @ 16-byte Reload 1759; CHECK-NEXT: vfma.f32 q3, q4, r4 1760; CHECK-NEXT: vmov lr, s6 1761; CHECK-NEXT: vfma.f32 q3, q5, r3 1762; CHECK-NEXT: vfma.f32 q3, q7, r0 1763; CHECK-NEXT: vfma.f32 q3, q2, r1 1764; CHECK-NEXT: vldrw.u32 q2, [sp, #24] @ 16-byte Reload 1765; CHECK-NEXT: vfma.f32 q3, q2, r2 1766; CHECK-NEXT: vldrw.u32 q2, [sp, #48] @ 16-byte Reload 1767; CHECK-NEXT: vfma.f32 q3, q2, lr 1768; CHECK-NEXT: bne .LBB19_9 1769; CHECK-NEXT: @ %bb.8: @ %if.then58 1770; CHECK-NEXT: @ in Loop: Header=BB19_3 Depth=1 1771; CHECK-NEXT: vstr s12, [r5] 1772; CHECK-NEXT: vmov.f32 s8, s24 1773; CHECK-NEXT: vmov.f32 s0, s2 1774; CHECK-NEXT: vmov.f32 s14, s12 1775; CHECK-NEXT: b .LBB19_11 1776; CHECK-NEXT: .LBB19_9: @ %if.else 1777; CHECK-NEXT: @ in Loop: Header=BB19_3 Depth=1 1778; CHECK-NEXT: cmp r7, #2 1779; CHECK-NEXT: vstmia r5, {s12, s13} 1780; CHECK-NEXT: bne .LBB19_12 1781; CHECK-NEXT: @ %bb.10: @ in Loop: Header=BB19_3 Depth=1 1782; CHECK-NEXT: vmov.f32 s8, s0 1783; CHECK-NEXT: vmov.f32 s14, s13 1784; CHECK-NEXT: vmov.f32 s0, s24 1785; CHECK-NEXT: vmov.f32 s7, s12 1786; CHECK-NEXT: .LBB19_11: @ %if.end69 1787; CHECK-NEXT: @ in Loop: Header=BB19_3 Depth=1 1788; CHECK-NEXT: vmov.f32 s2, s3 1789; CHECK-NEXT: ldr r2, [sp, #44] @ 4-byte Reload 1790; CHECK-NEXT: b .LBB19_2 1791; CHECK-NEXT: .LBB19_12: @ %if.else64 1792; CHECK-NEXT: @ in Loop: Header=BB19_3 Depth=1 1793; CHECK-NEXT: vmov.f32 s7, s13 1794; CHECK-NEXT: ldr r2, [sp, #44] @ 4-byte Reload 1795; CHECK-NEXT: vmov.f32 s2, s3 1796; CHECK-NEXT: vstr s14, [r5, #8] 1797; CHECK-NEXT: vmov.f32 s8, s1 1798; CHECK-NEXT: b .LBB19_2 1799; CHECK-NEXT: .LBB19_13: @ %do.end 1800; CHECK-NEXT: add sp, #64 1801; CHECK-NEXT: vpop {d8, d9, d10, d11, d12, d13, d14, d15} 1802; CHECK-NEXT: add sp, #4 1803; CHECK-NEXT: pop.w {r4, r5, r6, r7, r8, r9, r10, r11, pc} 1804entry: 1805 %pState1 = getelementptr inbounds %struct.arm_biquad_casd_df1_inst_f32, %struct.arm_biquad_casd_df1_inst_f32* %S, i32 0, i32 1 1806 %0 = load float*, float** %pState1, align 4 1807 %pCoeffs2 = getelementptr inbounds %struct.arm_biquad_casd_df1_inst_f32, %struct.arm_biquad_casd_df1_inst_f32* %S, i32 0, i32 2 1808 %1 = load float*, float** %pCoeffs2, align 4 1809 %numStages = getelementptr inbounds %struct.arm_biquad_casd_df1_inst_f32, %struct.arm_biquad_casd_df1_inst_f32* %S, i32 0, i32 0 1810 %2 = load i32, i32* %numStages, align 4 1811 %shr = lshr i32 %blockSize, 2 1812 %cmp201 = icmp eq i32 %shr, 0 1813 %and = and i32 %blockSize, 3 1814 %tobool = icmp eq i32 %and, 0 1815 %cmp57 = icmp eq i32 %and, 1 1816 %cmp60 = icmp eq i32 %and, 2 1817 br label %do.body 1818 1819do.body: ; preds = %if.end69, %entry 1820 %pState.0 = phi float* [ %0, %entry ], [ %incdec.ptr73, %if.end69 ] 1821 %pCoeffs.0 = phi float* [ %1, %entry ], [ %add.ptr74, %if.end69 ] 1822 %pIn.0 = phi float* [ %pSrc, %entry ], [ %pDst, %if.end69 ] 1823 %X3.0 = phi float [ undef, %entry ], [ %X3.2, %if.end69 ] 1824 %stage.0 = phi i32 [ %2, %entry ], [ %dec75, %if.end69 ] 1825 %3 = load float, float* %pState.0, align 4 1826 %arrayidx3 = getelementptr inbounds float, float* %pState.0, i32 1 1827 %4 = load float, float* %arrayidx3, align 4 1828 %arrayidx4 = getelementptr inbounds float, float* %pState.0, i32 2 1829 %5 = load float, float* %arrayidx4, align 4 1830 %arrayidx5 = getelementptr inbounds float, float* %pState.0, i32 3 1831 %6 = load float, float* %arrayidx5, align 4 1832 br i1 %cmp201, label %while.end, label %while.body.lr.ph 1833 1834while.body.lr.ph: ; preds = %do.body 1835 %7 = bitcast float* %pCoeffs.0 to <4 x float>* 1836 %arrayidx9 = getelementptr inbounds float, float* %pCoeffs.0, i32 4 1837 %8 = bitcast float* %arrayidx9 to <4 x float>* 1838 %arrayidx12 = getelementptr inbounds float, float* %pCoeffs.0, i32 8 1839 %9 = bitcast float* %arrayidx12 to <4 x float>* 1840 %arrayidx15 = getelementptr inbounds float, float* %pCoeffs.0, i32 12 1841 %10 = bitcast float* %arrayidx15 to <4 x float>* 1842 %arrayidx18 = getelementptr inbounds float, float* %pCoeffs.0, i32 16 1843 %11 = bitcast float* %arrayidx18 to <4 x float>* 1844 %arrayidx21 = getelementptr inbounds float, float* %pCoeffs.0, i32 20 1845 %12 = bitcast float* %arrayidx21 to <4 x float>* 1846 %arrayidx24 = getelementptr inbounds float, float* %pCoeffs.0, i32 24 1847 %13 = bitcast float* %arrayidx24 to <4 x float>* 1848 %arrayidx27 = getelementptr inbounds float, float* %pCoeffs.0, i32 28 1849 %14 = bitcast float* %arrayidx27 to <4 x float>* 1850 br label %while.body 1851 1852while.body: ; preds = %while.body.lr.ph, %while.body 1853 %sample.0208 = phi i32 [ %shr, %while.body.lr.ph ], [ %dec, %while.body ] 1854 %pIn.1207 = phi float* [ %pIn.0, %while.body.lr.ph ], [ %incdec.ptr8, %while.body ] 1855 %pOut.1206 = phi float* [ %pDst, %while.body.lr.ph ], [ %add.ptr, %while.body ] 1856 %Yn2.0205 = phi float [ %6, %while.body.lr.ph ], [ %37, %while.body ] 1857 %Yn1.0204 = phi float [ %5, %while.body.lr.ph ], [ %36, %while.body ] 1858 %Xn2.0203 = phi float [ %4, %while.body.lr.ph ], [ %17, %while.body ] 1859 %Xn1.0202 = phi float [ %3, %while.body.lr.ph ], [ %18, %while.body ] 1860 %incdec.ptr = getelementptr inbounds float, float* %pIn.1207, i32 1 1861 %15 = load float, float* %pIn.1207, align 4 1862 %incdec.ptr6 = getelementptr inbounds float, float* %pIn.1207, i32 2 1863 %16 = load float, float* %incdec.ptr, align 4 1864 %incdec.ptr7 = getelementptr inbounds float, float* %pIn.1207, i32 3 1865 %17 = load float, float* %incdec.ptr6, align 4 1866 %incdec.ptr8 = getelementptr inbounds float, float* %pIn.1207, i32 4 1867 %18 = load float, float* %incdec.ptr7, align 4 1868 %19 = load <4 x float>, <4 x float>* %7, align 4 1869 %.splatinsert = insertelement <4 x float> undef, float %18, i32 0 1870 %.splat = shufflevector <4 x float> %.splatinsert, <4 x float> undef, <4 x i32> zeroinitializer 1871 %20 = fmul fast <4 x float> %.splat, %19 1872 %21 = load <4 x float>, <4 x float>* %8, align 4 1873 %.splatinsert10 = insertelement <4 x float> undef, float %17, i32 0 1874 %.splat11 = shufflevector <4 x float> %.splatinsert10, <4 x float> undef, <4 x i32> zeroinitializer 1875 %22 = tail call fast <4 x float> @llvm.fma.v4f32(<4 x float> %21, <4 x float> %.splat11, <4 x float> %20) 1876 %23 = load <4 x float>, <4 x float>* %9, align 4 1877 %.splatinsert13 = insertelement <4 x float> undef, float %16, i32 0 1878 %.splat14 = shufflevector <4 x float> %.splatinsert13, <4 x float> undef, <4 x i32> zeroinitializer 1879 %24 = tail call fast <4 x float> @llvm.fma.v4f32(<4 x float> %23, <4 x float> %.splat14, <4 x float> %22) 1880 %25 = load <4 x float>, <4 x float>* %10, align 4 1881 %.splatinsert16 = insertelement <4 x float> undef, float %15, i32 0 1882 %.splat17 = shufflevector <4 x float> %.splatinsert16, <4 x float> undef, <4 x i32> zeroinitializer 1883 %26 = tail call fast <4 x float> @llvm.fma.v4f32(<4 x float> %25, <4 x float> %.splat17, <4 x float> %24) 1884 %27 = load <4 x float>, <4 x float>* %11, align 4 1885 %.splatinsert19 = insertelement <4 x float> undef, float %Xn1.0202, i32 0 1886 %.splat20 = shufflevector <4 x float> %.splatinsert19, <4 x float> undef, <4 x i32> zeroinitializer 1887 %28 = tail call fast <4 x float> @llvm.fma.v4f32(<4 x float> %27, <4 x float> %.splat20, <4 x float> %26) 1888 %29 = load <4 x float>, <4 x float>* %12, align 4 1889 %.splatinsert22 = insertelement <4 x float> undef, float %Xn2.0203, i32 0 1890 %.splat23 = shufflevector <4 x float> %.splatinsert22, <4 x float> undef, <4 x i32> zeroinitializer 1891 %30 = tail call fast <4 x float> @llvm.fma.v4f32(<4 x float> %29, <4 x float> %.splat23, <4 x float> %28) 1892 %31 = load <4 x float>, <4 x float>* %13, align 4 1893 %.splatinsert25 = insertelement <4 x float> undef, float %Yn1.0204, i32 0 1894 %.splat26 = shufflevector <4 x float> %.splatinsert25, <4 x float> undef, <4 x i32> zeroinitializer 1895 %32 = tail call fast <4 x float> @llvm.fma.v4f32(<4 x float> %31, <4 x float> %.splat26, <4 x float> %30) 1896 %33 = load <4 x float>, <4 x float>* %14, align 4 1897 %.splatinsert28 = insertelement <4 x float> undef, float %Yn2.0205, i32 0 1898 %.splat29 = shufflevector <4 x float> %.splatinsert28, <4 x float> undef, <4 x i32> zeroinitializer 1899 %34 = tail call fast <4 x float> @llvm.fma.v4f32(<4 x float> %33, <4 x float> %.splat29, <4 x float> %32) 1900 %35 = bitcast float* %pOut.1206 to <4 x float>* 1901 store <4 x float> %34, <4 x float>* %35, align 4 1902 %add.ptr = getelementptr inbounds float, float* %pOut.1206, i32 4 1903 %36 = extractelement <4 x float> %34, i32 3 1904 %37 = extractelement <4 x float> %34, i32 2 1905 %dec = add nsw i32 %sample.0208, -1 1906 %cmp = icmp eq i32 %dec, 0 1907 br i1 %cmp, label %while.end, label %while.body 1908 1909while.end: ; preds = %while.body, %do.body 1910 %Xn1.0.lcssa = phi float [ %3, %do.body ], [ %18, %while.body ] 1911 %Xn2.0.lcssa = phi float [ %4, %do.body ], [ %17, %while.body ] 1912 %Yn1.0.lcssa = phi float [ %5, %do.body ], [ %36, %while.body ] 1913 %Yn2.0.lcssa = phi float [ %6, %do.body ], [ %37, %while.body ] 1914 %pOut.1.lcssa = phi float* [ %pDst, %do.body ], [ %add.ptr, %while.body ] 1915 %pIn.1.lcssa = phi float* [ %pIn.0, %do.body ], [ %incdec.ptr8, %while.body ] 1916 %X3.1.lcssa = phi float [ %X3.0, %do.body ], [ %18, %while.body ] 1917 br i1 %tobool, label %if.end69, label %if.then 1918 1919if.then: ; preds = %while.end 1920 %incdec.ptr30 = getelementptr inbounds float, float* %pIn.1.lcssa, i32 1 1921 %38 = load float, float* %pIn.1.lcssa, align 4 1922 %incdec.ptr31 = getelementptr inbounds float, float* %pIn.1.lcssa, i32 2 1923 %39 = load float, float* %incdec.ptr30, align 4 1924 %incdec.ptr32 = getelementptr inbounds float, float* %pIn.1.lcssa, i32 3 1925 %40 = load float, float* %incdec.ptr31, align 4 1926 %41 = load float, float* %incdec.ptr32, align 4 1927 %42 = bitcast float* %pCoeffs.0 to <4 x float>* 1928 %43 = load <4 x float>, <4 x float>* %42, align 4 1929 %.splatinsert34 = insertelement <4 x float> undef, float %41, i32 0 1930 %.splat35 = shufflevector <4 x float> %.splatinsert34, <4 x float> undef, <4 x i32> zeroinitializer 1931 %44 = fmul fast <4 x float> %.splat35, %43 1932 %arrayidx36 = getelementptr inbounds float, float* %pCoeffs.0, i32 4 1933 %45 = bitcast float* %arrayidx36 to <4 x float>* 1934 %46 = load <4 x float>, <4 x float>* %45, align 4 1935 %.splatinsert37 = insertelement <4 x float> undef, float %40, i32 0 1936 %.splat38 = shufflevector <4 x float> %.splatinsert37, <4 x float> undef, <4 x i32> zeroinitializer 1937 %47 = tail call fast <4 x float> @llvm.fma.v4f32(<4 x float> %46, <4 x float> %.splat38, <4 x float> %44) 1938 %arrayidx39 = getelementptr inbounds float, float* %pCoeffs.0, i32 8 1939 %48 = bitcast float* %arrayidx39 to <4 x float>* 1940 %49 = load <4 x float>, <4 x float>* %48, align 4 1941 %.splatinsert40 = insertelement <4 x float> undef, float %39, i32 0 1942 %.splat41 = shufflevector <4 x float> %.splatinsert40, <4 x float> undef, <4 x i32> zeroinitializer 1943 %50 = tail call fast <4 x float> @llvm.fma.v4f32(<4 x float> %49, <4 x float> %.splat41, <4 x float> %47) 1944 %arrayidx42 = getelementptr inbounds float, float* %pCoeffs.0, i32 12 1945 %51 = bitcast float* %arrayidx42 to <4 x float>* 1946 %52 = load <4 x float>, <4 x float>* %51, align 4 1947 %.splatinsert43 = insertelement <4 x float> undef, float %38, i32 0 1948 %.splat44 = shufflevector <4 x float> %.splatinsert43, <4 x float> undef, <4 x i32> zeroinitializer 1949 %53 = tail call fast <4 x float> @llvm.fma.v4f32(<4 x float> %52, <4 x float> %.splat44, <4 x float> %50) 1950 %arrayidx45 = getelementptr inbounds float, float* %pCoeffs.0, i32 16 1951 %54 = bitcast float* %arrayidx45 to <4 x float>* 1952 %55 = load <4 x float>, <4 x float>* %54, align 4 1953 %.splatinsert46 = insertelement <4 x float> undef, float %Xn1.0.lcssa, i32 0 1954 %.splat47 = shufflevector <4 x float> %.splatinsert46, <4 x float> undef, <4 x i32> zeroinitializer 1955 %56 = tail call fast <4 x float> @llvm.fma.v4f32(<4 x float> %55, <4 x float> %.splat47, <4 x float> %53) 1956 %arrayidx48 = getelementptr inbounds float, float* %pCoeffs.0, i32 20 1957 %57 = bitcast float* %arrayidx48 to <4 x float>* 1958 %58 = load <4 x float>, <4 x float>* %57, align 4 1959 %.splatinsert49 = insertelement <4 x float> undef, float %Xn2.0.lcssa, i32 0 1960 %.splat50 = shufflevector <4 x float> %.splatinsert49, <4 x float> undef, <4 x i32> zeroinitializer 1961 %59 = tail call fast <4 x float> @llvm.fma.v4f32(<4 x float> %58, <4 x float> %.splat50, <4 x float> %56) 1962 %arrayidx51 = getelementptr inbounds float, float* %pCoeffs.0, i32 24 1963 %60 = bitcast float* %arrayidx51 to <4 x float>* 1964 %61 = load <4 x float>, <4 x float>* %60, align 4 1965 %.splatinsert52 = insertelement <4 x float> undef, float %Yn1.0.lcssa, i32 0 1966 %.splat53 = shufflevector <4 x float> %.splatinsert52, <4 x float> undef, <4 x i32> zeroinitializer 1967 %62 = tail call fast <4 x float> @llvm.fma.v4f32(<4 x float> %61, <4 x float> %.splat53, <4 x float> %59) 1968 %arrayidx54 = getelementptr inbounds float, float* %pCoeffs.0, i32 28 1969 %63 = bitcast float* %arrayidx54 to <4 x float>* 1970 %64 = load <4 x float>, <4 x float>* %63, align 4 1971 %.splatinsert55 = insertelement <4 x float> undef, float %Yn2.0.lcssa, i32 0 1972 %.splat56 = shufflevector <4 x float> %.splatinsert55, <4 x float> undef, <4 x i32> zeroinitializer 1973 %65 = tail call fast <4 x float> @llvm.fma.v4f32(<4 x float> %64, <4 x float> %.splat56, <4 x float> %62) 1974 %66 = extractelement <4 x float> %65, i32 0 1975 br i1 %cmp57, label %if.then58, label %if.else 1976 1977if.then58: ; preds = %if.then 1978 store float %66, float* %pOut.1.lcssa, align 4 1979 br label %if.end69 1980 1981if.else: ; preds = %if.then 1982 %incdec.ptr62 = getelementptr inbounds float, float* %pOut.1.lcssa, i32 1 1983 store float %66, float* %pOut.1.lcssa, align 4 1984 %67 = extractelement <4 x float> %65, i32 1 1985 store float %67, float* %incdec.ptr62, align 4 1986 br i1 %cmp60, label %if.end69, label %if.else64 1987 1988if.else64: ; preds = %if.else 1989 %incdec.ptr63 = getelementptr inbounds float, float* %pOut.1.lcssa, i32 2 1990 %68 = extractelement <4 x float> %65, i32 2 1991 store float %68, float* %incdec.ptr63, align 4 1992 br label %if.end69 1993 1994if.end69: ; preds = %if.else, %while.end, %if.then58, %if.else64 1995 %Xn1.1 = phi float [ %38, %if.then58 ], [ %40, %if.else64 ], [ %Xn1.0.lcssa, %while.end ], [ %39, %if.else ] 1996 %Xn2.1 = phi float [ %X3.1.lcssa, %if.then58 ], [ %39, %if.else64 ], [ %Xn2.0.lcssa, %while.end ], [ %38, %if.else ] 1997 %Yn1.1 = phi float [ %66, %if.then58 ], [ %68, %if.else64 ], [ %Yn1.0.lcssa, %while.end ], [ %67, %if.else ] 1998 %Yn2.1 = phi float [ %Yn1.0.lcssa, %if.then58 ], [ %67, %if.else64 ], [ %Yn2.0.lcssa, %while.end ], [ %66, %if.else ] 1999 %X3.2 = phi float [ %41, %if.then58 ], [ %41, %if.else64 ], [ %X3.1.lcssa, %while.end ], [ %41, %if.else ] 2000 store float %Xn1.1, float* %pState.0, align 4 2001 store float %Xn2.1, float* %arrayidx3, align 4 2002 store float %Yn1.1, float* %arrayidx4, align 4 2003 %incdec.ptr73 = getelementptr inbounds float, float* %pState.0, i32 4 2004 store float %Yn2.1, float* %arrayidx5, align 4 2005 %add.ptr74 = getelementptr inbounds float, float* %pCoeffs.0, i32 32 2006 %dec75 = add i32 %stage.0, -1 2007 %cmp76 = icmp eq i32 %dec75, 0 2008 br i1 %cmp76, label %do.end, label %do.body 2009 2010do.end: ; preds = %if.end69 2011 ret void 2012} 2013 2014 2015%struct.arm_biquad_cascade_df2T_instance_f32 = type { i8, float*, float* } 2016define void @arm_biquad_cascade_df2T_f32(%struct.arm_biquad_cascade_df2T_instance_f32* nocapture readonly %S, float* nocapture readonly %pSrc, float* nocapture %pDst, i32 %blockSize) { 2017; CHECK-LABEL: arm_biquad_cascade_df2T_f32: 2018; CHECK: @ %bb.0: @ %entry 2019; CHECK-NEXT: .save {r4, r5, r6, r7, r8, lr} 2020; CHECK-NEXT: push.w {r4, r5, r6, r7, r8, lr} 2021; CHECK-NEXT: .vsave {d8, d9, d10, d11, d12, d13} 2022; CHECK-NEXT: vpush {d8, d9, d10, d11, d12, d13} 2023; CHECK-NEXT: ldrd r12, r6, [r0, #4] 2024; CHECK-NEXT: and r8, r3, #1 2025; CHECK-NEXT: ldrb r0, [r0] 2026; CHECK-NEXT: lsrs r3, r3, #1 2027; CHECK-NEXT: vldr s0, .LCPI20_0 2028; CHECK-NEXT: b .LBB20_3 2029; CHECK-NEXT: .LBB20_1: @ %if.else 2030; CHECK-NEXT: @ in Loop: Header=BB20_3 Depth=1 2031; CHECK-NEXT: vstr s4, [r12] 2032; CHECK-NEXT: vmov.f32 s6, s5 2033; CHECK-NEXT: .LBB20_2: @ %if.end 2034; CHECK-NEXT: @ in Loop: Header=BB20_3 Depth=1 2035; CHECK-NEXT: vstr s6, [r12, #4] 2036; CHECK-NEXT: adds r6, #20 2037; CHECK-NEXT: subs r0, #1 2038; CHECK-NEXT: add.w r12, r12, #8 2039; CHECK-NEXT: mov r1, r2 2040; CHECK-NEXT: beq .LBB20_8 2041; CHECK-NEXT: .LBB20_3: @ %do.body 2042; CHECK-NEXT: @ =>This Loop Header: Depth=1 2043; CHECK-NEXT: @ Child Loop BB20_5 Depth 2 2044; CHECK-NEXT: vldrw.u32 q3, [r6] 2045; CHECK-NEXT: movs r5, #0 2046; CHECK-NEXT: vmov q4, q3 2047; CHECK-NEXT: vshlc q4, r5, #32 2048; CHECK-NEXT: vldrw.u32 q2, [r6, #8] 2049; CHECK-NEXT: vmov q5, q2 2050; CHECK-NEXT: vshlc q5, r5, #32 2051; CHECK-NEXT: vldrw.u32 q1, [r12] 2052; CHECK-NEXT: vmov.f32 s6, s0 2053; CHECK-NEXT: mov r5, r2 2054; CHECK-NEXT: vmov.f32 s7, s0 2055; CHECK-NEXT: wls lr, r3, .LBB20_6 2056; CHECK-NEXT: @ %bb.4: @ %while.body.preheader 2057; CHECK-NEXT: @ in Loop: Header=BB20_3 Depth=1 2058; CHECK-NEXT: vmov q6, q1 2059; CHECK-NEXT: mov r5, r2 2060; CHECK-NEXT: .LBB20_5: @ %while.body 2061; CHECK-NEXT: @ Parent Loop BB20_3 Depth=1 2062; CHECK-NEXT: @ => This Inner Loop Header: Depth=2 2063; CHECK-NEXT: ldrd r7, r4, [r1], #8 2064; CHECK-NEXT: vfma.f32 q6, q3, r7 2065; CHECK-NEXT: vmov r7, s24 2066; CHECK-NEXT: vmov q1, q6 2067; CHECK-NEXT: vfma.f32 q1, q2, r7 2068; CHECK-NEXT: vstr s24, [r5] 2069; CHECK-NEXT: vmov.f32 s7, s0 2070; CHECK-NEXT: vfma.f32 q1, q4, r4 2071; CHECK-NEXT: vmov r4, s5 2072; CHECK-NEXT: vstr s5, [r5, #4] 2073; CHECK-NEXT: vfma.f32 q1, q5, r4 2074; CHECK-NEXT: adds r5, #8 2075; CHECK-NEXT: vmov.f32 s4, s6 2076; CHECK-NEXT: vmov.f32 s5, s7 2077; CHECK-NEXT: vmov.f32 s6, s0 2078; CHECK-NEXT: vmov q6, q1 2079; CHECK-NEXT: le lr, .LBB20_5 2080; CHECK-NEXT: .LBB20_6: @ %while.end 2081; CHECK-NEXT: @ in Loop: Header=BB20_3 Depth=1 2082; CHECK-NEXT: cmp.w r8, #0 2083; CHECK-NEXT: beq .LBB20_1 2084; CHECK-NEXT: @ %bb.7: @ %if.then 2085; CHECK-NEXT: @ in Loop: Header=BB20_3 Depth=1 2086; CHECK-NEXT: ldr r1, [r1] 2087; CHECK-NEXT: vfma.f32 q1, q3, r1 2088; CHECK-NEXT: vmov r1, s4 2089; CHECK-NEXT: vstr s4, [r5] 2090; CHECK-NEXT: vfma.f32 q1, q2, r1 2091; CHECK-NEXT: vstr s5, [r12] 2092; CHECK-NEXT: b .LBB20_2 2093; CHECK-NEXT: .LBB20_8: @ %do.end 2094; CHECK-NEXT: vpop {d8, d9, d10, d11, d12, d13} 2095; CHECK-NEXT: pop.w {r4, r5, r6, r7, r8, pc} 2096; CHECK-NEXT: .p2align 2 2097; CHECK-NEXT: @ %bb.9: 2098; CHECK-NEXT: .LCPI20_0: 2099; CHECK-NEXT: .long 0x00000000 @ float 0 2100entry: 2101 %pState1 = getelementptr inbounds %struct.arm_biquad_cascade_df2T_instance_f32, %struct.arm_biquad_cascade_df2T_instance_f32* %S, i32 0, i32 1 2102 %0 = load float*, float** %pState1, align 4 2103 %numStages = getelementptr inbounds %struct.arm_biquad_cascade_df2T_instance_f32, %struct.arm_biquad_cascade_df2T_instance_f32* %S, i32 0, i32 0 2104 %1 = load i8, i8* %numStages, align 4 2105 %conv = zext i8 %1 to i32 2106 %pCoeffs = getelementptr inbounds %struct.arm_biquad_cascade_df2T_instance_f32, %struct.arm_biquad_cascade_df2T_instance_f32* %S, i32 0, i32 2 2107 %2 = load float*, float** %pCoeffs, align 4 2108 %div = lshr i32 %blockSize, 1 2109 %cmp.not90 = icmp eq i32 %div, 0 2110 %and = and i32 %blockSize, 1 2111 %tobool.not = icmp eq i32 %and, 0 2112 br label %do.body 2113 2114do.body: ; preds = %if.end, %entry 2115 %stage.0 = phi i32 [ %conv, %entry ], [ %dec23, %if.end ] 2116 %pCurCoeffs.0 = phi float* [ %2, %entry ], [ %add.ptr2, %if.end ] 2117 %pState.0 = phi float* [ %0, %entry ], [ %pState.1, %if.end ] 2118 %pIn.0 = phi float* [ %pSrc, %entry ], [ %pDst, %if.end ] 2119 %3 = bitcast float* %pCurCoeffs.0 to <4 x float>* 2120 %4 = load <4 x float>, <4 x float>* %3, align 4 2121 %add.ptr = getelementptr inbounds float, float* %pCurCoeffs.0, i32 2 2122 %5 = bitcast float* %add.ptr to <4 x float>* 2123 %6 = load <4 x float>, <4 x float>* %5, align 4 2124 %add.ptr2 = getelementptr inbounds float, float* %pCurCoeffs.0, i32 5 2125 %7 = bitcast float* %pState.0 to <4 x float>* 2126 %8 = load <4 x float>, <4 x float>* %7, align 8 2127 %9 = shufflevector <4 x float> %8, <4 x float> <float poison, float poison, float 0.000000e+00, float 0.000000e+00>, <4 x i32> <i32 0, i32 1, i32 6, i32 7> 2128 %10 = bitcast <4 x float> %4 to <4 x i32> 2129 %11 = tail call { i32, <4 x i32> } @llvm.arm.mve.vshlc.v4i32(<4 x i32> %10, i32 0, i32 32) 2130 %12 = extractvalue { i32, <4 x i32> } %11, 0 2131 %13 = extractvalue { i32, <4 x i32> } %11, 1 2132 %14 = bitcast <4 x i32> %13 to <4 x float> 2133 %15 = bitcast <4 x float> %6 to <4 x i32> 2134 %16 = tail call { i32, <4 x i32> } @llvm.arm.mve.vshlc.v4i32(<4 x i32> %15, i32 %12, i32 32) 2135 %17 = extractvalue { i32, <4 x i32> } %16, 1 2136 %18 = bitcast <4 x i32> %17 to <4 x float> 2137 br i1 %cmp.not90, label %while.end, label %while.body 2138 2139while.body: ; preds = %do.body, %while.body 2140 %pIn.194 = phi float* [ %incdec.ptr4, %while.body ], [ %pIn.0, %do.body ] 2141 %state.093 = phi <4 x float> [ %30, %while.body ], [ %9, %do.body ] 2142 %pOut.192 = phi float* [ %incdec.ptr12, %while.body ], [ %pDst, %do.body ] 2143 %sample.091 = phi i32 [ %dec, %while.body ], [ %div, %do.body ] 2144 %incdec.ptr = getelementptr inbounds float, float* %pIn.194, i32 1 2145 %19 = load float, float* %pIn.194, align 4 2146 %incdec.ptr4 = getelementptr inbounds float, float* %pIn.194, i32 2 2147 %20 = load float, float* %incdec.ptr, align 4 2148 %.splatinsert = insertelement <4 x float> poison, float %19, i32 0 2149 %.splat = shufflevector <4 x float> %.splatinsert, <4 x float> poison, <4 x i32> zeroinitializer 2150 %21 = tail call fast <4 x float> @llvm.fma.v4f32(<4 x float> %4, <4 x float> %.splat, <4 x float> %state.093) 2151 %22 = extractelement <4 x float> %21, i32 0 2152 %.splat6 = shufflevector <4 x float> %21, <4 x float> poison, <4 x i32> zeroinitializer 2153 %23 = tail call fast <4 x float> @llvm.fma.v4f32(<4 x float> %6, <4 x float> %.splat6, <4 x float> %21) 2154 %24 = insertelement <4 x float> %23, float 0.000000e+00, i32 3 2155 %.splatinsert7 = insertelement <4 x float> poison, float %20, i32 0 2156 %.splat8 = shufflevector <4 x float> %.splatinsert7, <4 x float> poison, <4 x i32> zeroinitializer 2157 %25 = tail call fast <4 x float> @llvm.fma.v4f32(<4 x float> %14, <4 x float> %.splat8, <4 x float> %24) 2158 %26 = extractelement <4 x float> %25, i32 1 2159 %.splat10 = shufflevector <4 x float> %25, <4 x float> undef, <4 x i32> <i32 1, i32 1, i32 1, i32 1> 2160 %27 = tail call fast <4 x float> @llvm.fma.v4f32(<4 x float> %18, <4 x float> %.splat10, <4 x float> %25) 2161 %28 = shufflevector <4 x float> %27, <4 x float> undef, <4 x i32> <i32 2, i32 undef, i32 undef, i32 3> 2162 %29 = insertelement <4 x float> %28, float 0.000000e+00, i32 2 2163 %30 = shufflevector <4 x float> %29, <4 x float> %27, <4 x i32> <i32 0, i32 7, i32 2, i32 3> 2164 %incdec.ptr11 = getelementptr inbounds float, float* %pOut.192, i32 1 2165 store float %22, float* %pOut.192, align 4 2166 %incdec.ptr12 = getelementptr inbounds float, float* %pOut.192, i32 2 2167 store float %26, float* %incdec.ptr11, align 4 2168 %dec = add nsw i32 %sample.091, -1 2169 %cmp.not = icmp eq i32 %dec, 0 2170 br i1 %cmp.not, label %while.end, label %while.body 2171 2172while.end: ; preds = %while.body, %do.body 2173 %pOut.1.lcssa = phi float* [ %pDst, %do.body ], [ %incdec.ptr12, %while.body ] 2174 %state.0.lcssa = phi <4 x float> [ %9, %do.body ], [ %30, %while.body ] 2175 %pIn.1.lcssa = phi float* [ %pIn.0, %do.body ], [ %incdec.ptr4, %while.body ] 2176 br i1 %tobool.not, label %if.else, label %if.then 2177 2178if.then: ; preds = %while.end 2179 %31 = load float, float* %pIn.1.lcssa, align 4 2180 %.splatinsert14 = insertelement <4 x float> poison, float %31, i32 0 2181 %.splat15 = shufflevector <4 x float> %.splatinsert14, <4 x float> poison, <4 x i32> zeroinitializer 2182 %32 = tail call fast <4 x float> @llvm.fma.v4f32(<4 x float> %4, <4 x float> %.splat15, <4 x float> %state.0.lcssa) 2183 %33 = extractelement <4 x float> %32, i32 0 2184 %.splat17 = shufflevector <4 x float> %32, <4 x float> poison, <4 x i32> zeroinitializer 2185 %34 = tail call fast <4 x float> @llvm.fma.v4f32(<4 x float> %6, <4 x float> %.splat17, <4 x float> %32) 2186 store float %33, float* %pOut.1.lcssa, align 4 2187 %35 = extractelement <4 x float> %34, i32 1 2188 store float %35, float* %pState.0, align 4 2189 %36 = extractelement <4 x float> %34, i32 2 2190 br label %if.end 2191 2192if.else: ; preds = %while.end 2193 %37 = extractelement <4 x float> %state.0.lcssa, i32 0 2194 store float %37, float* %pState.0, align 4 2195 %38 = extractelement <4 x float> %state.0.lcssa, i32 1 2196 br label %if.end 2197 2198if.end: ; preds = %if.else, %if.then 2199 %.sink = phi float [ %38, %if.else ], [ %36, %if.then ] 2200 %39 = getelementptr inbounds float, float* %pState.0, i32 1 2201 store float %.sink, float* %39, align 4 2202 %pState.1 = getelementptr inbounds float, float* %pState.0, i32 2 2203 %dec23 = add i32 %stage.0, -1 2204 %cmp24.not = icmp eq i32 %dec23, 0 2205 br i1 %cmp24.not, label %do.end, label %do.body 2206 2207do.end: ; preds = %if.end 2208 ret void 2209} 2210 2211define arm_aapcs_vfpcc float @vecAddAcrossF32Mve(<4 x float> %in) { 2212; CHECK-LABEL: vecAddAcrossF32Mve: 2213; CHECK: @ %bb.0: @ %entry 2214; CHECK-NEXT: vadd.f32 s4, s0, s1 2215; CHECK-NEXT: vadd.f32 s4, s4, s2 2216; CHECK-NEXT: vadd.f32 s0, s4, s3 2217; CHECK-NEXT: bx lr 2218entry: 2219 %0 = extractelement <4 x float> %in, i32 0 2220 %1 = extractelement <4 x float> %in, i32 1 2221 %add = fadd fast float %0, %1 2222 %2 = extractelement <4 x float> %in, i32 2 2223 %add1 = fadd fast float %add, %2 2224 %3 = extractelement <4 x float> %in, i32 3 2225 %add2 = fadd fast float %add1, %3 2226 ret float %add2 2227} 2228 2229 2230declare { i32, <4 x i32> } @llvm.arm.mve.vshlc.v4i32(<4 x i32>, i32, i32) #1 2231declare void @llvm.lifetime.end.p0i8(i64 immarg, i8* nocapture) 2232declare void @llvm.lifetime.start.p0i8(i64 immarg, i8* nocapture) 2233declare { <4 x i32>, i32 } @llvm.arm.mve.viwdup.v4i32(i32, i32, i32) 2234declare <4 x i32> @llvm.arm.mve.vldr.gather.offset.v4i32.p0i32.v4i32(i32*, <4 x i32>, i32, i32, i32) 2235declare void @llvm.assume(i1) 2236declare <4 x i1> @llvm.arm.mve.vctp32(i32) 2237declare <4 x float> @llvm.fma.v4f32(<4 x float>, <4 x float>, <4 x float>) 2238declare void @llvm.masked.store.v4f32.p0v4f32(<4 x float>, <4 x float>*, i32 immarg, <4 x i1>) 2239