brintos

brintos / llvm-project-archived public Read only

0
0
Text · 17.8 KiB · 6b29c78 Raw
516 lines · plain
1; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py2; RUN: llc -mcpu=pwr9 -O3 -verify-machineinstrs -ppc-vsr-nums-as-vr \3; RUN:     -mtriple=powerpc64le-unknown-linux-gnu \4; RUN:     < %s | FileCheck %s --check-prefixes=P9LE5 6; RUN: llc -mcpu=pwr9 -O3 -verify-machineinstrs -ppc-vsr-nums-as-vr \7; RUN:     -mtriple=powerpc64-unknown-linux-gnu \8; RUN:     < %s | FileCheck %s --check-prefixes=P9BE9 10; RUN: llc -mcpu=pwr9 -O3 -verify-machineinstrs -ppc-vsr-nums-as-vr \11; RUN:     -mtriple=powerpc64-ibm-aix-xcoff -vec-extabi \12; RUN:     < %s | FileCheck %s --check-prefixes=P9BE-AIX13 14; RUN: llc -mcpu=pwr9 -O3 -verify-machineinstrs -ppc-vsr-nums-as-vr \15; RUN:     -mtriple=powerpc-ibm-aix-xcoff -vec-extabi \16; RUN:     < %s | FileCheck %s --check-prefixes=P9BE-AIX3217 18define void @test64(ptr nocapture readonly %pix2, i32 signext %i_pix2) {19; P9LE-LABEL: test64:20; P9LE:       # %bb.0: # %entry21; P9LE-NEXT:    add 5, 3, 422; P9LE-NEXT:    lfdx 0, 3, 423; P9LE-NEXT:    addis 3, 2, .LCPI0_0@toc@ha24; P9LE-NEXT:    xxlxor 2, 2, 225; P9LE-NEXT:    xxspltib 4, 1626; P9LE-NEXT:    lxsd 3, 4(5)27; P9LE-NEXT:    addi 3, 3, .LCPI0_0@toc@l28; P9LE-NEXT:    vextsb2w 4, 429; P9LE-NEXT:    lxv 1, 0(3)30; P9LE-NEXT:    addis 3, 2, .LCPI0_1@toc@ha31; P9LE-NEXT:    addi 3, 3, .LCPI0_1@toc@l32; P9LE-NEXT:    xxperm 2, 0, 133; P9LE-NEXT:    lxv 0, 0(3)34; P9LE-NEXT:    xxperm 3, 3, 035; P9LE-NEXT:    vnegw 3, 336; P9LE-NEXT:    vslw 3, 3, 437; P9LE-NEXT:    vsubuwm 2, 3, 238; P9LE-NEXT:    xxswapd 0, 239; P9LE-NEXT:    stxv 0, 0(3)40; P9LE-NEXT:    blr41;42; P9BE-LABEL: test64:43; P9BE:       # %bb.0: # %entry44; P9BE-NEXT:    add 5, 3, 445; P9BE-NEXT:    lxsdx 2, 3, 446; P9BE-NEXT:    addis 3, 2, .LCPI0_0@toc@ha47; P9BE-NEXT:    xxlxor 1, 1, 148; P9BE-NEXT:    xxspltib 4, 1649; P9BE-NEXT:    lxsd 3, 4(5)50; P9BE-NEXT:    addi 3, 3, .LCPI0_0@toc@l51; P9BE-NEXT:    vextsb2w 4, 452; P9BE-NEXT:    lxv 0, 0(3)53; P9BE-NEXT:    addis 3, 2, .LCPI0_1@toc@ha54; P9BE-NEXT:    addi 3, 3, .LCPI0_1@toc@l55; P9BE-NEXT:    xxperm 2, 1, 056; P9BE-NEXT:    lxv 0, 0(3)57; P9BE-NEXT:    xxperm 3, 3, 058; P9BE-NEXT:    vnegw 3, 359; P9BE-NEXT:    vslw 3, 3, 460; P9BE-NEXT:    vsubuwm 2, 3, 261; P9BE-NEXT:    xxswapd 0, 262; P9BE-NEXT:    stxv 0, 0(3)63; P9BE-NEXT:    blr64;65; P9BE-AIX-LABEL: test64:66; P9BE-AIX:       # %bb.0: # %entry67; P9BE-AIX-NEXT:    add 5, 3, 468; P9BE-AIX-NEXT:    lxsdx 2, 3, 469; P9BE-AIX-NEXT:    ld 3, L..C0(2) # %const.070; P9BE-AIX-NEXT:    xxlxor 1, 1, 171; P9BE-AIX-NEXT:    xxspltib 4, 1672; P9BE-AIX-NEXT:    lxsd 3, 4(5)73; P9BE-AIX-NEXT:    lxv 0, 0(3)74; P9BE-AIX-NEXT:    ld 3, L..C1(2) # %const.175; P9BE-AIX-NEXT:    vextsb2w 4, 476; P9BE-AIX-NEXT:    xxperm 2, 1, 077; P9BE-AIX-NEXT:    lxv 0, 0(3)78; P9BE-AIX-NEXT:    xxperm 3, 3, 079; P9BE-AIX-NEXT:    vnegw 3, 380; P9BE-AIX-NEXT:    vslw 3, 3, 481; P9BE-AIX-NEXT:    vsubuwm 2, 3, 282; P9BE-AIX-NEXT:    xxswapd 0, 283; P9BE-AIX-NEXT:    stxv 0, 0(3)84; P9BE-AIX-NEXT:    blr85;86; P9BE-AIX32-LABEL: test64:87; P9BE-AIX32:       # %bb.0: # %entry88; P9BE-AIX32-NEXT:    add 5, 3, 489; P9BE-AIX32-NEXT:    lxvwsx 0, 3, 490; P9BE-AIX32-NEXT:    li 3, 491; P9BE-AIX32-NEXT:    xxlxor 2, 2, 292; P9BE-AIX32-NEXT:    xxspltib 4, 1693; P9BE-AIX32-NEXT:    lxvwsx 1, 5, 394; P9BE-AIX32-NEXT:    lwz 3, L..C0(2) # %const.095; P9BE-AIX32-NEXT:    vextsb2w 4, 496; P9BE-AIX32-NEXT:    xxmrghw 2, 0, 197; P9BE-AIX32-NEXT:    lxv 0, 0(3)98; P9BE-AIX32-NEXT:    li 3, 899; P9BE-AIX32-NEXT:    xxperm 2, 2, 0100; P9BE-AIX32-NEXT:    lxvwsx 0, 5, 3101; P9BE-AIX32-NEXT:    lwz 3, L..C1(2) # %const.1102; P9BE-AIX32-NEXT:    xxmrghw 3, 1, 0103; P9BE-AIX32-NEXT:    lxv 0, 0(3)104; P9BE-AIX32-NEXT:    xxperm 3, 3, 0105; P9BE-AIX32-NEXT:    vnegw 3, 3106; P9BE-AIX32-NEXT:    vslw 3, 3, 4107; P9BE-AIX32-NEXT:    vsubuwm 2, 3, 2108; P9BE-AIX32-NEXT:    xxswapd 0, 2109; P9BE-AIX32-NEXT:    stxv 0, 0(3)110; P9BE-AIX32-NEXT:    blr111entry:112  %idx.ext63 = sext i32 %i_pix2 to i64113  %add.ptr64 = getelementptr inbounds i8, ptr %pix2, i64 %idx.ext63114  %arrayidx5.1 = getelementptr inbounds i8, ptr %add.ptr64, i64 4115  %0 = load <4 x i16>, ptr %add.ptr64, align 1116  %reorder_shuffle117 = shufflevector <4 x i16> %0, <4 x i16> undef, <4 x i32> <i32 3, i32 2, i32 1, i32 0>117  %1 = zext <4 x i16> %reorder_shuffle117 to <4 x i32>118  %2 = sub nsw <4 x i32> zeroinitializer, %1119  %3 = load <4 x i16>, ptr %arrayidx5.1, align 1120  %reorder_shuffle115 = shufflevector <4 x i16> %3, <4 x i16> undef, <4 x i32> <i32 3, i32 2, i32 1, i32 0>121  %4 = zext <4 x i16> %reorder_shuffle115 to <4 x i32>122  %5 = sub nsw <4 x i32> zeroinitializer, %4123  %6 = shl nsw <4 x i32> %5, <i32 16, i32 16, i32 16, i32 16>124  %7 = add nsw <4 x i32> %6, %2125  %8 = sub nsw <4 x i32> %7, zeroinitializer126  %9 = shufflevector <4 x i32> undef, <4 x i32> %8, <4 x i32> <i32 2, i32 7, i32 0, i32 5>127  %10 = add nsw <4 x i32> zeroinitializer, %9128  %11 = shufflevector <4 x i32> %10, <4 x i32> undef, <4 x i32> <i32 0, i32 1, i32 6, i32 7>129  store <4 x i32> %11, ptr undef, align 16130  ret void131}132 133define void @test32(ptr nocapture readonly %pix2, i32 signext %i_pix2) {134; P9LE-LABEL: test32:135; P9LE:       # %bb.0: # %entry136; P9LE-NEXT:    add 5, 3, 4137; P9LE-NEXT:    lxsiwzx 2, 3, 4138; P9LE-NEXT:    addis 3, 2, .LCPI1_0@toc@ha139; P9LE-NEXT:    xxlxor 0, 0, 0140; P9LE-NEXT:    xxspltib 4, 16141; P9LE-NEXT:    addi 3, 3, .LCPI1_0@toc@l142; P9LE-NEXT:    lxv 1, 0(3)143; P9LE-NEXT:    li 3, 4144; P9LE-NEXT:    vextsb2w 4, 4145; P9LE-NEXT:    lxsiwzx 3, 5, 3146; P9LE-NEXT:    xxperm 2, 0, 1147; P9LE-NEXT:    xxperm 3, 0, 1148; P9LE-NEXT:    vnegw 3, 3149; P9LE-NEXT:    vslw 3, 3, 4150; P9LE-NEXT:    vsubuwm 2, 3, 2151; P9LE-NEXT:    xxswapd 0, 2152; P9LE-NEXT:    stxv 0, 0(3)153; P9LE-NEXT:    blr154;155; P9BE-LABEL: test32:156; P9BE:       # %bb.0: # %entry157; P9BE-NEXT:    add 5, 3, 4158; P9BE-NEXT:    lxsiwzx 2, 3, 4159; P9BE-NEXT:    addis 3, 2, .LCPI1_0@toc@ha160; P9BE-NEXT:    xxlxor 0, 0, 0161; P9BE-NEXT:    xxspltib 4, 16162; P9BE-NEXT:    addi 3, 3, .LCPI1_0@toc@l163; P9BE-NEXT:    lxv 1, 0(3)164; P9BE-NEXT:    li 3, 4165; P9BE-NEXT:    vextsb2w 4, 4166; P9BE-NEXT:    lxsiwzx 3, 5, 3167; P9BE-NEXT:    xxperm 2, 0, 1168; P9BE-NEXT:    xxperm 3, 0, 1169; P9BE-NEXT:    vnegw 3, 3170; P9BE-NEXT:    vslw 3, 3, 4171; P9BE-NEXT:    vsubuwm 2, 3, 2172; P9BE-NEXT:    xxswapd 0, 2173; P9BE-NEXT:    stxv 0, 0(3)174; P9BE-NEXT:    blr175;176; P9BE-AIX-LABEL: test32:177; P9BE-AIX:       # %bb.0: # %entry178; P9BE-AIX-NEXT:    add 5, 3, 4179; P9BE-AIX-NEXT:    lxsiwzx 2, 3, 4180; P9BE-AIX-NEXT:    ld 3, L..C2(2) # %const.0181; P9BE-AIX-NEXT:    xxlxor 0, 0, 0182; P9BE-AIX-NEXT:    xxspltib 4, 16183; P9BE-AIX-NEXT:    lxv 1, 0(3)184; P9BE-AIX-NEXT:    li 3, 4185; P9BE-AIX-NEXT:    vextsb2w 4, 4186; P9BE-AIX-NEXT:    lxsiwzx 3, 5, 3187; P9BE-AIX-NEXT:    xxperm 2, 0, 1188; P9BE-AIX-NEXT:    xxperm 3, 0, 1189; P9BE-AIX-NEXT:    vnegw 3, 3190; P9BE-AIX-NEXT:    vslw 3, 3, 4191; P9BE-AIX-NEXT:    vsubuwm 2, 3, 2192; P9BE-AIX-NEXT:    xxswapd 0, 2193; P9BE-AIX-NEXT:    stxv 0, 0(3)194; P9BE-AIX-NEXT:    blr195;196; P9BE-AIX32-LABEL: test32:197; P9BE-AIX32:       # %bb.0: # %entry198; P9BE-AIX32-NEXT:    add 5, 3, 4199; P9BE-AIX32-NEXT:    lxsiwzx 2, 3, 4200; P9BE-AIX32-NEXT:    lwz 3, L..C2(2) # %const.0201; P9BE-AIX32-NEXT:    xxlxor 0, 0, 0202; P9BE-AIX32-NEXT:    xxspltib 4, 16203; P9BE-AIX32-NEXT:    lxv 1, 0(3)204; P9BE-AIX32-NEXT:    li 3, 4205; P9BE-AIX32-NEXT:    vextsb2w 4, 4206; P9BE-AIX32-NEXT:    lxsiwzx 3, 5, 3207; P9BE-AIX32-NEXT:    xxperm 2, 0, 1208; P9BE-AIX32-NEXT:    xxperm 3, 0, 1209; P9BE-AIX32-NEXT:    vnegw 3, 3210; P9BE-AIX32-NEXT:    vslw 3, 3, 4211; P9BE-AIX32-NEXT:    vsubuwm 2, 3, 2212; P9BE-AIX32-NEXT:    xxswapd 0, 2213; P9BE-AIX32-NEXT:    stxv 0, 0(3)214; P9BE-AIX32-NEXT:    blr215entry:216  %idx.ext63 = sext i32 %i_pix2 to i64217  %add.ptr64 = getelementptr inbounds i8, ptr %pix2, i64 %idx.ext63218  %arrayidx5.1 = getelementptr inbounds i8, ptr %add.ptr64, i64 4219  %0 = load <4 x i8>, ptr %add.ptr64, align 1220  %reorder_shuffle117 = shufflevector <4 x i8> %0, <4 x i8> undef, <4 x i32> <i32 3, i32 2, i32 1, i32 0>221  %1 = zext <4 x i8> %reorder_shuffle117 to <4 x i32>222  %2 = sub nsw <4 x i32> zeroinitializer, %1223  %3 = load <4 x i8>, ptr %arrayidx5.1, align 1224  %reorder_shuffle115 = shufflevector <4 x i8> %3, <4 x i8> undef, <4 x i32> <i32 3, i32 2, i32 1, i32 0>225  %4 = zext <4 x i8> %reorder_shuffle115 to <4 x i32>226  %5 = sub nsw <4 x i32> zeroinitializer, %4227  %6 = shl nsw <4 x i32> %5, <i32 16, i32 16, i32 16, i32 16>228  %7 = add nsw <4 x i32> %6, %2229  %8 = sub nsw <4 x i32> %7, zeroinitializer230  %9 = shufflevector <4 x i32> undef, <4 x i32> %8, <4 x i32> <i32 2, i32 7, i32 0, i32 5>231  %10 = add nsw <4 x i32> zeroinitializer, %9232  %11 = shufflevector <4 x i32> %10, <4 x i32> undef, <4 x i32> <i32 0, i32 1, i32 6, i32 7>233  store <4 x i32> %11, ptr undef, align 16234  ret void235}236 237define void @test16(ptr nocapture readonly %sums, i32 signext %delta, i32 signext %thresh) {238; P9LE-LABEL: test16:239; P9LE:       # %bb.0: # %entry240; P9LE-NEXT:    sldi 4, 4, 1241; P9LE-NEXT:    li 7, 16242; P9LE-NEXT:    add 6, 3, 4243; P9LE-NEXT:    lxsihzx 4, 3, 4244; P9LE-NEXT:    addis 3, 2, .LCPI2_0@toc@ha245; P9LE-NEXT:    lxsihzx 2, 6, 7246; P9LE-NEXT:    li 6, 0247; P9LE-NEXT:    addi 3, 3, .LCPI2_0@toc@l248; P9LE-NEXT:    mtvsrd 3, 6249; P9LE-NEXT:    lxv 0, 0(3)250; P9LE-NEXT:    li 3, 0251; P9LE-NEXT:    vmrghh 4, 3, 4252; P9LE-NEXT:    vmrghh 2, 3, 2253; P9LE-NEXT:    vsplth 3, 3, 3254; P9LE-NEXT:    xxmrglw 3, 4, 3255; P9LE-NEXT:    xxperm 3, 2, 0256; P9LE-NEXT:    xxspltw 2, 3, 2257; P9LE-NEXT:    vadduwm 2, 3, 2258; P9LE-NEXT:    vextuwrx 3, 3, 2259; P9LE-NEXT:    cmpw 3, 5260; P9LE-NEXT:    bgelr+ 0261; P9LE-NEXT:  # %bb.1: # %if.then262;263; P9BE-LABEL: test16:264; P9BE:       # %bb.0: # %entry265; P9BE-NEXT:    sldi 4, 4, 1266; P9BE-NEXT:    li 7, 16267; P9BE-NEXT:    add 6, 3, 4268; P9BE-NEXT:    lxsihzx 1, 3, 4269; P9BE-NEXT:    addis 3, 2, .LCPI2_1@toc@ha270; P9BE-NEXT:    lxsihzx 2, 6, 7271; P9BE-NEXT:    addis 6, 2, .LCPI2_0@toc@ha272; P9BE-NEXT:    addi 3, 3, .LCPI2_1@toc@l273; P9BE-NEXT:    addi 6, 6, .LCPI2_0@toc@l274; P9BE-NEXT:    lxv 0, 0(6)275; P9BE-NEXT:    li 6, 0276; P9BE-NEXT:    mtvsrwz 3, 6277; P9BE-NEXT:    xxperm 2, 3, 0278; P9BE-NEXT:    xxperm 1, 3, 0279; P9BE-NEXT:    vsplth 3, 3, 3280; P9BE-NEXT:    lxv 0, 0(3)281; P9BE-NEXT:    li 3, 0282; P9BE-NEXT:    xxmrghw 3, 3, 1283; P9BE-NEXT:    xxperm 2, 3, 0284; P9BE-NEXT:    xxspltw 3, 2, 1285; P9BE-NEXT:    vadduwm 2, 2, 3286; P9BE-NEXT:    vextuwlx 3, 3, 2287; P9BE-NEXT:    cmpw 3, 5288; P9BE-NEXT:    bgelr+ 0289; P9BE-NEXT:  # %bb.1: # %if.then290;291; P9BE-AIX-LABEL: test16:292; P9BE-AIX:       # %bb.0: # %entry293; P9BE-AIX-NEXT:    sldi 4, 4, 1294; P9BE-AIX-NEXT:    li 7, 16295; P9BE-AIX-NEXT:    add 6, 3, 4296; P9BE-AIX-NEXT:    lxsihzx 1, 3, 4297; P9BE-AIX-NEXT:    ld 3, L..C3(2) # %const.1298; P9BE-AIX-NEXT:    lxsihzx 2, 6, 7299; P9BE-AIX-NEXT:    ld 6, L..C4(2) # %const.0300; P9BE-AIX-NEXT:    lxv 0, 0(6)301; P9BE-AIX-NEXT:    li 6, 0302; P9BE-AIX-NEXT:    mtvsrwz 3, 6303; P9BE-AIX-NEXT:    xxperm 2, 3, 0304; P9BE-AIX-NEXT:    xxperm 1, 3, 0305; P9BE-AIX-NEXT:    vsplth 3, 3, 3306; P9BE-AIX-NEXT:    lxv 0, 0(3)307; P9BE-AIX-NEXT:    li 3, 0308; P9BE-AIX-NEXT:    xxmrghw 3, 3, 1309; P9BE-AIX-NEXT:    xxperm 2, 3, 0310; P9BE-AIX-NEXT:    xxspltw 3, 2, 1311; P9BE-AIX-NEXT:    vadduwm 2, 2, 3312; P9BE-AIX-NEXT:    vextuwlx 3, 3, 2313; P9BE-AIX-NEXT:    cmpw 3, 5314; P9BE-AIX-NEXT:    bgelr+ 0315; P9BE-AIX-NEXT:  # %bb.1: # %if.then316;317; P9BE-AIX32-LABEL: test16:318; P9BE-AIX32:       # %bb.0: # %entry319; P9BE-AIX32-NEXT:    slwi 4, 4, 1320; P9BE-AIX32-NEXT:    li 6, 0321; P9BE-AIX32-NEXT:    lhzux 4, 3, 4322; P9BE-AIX32-NEXT:    lhz 3, 16(3)323; P9BE-AIX32-NEXT:    sth 6, -64(1)324; P9BE-AIX32-NEXT:    lxv 2, -64(1)325; P9BE-AIX32-NEXT:    sth 4, -48(1)326; P9BE-AIX32-NEXT:    lxv 4, -48(1)327; P9BE-AIX32-NEXT:    sth 3, -32(1)328; P9BE-AIX32-NEXT:    lwz 3, L..C3(2) # %const.0329; P9BE-AIX32-NEXT:    lxv 3, -32(1)330; P9BE-AIX32-NEXT:    vmrghh 4, 2, 4331; P9BE-AIX32-NEXT:    lxv 0, 0(3)332; P9BE-AIX32-NEXT:    vmrghh 3, 2, 3333; P9BE-AIX32-NEXT:    vsplth 2, 2, 0334; P9BE-AIX32-NEXT:    xxmrghw 2, 2, 4335; P9BE-AIX32-NEXT:    xxperm 3, 2, 0336; P9BE-AIX32-NEXT:    xxspltw 2, 3, 1337; P9BE-AIX32-NEXT:    vadduwm 2, 3, 2338; P9BE-AIX32-NEXT:    stxv 2, -16(1)339; P9BE-AIX32-NEXT:    lwz 3, -16(1)340; P9BE-AIX32-NEXT:    cmpw 3, 5341; P9BE-AIX32-NEXT:    bgelr+ 0342; P9BE-AIX32-NEXT:  # %bb.1: # %if.then343entry:344  %idxprom = sext i32 %delta to i64345  %add14 = add nsw i32 %delta, 8346  %idxprom15 = sext i32 %add14 to i64347  br label %for.body348 349for.body:                                         ; preds = %entry350  %arrayidx8 = getelementptr inbounds i16, ptr %sums, i64 %idxprom351  %0 = load i16, ptr %arrayidx8, align 2352  %arrayidx16 = getelementptr inbounds i16, ptr %sums, i64 %idxprom15353  %1 = load i16, ptr %arrayidx16, align 2354  %2 = insertelement <4 x i16> undef, i16 %0, i32 2355  %3 = insertelement <4 x i16> %2, i16 %1, i32 3356  %4 = zext <4 x i16> %3 to <4 x i32>357  %5 = sub nsw <4 x i32> zeroinitializer, %4358  %6 = sub nsw <4 x i32> zeroinitializer, %5359  %7 = select <4 x i1> undef, <4 x i32> %6, <4 x i32> %5360  %bin.rdx = add <4 x i32> %7, zeroinitializer361  %rdx.shuf54 = shufflevector <4 x i32> %bin.rdx, <4 x i32> undef, <4 x i32> <i32 1, i32 undef, i32 undef, i32 undef>362  %bin.rdx55 = add <4 x i32> %bin.rdx, %rdx.shuf54363  %8 = extractelement <4 x i32> %bin.rdx55, i32 0364  %op.extra = add nuw i32 %8, 0365  %cmp25 = icmp slt i32 %op.extra, %thresh366  br i1 %cmp25, label %if.then, label %if.end367 368if.then:                                          ; preds = %for.body369  unreachable370 371if.end:                                           ; preds = %for.body372  ret void373}374 375define void @test8(ptr nocapture readonly %sums, i32 signext %delta, i32 signext %thresh) {376; P9LE-LABEL: test8:377; P9LE:       # %bb.0: # %entry378; P9LE-NEXT:    add 6, 3, 4379; P9LE-NEXT:    lxsibzx 2, 3, 4380; P9LE-NEXT:    li 3, 0381; P9LE-NEXT:    mtvsrd 3, 3382; P9LE-NEXT:    li 3, 8383; P9LE-NEXT:    lxsibzx 5, 6, 3384; P9LE-NEXT:    vspltb 4, 3, 7385; P9LE-NEXT:    addis 3, 2, .LCPI3_0@toc@ha386; P9LE-NEXT:    vmrghb 2, 3, 2387; P9LE-NEXT:    addi 3, 3, .LCPI3_0@toc@l388; P9LE-NEXT:    vmrglh 2, 2, 4389; P9LE-NEXT:    lxv 0, 0(3)390; P9LE-NEXT:    li 3, 0391; P9LE-NEXT:    vmrghb 3, 3, 5392; P9LE-NEXT:    xxmrglw 2, 2, 4393; P9LE-NEXT:    vmrglh 3, 3, 4394; P9LE-NEXT:    xxmrglw 3, 4, 3395; P9LE-NEXT:    xxperm 2, 3, 0396; P9LE-NEXT:    xxspltw 3, 2, 2397; P9LE-NEXT:    vadduwm 2, 2, 3398; P9LE-NEXT:    vextuwrx 3, 3, 2399; P9LE-NEXT:    cmpw 3, 5400; P9LE-NEXT:    bgelr+ 0401; P9LE-NEXT:  # %bb.1: # %if.then402;403; P9BE-LABEL: test8:404; P9BE:       # %bb.0: # %entry405; P9BE-NEXT:    add 6, 3, 4406; P9BE-NEXT:    li 7, 8407; P9BE-NEXT:    lxsibzx 3, 3, 4408; P9BE-NEXT:    addis 3, 2, .LCPI3_1@toc@ha409; P9BE-NEXT:    lxsibzx 0, 6, 7410; P9BE-NEXT:    addis 6, 2, .LCPI3_0@toc@ha411; P9BE-NEXT:    addi 3, 3, .LCPI3_1@toc@l412; P9BE-NEXT:    addi 6, 6, .LCPI3_0@toc@l413; P9BE-NEXT:    lxv 1, 0(6)414; P9BE-NEXT:    li 6, 0415; P9BE-NEXT:    mtvsrwz 2, 6416; P9BE-NEXT:    xxperm 0, 2, 1417; P9BE-NEXT:    xxperm 3, 2, 1418; P9BE-NEXT:    vspltb 2, 2, 7419; P9BE-NEXT:    vmrghh 3, 3, 2420; P9BE-NEXT:    xxspltw 1, 2, 0421; P9BE-NEXT:    xxmrghw 3, 3, 0422; P9BE-NEXT:    lxv 0, 0(3)423; P9BE-NEXT:    li 3, 0424; P9BE-NEXT:    xxperm 3, 1, 0425; P9BE-NEXT:    xxspltw 2, 3, 1426; P9BE-NEXT:    vadduwm 2, 3, 2427; P9BE-NEXT:    vextuwlx 3, 3, 2428; P9BE-NEXT:    cmpw 3, 5429; P9BE-NEXT:    bgelr+ 0430; P9BE-NEXT:  # %bb.1: # %if.then431;432; P9BE-AIX-LABEL: test8:433; P9BE-AIX:       # %bb.0: # %entry434; P9BE-AIX-NEXT:    add 6, 3, 4435; P9BE-AIX-NEXT:    li 7, 8436; P9BE-AIX-NEXT:    lxsibzx 3, 3, 4437; P9BE-AIX-NEXT:    ld 3, L..C5(2) # %const.1438; P9BE-AIX-NEXT:    lxsibzx 0, 6, 7439; P9BE-AIX-NEXT:    ld 6, L..C6(2) # %const.0440; P9BE-AIX-NEXT:    lxv 1, 0(6)441; P9BE-AIX-NEXT:    li 6, 0442; P9BE-AIX-NEXT:    mtvsrwz 2, 6443; P9BE-AIX-NEXT:    xxperm 0, 2, 1444; P9BE-AIX-NEXT:    xxperm 3, 2, 1445; P9BE-AIX-NEXT:    vspltb 2, 2, 7446; P9BE-AIX-NEXT:    vmrghh 3, 3, 2447; P9BE-AIX-NEXT:    xxspltw 1, 2, 0448; P9BE-AIX-NEXT:    xxmrghw 3, 3, 0449; P9BE-AIX-NEXT:    lxv 0, 0(3)450; P9BE-AIX-NEXT:    li 3, 0451; P9BE-AIX-NEXT:    xxperm 3, 1, 0452; P9BE-AIX-NEXT:    xxspltw 2, 3, 1453; P9BE-AIX-NEXT:    vadduwm 2, 3, 2454; P9BE-AIX-NEXT:    vextuwlx 3, 3, 2455; P9BE-AIX-NEXT:    cmpw 3, 5456; P9BE-AIX-NEXT:    bgelr+ 0457; P9BE-AIX-NEXT:  # %bb.1: # %if.then458;459; P9BE-AIX32-LABEL: test8:460; P9BE-AIX32:       # %bb.0: # %entry461; P9BE-AIX32-NEXT:    add 6, 3, 4462; P9BE-AIX32-NEXT:    li 7, 8463; P9BE-AIX32-NEXT:    lxsibzx 3, 3, 4464; P9BE-AIX32-NEXT:    lwz 3, L..C4(2) # %const.1465; P9BE-AIX32-NEXT:    lxsibzx 0, 6, 7466; P9BE-AIX32-NEXT:    lwz 6, L..C5(2) # %const.0467; P9BE-AIX32-NEXT:    lxv 1, 0(6)468; P9BE-AIX32-NEXT:    li 6, 0469; P9BE-AIX32-NEXT:    mtvsrwz 2, 6470; P9BE-AIX32-NEXT:    xxperm 0, 2, 1471; P9BE-AIX32-NEXT:    xxperm 3, 2, 1472; P9BE-AIX32-NEXT:    vspltb 2, 2, 7473; P9BE-AIX32-NEXT:    vmrghh 3, 3, 2474; P9BE-AIX32-NEXT:    xxspltw 1, 2, 0475; P9BE-AIX32-NEXT:    xxmrghw 3, 3, 0476; P9BE-AIX32-NEXT:    lxv 0, 0(3)477; P9BE-AIX32-NEXT:    xxperm 3, 1, 0478; P9BE-AIX32-NEXT:    xxspltw 2, 3, 1479; P9BE-AIX32-NEXT:    vadduwm 2, 3, 2480; P9BE-AIX32-NEXT:    stxv 2, -16(1)481; P9BE-AIX32-NEXT:    lwz 3, -16(1)482; P9BE-AIX32-NEXT:    cmpw 3, 5483; P9BE-AIX32-NEXT:    bgelr+ 0484; P9BE-AIX32-NEXT:  # %bb.1: # %if.then485entry:486  %idxprom = sext i32 %delta to i64487  %add14 = add nsw i32 %delta, 8488  %idxprom15 = sext i32 %add14 to i64489  br label %for.body490 491for.body:                                         ; preds = %entry492  %arrayidx8 = getelementptr inbounds i8, ptr %sums, i64 %idxprom493  %0 = load i8, ptr %arrayidx8, align 2494  %arrayidx16 = getelementptr inbounds i8, ptr %sums, i64 %idxprom15495  %1 = load i8, ptr %arrayidx16, align 2496  %2 = insertelement <4 x i8> undef, i8 %0, i32 2497  %3 = insertelement <4 x i8> %2, i8 %1, i32 3498  %4 = zext <4 x i8> %3 to <4 x i32>499  %5 = sub nsw <4 x i32> zeroinitializer, %4500  %6 = sub nsw <4 x i32> zeroinitializer, %5501  %7 = select <4 x i1> undef, <4 x i32> %6, <4 x i32> %5502  %bin.rdx = add <4 x i32> %7, zeroinitializer503  %rdx.shuf54 = shufflevector <4 x i32> %bin.rdx, <4 x i32> undef, <4 x i32> <i32 1, i32 undef, i32 undef, i32 undef>504  %bin.rdx55 = add <4 x i32> %bin.rdx, %rdx.shuf54505  %8 = extractelement <4 x i32> %bin.rdx55, i32 0506  %op.extra = add nuw i32 %8, 0507  %cmp25 = icmp slt i32 %op.extra, %thresh508  br i1 %cmp25, label %if.then, label %if.end509 510if.then:                                          ; preds = %for.body511  unreachable512 513if.end:                                           ; preds = %for.body514  ret void515}516