brintos

brintos / llvm-project-archived public Read only

0
0
Text · 127.4 KiB · a7b6ed4 Raw
3889 lines · plain
1; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py UTC_ARGS: --version 42; RUN: llc < %s -mtriple=i686-- -mattr=+mmx,+ssse3,-avx | FileCheck %s --check-prefixes=ALL,X863; RUN: llc < %s -mtriple=i686-- -mattr=+mmx,+avx | FileCheck %s --check-prefixes=ALL,X864; RUN: llc < %s -mtriple=x86_64-- -mattr=+mmx,+ssse3,-avx | FileCheck %s --check-prefixes=ALL,X645; RUN: llc < %s -mtriple=x86_64-- -mattr=+mmx,+avx | FileCheck %s --check-prefixes=ALL,X646 7declare <1 x i64> @llvm.x86.ssse3.phadd.w(<1 x i64>, <1 x i64>) nounwind readnone8 9define i64 @test1(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {10; X86-LABEL: test1:11; X86:       # %bb.0: # %entry12; X86-NEXT:    pushl %ebp13; X86-NEXT:    movl %esp, %ebp14; X86-NEXT:    andl $-8, %esp15; X86-NEXT:    subl $24, %esp16; X86-NEXT:    movl 8(%ebp), %eax17; X86-NEXT:    movl 12(%ebp), %ecx18; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)19; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)20; X86-NEXT:    movl 16(%ebp), %eax21; X86-NEXT:    movl 20(%ebp), %ecx22; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)23; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)24; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm025; X86-NEXT:    phaddw {{[0-9]+}}(%esp), %mm026; X86-NEXT:    movq %mm0, (%esp)27; X86-NEXT:    movl (%esp), %eax28; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx29; X86-NEXT:    movl %ebp, %esp30; X86-NEXT:    popl %ebp31; X86-NEXT:    retl32;33; X64-LABEL: test1:34; X64:       # %bb.0: # %entry35; X64-NEXT:    movq %rsi, %mm036; X64-NEXT:    movq %rdi, %mm137; X64-NEXT:    phaddw %mm0, %mm138; X64-NEXT:    movq %mm1, %rax39; X64-NEXT:    retq40entry:41  %0 = bitcast <1 x i64> %b to <4 x i16>42  %1 = bitcast <1 x i64> %a to <4 x i16>43  %2 = bitcast <4 x i16> %1 to <1 x i64>44  %3 = bitcast <4 x i16> %0 to <1 x i64>45  %4 = tail call <1 x i64> @llvm.x86.ssse3.phadd.w(<1 x i64> %2, <1 x i64> %3) nounwind readnone46  %5 = bitcast <1 x i64> %4 to <4 x i16>47  %6 = bitcast <4 x i16> %5 to <1 x i64>48  %7 = extractelement <1 x i64> %6, i32 049  ret i64 %750}51 52declare <1 x i64> @llvm.x86.mmx.pcmpgt.d(<1 x i64>, <1 x i64>) nounwind readnone53 54define i64 @test88(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {55; X86-LABEL: test88:56; X86:       # %bb.0: # %entry57; X86-NEXT:    pushl %ebp58; X86-NEXT:    movl %esp, %ebp59; X86-NEXT:    andl $-8, %esp60; X86-NEXT:    subl $24, %esp61; X86-NEXT:    movl 8(%ebp), %eax62; X86-NEXT:    movl 12(%ebp), %ecx63; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)64; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)65; X86-NEXT:    movl 16(%ebp), %eax66; X86-NEXT:    movl 20(%ebp), %ecx67; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)68; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)69; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm070; X86-NEXT:    pcmpgtd {{[0-9]+}}(%esp), %mm071; X86-NEXT:    movq %mm0, (%esp)72; X86-NEXT:    movl (%esp), %eax73; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx74; X86-NEXT:    movl %ebp, %esp75; X86-NEXT:    popl %ebp76; X86-NEXT:    retl77;78; X64-LABEL: test88:79; X64:       # %bb.0: # %entry80; X64-NEXT:    movq %rsi, %mm081; X64-NEXT:    movq %rdi, %mm182; X64-NEXT:    pcmpgtd %mm0, %mm183; X64-NEXT:    movq %mm1, %rax84; X64-NEXT:    retq85entry:86  %0 = bitcast <1 x i64> %b to <2 x i32>87  %1 = bitcast <1 x i64> %a to <2 x i32>88  %mmx_var.i = bitcast <2 x i32> %1 to <1 x i64>89  %mmx_var1.i = bitcast <2 x i32> %0 to <1 x i64>90  %2 = tail call <1 x i64> @llvm.x86.mmx.pcmpgt.d(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind91  %3 = bitcast <1 x i64> %2 to <2 x i32>92  %4 = bitcast <2 x i32> %3 to <1 x i64>93  %5 = extractelement <1 x i64> %4, i32 094  ret i64 %595}96 97declare <1 x i64> @llvm.x86.mmx.pcmpgt.w(<1 x i64>, <1 x i64>) nounwind readnone98 99define i64 @test87(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {100; X86-LABEL: test87:101; X86:       # %bb.0: # %entry102; X86-NEXT:    pushl %ebp103; X86-NEXT:    movl %esp, %ebp104; X86-NEXT:    andl $-8, %esp105; X86-NEXT:    subl $24, %esp106; X86-NEXT:    movl 8(%ebp), %eax107; X86-NEXT:    movl 12(%ebp), %ecx108; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)109; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)110; X86-NEXT:    movl 16(%ebp), %eax111; X86-NEXT:    movl 20(%ebp), %ecx112; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)113; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)114; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm0115; X86-NEXT:    pcmpgtw {{[0-9]+}}(%esp), %mm0116; X86-NEXT:    movq %mm0, (%esp)117; X86-NEXT:    movl (%esp), %eax118; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx119; X86-NEXT:    movl %ebp, %esp120; X86-NEXT:    popl %ebp121; X86-NEXT:    retl122;123; X64-LABEL: test87:124; X64:       # %bb.0: # %entry125; X64-NEXT:    movq %rsi, %mm0126; X64-NEXT:    movq %rdi, %mm1127; X64-NEXT:    pcmpgtw %mm0, %mm1128; X64-NEXT:    movq %mm1, %rax129; X64-NEXT:    retq130entry:131  %0 = bitcast <1 x i64> %b to <4 x i16>132  %1 = bitcast <1 x i64> %a to <4 x i16>133  %mmx_var.i = bitcast <4 x i16> %1 to <1 x i64>134  %mmx_var1.i = bitcast <4 x i16> %0 to <1 x i64>135  %2 = tail call <1 x i64> @llvm.x86.mmx.pcmpgt.w(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind136  %3 = bitcast <1 x i64> %2 to <4 x i16>137  %4 = bitcast <4 x i16> %3 to <1 x i64>138  %5 = extractelement <1 x i64> %4, i32 0139  ret i64 %5140}141 142declare <1 x i64> @llvm.x86.mmx.pcmpgt.b(<1 x i64>, <1 x i64>) nounwind readnone143 144define i64 @test86(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {145; X86-LABEL: test86:146; X86:       # %bb.0: # %entry147; X86-NEXT:    pushl %ebp148; X86-NEXT:    movl %esp, %ebp149; X86-NEXT:    andl $-8, %esp150; X86-NEXT:    subl $24, %esp151; X86-NEXT:    movl 8(%ebp), %eax152; X86-NEXT:    movl 12(%ebp), %ecx153; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)154; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)155; X86-NEXT:    movl 16(%ebp), %eax156; X86-NEXT:    movl 20(%ebp), %ecx157; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)158; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)159; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm0160; X86-NEXT:    pcmpgtb {{[0-9]+}}(%esp), %mm0161; X86-NEXT:    movq %mm0, (%esp)162; X86-NEXT:    movl (%esp), %eax163; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx164; X86-NEXT:    movl %ebp, %esp165; X86-NEXT:    popl %ebp166; X86-NEXT:    retl167;168; X64-LABEL: test86:169; X64:       # %bb.0: # %entry170; X64-NEXT:    movq %rsi, %mm0171; X64-NEXT:    movq %rdi, %mm1172; X64-NEXT:    pcmpgtb %mm0, %mm1173; X64-NEXT:    movq %mm1, %rax174; X64-NEXT:    retq175entry:176  %0 = bitcast <1 x i64> %b to <8 x i8>177  %1 = bitcast <1 x i64> %a to <8 x i8>178  %mmx_var.i = bitcast <8 x i8> %1 to <1 x i64>179  %mmx_var1.i = bitcast <8 x i8> %0 to <1 x i64>180  %2 = tail call <1 x i64> @llvm.x86.mmx.pcmpgt.b(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind181  %3 = bitcast <1 x i64> %2 to <8 x i8>182  %4 = bitcast <8 x i8> %3 to <1 x i64>183  %5 = extractelement <1 x i64> %4, i32 0184  ret i64 %5185}186 187declare <1 x i64> @llvm.x86.mmx.pcmpeq.d(<1 x i64>, <1 x i64>) nounwind readnone188 189define i64 @test85(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {190; X86-LABEL: test85:191; X86:       # %bb.0: # %entry192; X86-NEXT:    pushl %ebp193; X86-NEXT:    movl %esp, %ebp194; X86-NEXT:    andl $-8, %esp195; X86-NEXT:    subl $24, %esp196; X86-NEXT:    movl 8(%ebp), %eax197; X86-NEXT:    movl 12(%ebp), %ecx198; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)199; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)200; X86-NEXT:    movl 16(%ebp), %eax201; X86-NEXT:    movl 20(%ebp), %ecx202; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)203; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)204; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm0205; X86-NEXT:    pcmpeqd {{[0-9]+}}(%esp), %mm0206; X86-NEXT:    movq %mm0, (%esp)207; X86-NEXT:    movl (%esp), %eax208; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx209; X86-NEXT:    movl %ebp, %esp210; X86-NEXT:    popl %ebp211; X86-NEXT:    retl212;213; X64-LABEL: test85:214; X64:       # %bb.0: # %entry215; X64-NEXT:    movq %rsi, %mm0216; X64-NEXT:    movq %rdi, %mm1217; X64-NEXT:    pcmpeqd %mm0, %mm1218; X64-NEXT:    movq %mm1, %rax219; X64-NEXT:    retq220entry:221  %0 = bitcast <1 x i64> %b to <2 x i32>222  %1 = bitcast <1 x i64> %a to <2 x i32>223  %mmx_var.i = bitcast <2 x i32> %1 to <1 x i64>224  %mmx_var1.i = bitcast <2 x i32> %0 to <1 x i64>225  %2 = tail call <1 x i64> @llvm.x86.mmx.pcmpeq.d(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind226  %3 = bitcast <1 x i64> %2 to <2 x i32>227  %4 = bitcast <2 x i32> %3 to <1 x i64>228  %5 = extractelement <1 x i64> %4, i32 0229  ret i64 %5230}231 232declare <1 x i64> @llvm.x86.mmx.pcmpeq.w(<1 x i64>, <1 x i64>) nounwind readnone233 234define i64 @test84(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {235; X86-LABEL: test84:236; X86:       # %bb.0: # %entry237; X86-NEXT:    pushl %ebp238; X86-NEXT:    movl %esp, %ebp239; X86-NEXT:    andl $-8, %esp240; X86-NEXT:    subl $24, %esp241; X86-NEXT:    movl 8(%ebp), %eax242; X86-NEXT:    movl 12(%ebp), %ecx243; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)244; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)245; X86-NEXT:    movl 16(%ebp), %eax246; X86-NEXT:    movl 20(%ebp), %ecx247; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)248; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)249; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm0250; X86-NEXT:    pcmpeqw {{[0-9]+}}(%esp), %mm0251; X86-NEXT:    movq %mm0, (%esp)252; X86-NEXT:    movl (%esp), %eax253; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx254; X86-NEXT:    movl %ebp, %esp255; X86-NEXT:    popl %ebp256; X86-NEXT:    retl257;258; X64-LABEL: test84:259; X64:       # %bb.0: # %entry260; X64-NEXT:    movq %rsi, %mm0261; X64-NEXT:    movq %rdi, %mm1262; X64-NEXT:    pcmpeqw %mm0, %mm1263; X64-NEXT:    movq %mm1, %rax264; X64-NEXT:    retq265entry:266  %0 = bitcast <1 x i64> %b to <4 x i16>267  %1 = bitcast <1 x i64> %a to <4 x i16>268  %mmx_var.i = bitcast <4 x i16> %1 to <1 x i64>269  %mmx_var1.i = bitcast <4 x i16> %0 to <1 x i64>270  %2 = tail call <1 x i64> @llvm.x86.mmx.pcmpeq.w(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind271  %3 = bitcast <1 x i64> %2 to <4 x i16>272  %4 = bitcast <4 x i16> %3 to <1 x i64>273  %5 = extractelement <1 x i64> %4, i32 0274  ret i64 %5275}276 277declare <1 x i64> @llvm.x86.mmx.pcmpeq.b(<1 x i64>, <1 x i64>) nounwind readnone278 279define i64 @test83(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {280; X86-LABEL: test83:281; X86:       # %bb.0: # %entry282; X86-NEXT:    pushl %ebp283; X86-NEXT:    movl %esp, %ebp284; X86-NEXT:    andl $-8, %esp285; X86-NEXT:    subl $24, %esp286; X86-NEXT:    movl 8(%ebp), %eax287; X86-NEXT:    movl 12(%ebp), %ecx288; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)289; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)290; X86-NEXT:    movl 16(%ebp), %eax291; X86-NEXT:    movl 20(%ebp), %ecx292; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)293; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)294; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm0295; X86-NEXT:    pcmpeqb {{[0-9]+}}(%esp), %mm0296; X86-NEXT:    movq %mm0, (%esp)297; X86-NEXT:    movl (%esp), %eax298; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx299; X86-NEXT:    movl %ebp, %esp300; X86-NEXT:    popl %ebp301; X86-NEXT:    retl302;303; X64-LABEL: test83:304; X64:       # %bb.0: # %entry305; X64-NEXT:    movq %rsi, %mm0306; X64-NEXT:    movq %rdi, %mm1307; X64-NEXT:    pcmpeqb %mm0, %mm1308; X64-NEXT:    movq %mm1, %rax309; X64-NEXT:    retq310entry:311  %0 = bitcast <1 x i64> %b to <8 x i8>312  %1 = bitcast <1 x i64> %a to <8 x i8>313  %mmx_var.i = bitcast <8 x i8> %1 to <1 x i64>314  %mmx_var1.i = bitcast <8 x i8> %0 to <1 x i64>315  %2 = tail call <1 x i64> @llvm.x86.mmx.pcmpeq.b(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind316  %3 = bitcast <1 x i64> %2 to <8 x i8>317  %4 = bitcast <8 x i8> %3 to <1 x i64>318  %5 = extractelement <1 x i64> %4, i32 0319  ret i64 %5320}321 322declare <1 x i64> @llvm.x86.mmx.punpckldq(<1 x i64>, <1 x i64>) nounwind readnone323 324define i64 @test82(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {325; X86-LABEL: test82:326; X86:       # %bb.0: # %entry327; X86-NEXT:    pushl %ebp328; X86-NEXT:    movl %esp, %ebp329; X86-NEXT:    andl $-8, %esp330; X86-NEXT:    subl $24, %esp331; X86-NEXT:    movl 8(%ebp), %eax332; X86-NEXT:    movl 12(%ebp), %ecx333; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)334; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)335; X86-NEXT:    movl 16(%ebp), %eax336; X86-NEXT:    movl 20(%ebp), %ecx337; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)338; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)339; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm0340; X86-NEXT:    punpckldq {{[0-9]+}}(%esp), %mm0 # mm0 = mm0[0],mem[0]341; X86-NEXT:    movq %mm0, (%esp)342; X86-NEXT:    movl (%esp), %eax343; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx344; X86-NEXT:    movl %ebp, %esp345; X86-NEXT:    popl %ebp346; X86-NEXT:    retl347;348; X64-LABEL: test82:349; X64:       # %bb.0: # %entry350; X64-NEXT:    movq %rsi, %mm0351; X64-NEXT:    movq %rdi, %mm1352; X64-NEXT:    punpckldq %mm0, %mm1 # mm1 = mm1[0],mm0[0]353; X64-NEXT:    movq %mm1, %rax354; X64-NEXT:    retq355entry:356  %0 = bitcast <1 x i64> %b to <2 x i32>357  %1 = bitcast <1 x i64> %a to <2 x i32>358  %mmx_var.i = bitcast <2 x i32> %1 to <1 x i64>359  %mmx_var1.i = bitcast <2 x i32> %0 to <1 x i64>360  %2 = tail call <1 x i64> @llvm.x86.mmx.punpckldq(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind361  %3 = bitcast <1 x i64> %2 to <2 x i32>362  %4 = bitcast <2 x i32> %3 to <1 x i64>363  %5 = extractelement <1 x i64> %4, i32 0364  ret i64 %5365}366 367declare <1 x i64> @llvm.x86.mmx.punpcklwd(<1 x i64>, <1 x i64>) nounwind readnone368 369define i64 @test81(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {370; X86-LABEL: test81:371; X86:       # %bb.0: # %entry372; X86-NEXT:    pushl %ebp373; X86-NEXT:    movl %esp, %ebp374; X86-NEXT:    andl $-8, %esp375; X86-NEXT:    subl $24, %esp376; X86-NEXT:    movl 8(%ebp), %eax377; X86-NEXT:    movl 12(%ebp), %ecx378; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)379; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)380; X86-NEXT:    movl 16(%ebp), %eax381; X86-NEXT:    movl 20(%ebp), %ecx382; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)383; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)384; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm0385; X86-NEXT:    punpcklwd {{[0-9]+}}(%esp), %mm0 # mm0 = mm0[0],mem[0],mm0[1],mem[1]386; X86-NEXT:    movq %mm0, (%esp)387; X86-NEXT:    movl (%esp), %eax388; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx389; X86-NEXT:    movl %ebp, %esp390; X86-NEXT:    popl %ebp391; X86-NEXT:    retl392;393; X64-LABEL: test81:394; X64:       # %bb.0: # %entry395; X64-NEXT:    movq %rsi, %mm0396; X64-NEXT:    movq %rdi, %mm1397; X64-NEXT:    punpcklwd %mm0, %mm1 # mm1 = mm1[0],mm0[0],mm1[1],mm0[1]398; X64-NEXT:    movq %mm1, %rax399; X64-NEXT:    retq400entry:401  %0 = bitcast <1 x i64> %b to <4 x i16>402  %1 = bitcast <1 x i64> %a to <4 x i16>403  %mmx_var.i = bitcast <4 x i16> %1 to <1 x i64>404  %mmx_var1.i = bitcast <4 x i16> %0 to <1 x i64>405  %2 = tail call <1 x i64> @llvm.x86.mmx.punpcklwd(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind406  %3 = bitcast <1 x i64> %2 to <4 x i16>407  %4 = bitcast <4 x i16> %3 to <1 x i64>408  %5 = extractelement <1 x i64> %4, i32 0409  ret i64 %5410}411 412declare <1 x i64> @llvm.x86.mmx.punpcklbw(<1 x i64>, <1 x i64>) nounwind readnone413 414define i64 @test80(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {415; X86-LABEL: test80:416; X86:       # %bb.0: # %entry417; X86-NEXT:    pushl %ebp418; X86-NEXT:    movl %esp, %ebp419; X86-NEXT:    andl $-8, %esp420; X86-NEXT:    subl $24, %esp421; X86-NEXT:    movl 8(%ebp), %eax422; X86-NEXT:    movl 12(%ebp), %ecx423; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)424; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)425; X86-NEXT:    movl 16(%ebp), %eax426; X86-NEXT:    movl 20(%ebp), %ecx427; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)428; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)429; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm0430; X86-NEXT:    punpcklbw {{[0-9]+}}(%esp), %mm0 # mm0 = mm0[0],mem[0],mm0[1],mem[1],mm0[2],mem[2],mm0[3],mem[3]431; X86-NEXT:    movq %mm0, (%esp)432; X86-NEXT:    movl (%esp), %eax433; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx434; X86-NEXT:    movl %ebp, %esp435; X86-NEXT:    popl %ebp436; X86-NEXT:    retl437;438; X64-LABEL: test80:439; X64:       # %bb.0: # %entry440; X64-NEXT:    movq %rsi, %mm0441; X64-NEXT:    movq %rdi, %mm1442; X64-NEXT:    punpcklbw %mm0, %mm1 # mm1 = mm1[0],mm0[0],mm1[1],mm0[1],mm1[2],mm0[2],mm1[3],mm0[3]443; X64-NEXT:    movq %mm1, %rax444; X64-NEXT:    retq445entry:446  %0 = bitcast <1 x i64> %b to <8 x i8>447  %1 = bitcast <1 x i64> %a to <8 x i8>448  %mmx_var.i = bitcast <8 x i8> %1 to <1 x i64>449  %mmx_var1.i = bitcast <8 x i8> %0 to <1 x i64>450  %2 = tail call <1 x i64> @llvm.x86.mmx.punpcklbw(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind451  %3 = bitcast <1 x i64> %2 to <8 x i8>452  %4 = bitcast <8 x i8> %3 to <1 x i64>453  %5 = extractelement <1 x i64> %4, i32 0454  ret i64 %5455}456 457declare <1 x i64> @llvm.x86.mmx.punpckhdq(<1 x i64>, <1 x i64>) nounwind readnone458 459define i64 @test79(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {460; X86-LABEL: test79:461; X86:       # %bb.0: # %entry462; X86-NEXT:    pushl %ebp463; X86-NEXT:    movl %esp, %ebp464; X86-NEXT:    andl $-8, %esp465; X86-NEXT:    subl $24, %esp466; X86-NEXT:    movl 8(%ebp), %eax467; X86-NEXT:    movl 12(%ebp), %ecx468; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)469; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)470; X86-NEXT:    movl 16(%ebp), %eax471; X86-NEXT:    movl 20(%ebp), %ecx472; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)473; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)474; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm0475; X86-NEXT:    punpckhdq {{[0-9]+}}(%esp), %mm0 # mm0 = mm0[1],mem[1]476; X86-NEXT:    movq %mm0, (%esp)477; X86-NEXT:    movl (%esp), %eax478; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx479; X86-NEXT:    movl %ebp, %esp480; X86-NEXT:    popl %ebp481; X86-NEXT:    retl482;483; X64-LABEL: test79:484; X64:       # %bb.0: # %entry485; X64-NEXT:    movq %rsi, %mm0486; X64-NEXT:    movq %rdi, %mm1487; X64-NEXT:    punpckhdq %mm0, %mm1 # mm1 = mm1[1],mm0[1]488; X64-NEXT:    movq %mm1, %rax489; X64-NEXT:    retq490entry:491  %0 = bitcast <1 x i64> %b to <2 x i32>492  %1 = bitcast <1 x i64> %a to <2 x i32>493  %mmx_var.i = bitcast <2 x i32> %1 to <1 x i64>494  %mmx_var1.i = bitcast <2 x i32> %0 to <1 x i64>495  %2 = tail call <1 x i64> @llvm.x86.mmx.punpckhdq(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind496  %3 = bitcast <1 x i64> %2 to <2 x i32>497  %4 = bitcast <2 x i32> %3 to <1 x i64>498  %5 = extractelement <1 x i64> %4, i32 0499  ret i64 %5500}501 502declare <1 x i64> @llvm.x86.mmx.punpckhwd(<1 x i64>, <1 x i64>) nounwind readnone503 504define i64 @test78(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {505; X86-LABEL: test78:506; X86:       # %bb.0: # %entry507; X86-NEXT:    pushl %ebp508; X86-NEXT:    movl %esp, %ebp509; X86-NEXT:    andl $-8, %esp510; X86-NEXT:    subl $24, %esp511; X86-NEXT:    movl 8(%ebp), %eax512; X86-NEXT:    movl 12(%ebp), %ecx513; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)514; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)515; X86-NEXT:    movl 16(%ebp), %eax516; X86-NEXT:    movl 20(%ebp), %ecx517; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)518; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)519; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm0520; X86-NEXT:    punpckhwd {{[0-9]+}}(%esp), %mm0 # mm0 = mm0[2],mem[2],mm0[3],mem[3]521; X86-NEXT:    movq %mm0, (%esp)522; X86-NEXT:    movl (%esp), %eax523; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx524; X86-NEXT:    movl %ebp, %esp525; X86-NEXT:    popl %ebp526; X86-NEXT:    retl527;528; X64-LABEL: test78:529; X64:       # %bb.0: # %entry530; X64-NEXT:    movq %rsi, %mm0531; X64-NEXT:    movq %rdi, %mm1532; X64-NEXT:    punpckhwd %mm0, %mm1 # mm1 = mm1[2],mm0[2],mm1[3],mm0[3]533; X64-NEXT:    movq %mm1, %rax534; X64-NEXT:    retq535entry:536  %0 = bitcast <1 x i64> %b to <4 x i16>537  %1 = bitcast <1 x i64> %a to <4 x i16>538  %mmx_var.i = bitcast <4 x i16> %1 to <1 x i64>539  %mmx_var1.i = bitcast <4 x i16> %0 to <1 x i64>540  %2 = tail call <1 x i64> @llvm.x86.mmx.punpckhwd(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind541  %3 = bitcast <1 x i64> %2 to <4 x i16>542  %4 = bitcast <4 x i16> %3 to <1 x i64>543  %5 = extractelement <1 x i64> %4, i32 0544  ret i64 %5545}546 547declare <1 x i64> @llvm.x86.mmx.punpckhbw(<1 x i64>, <1 x i64>) nounwind readnone548 549define i64 @test77(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {550; X86-LABEL: test77:551; X86:       # %bb.0: # %entry552; X86-NEXT:    pushl %ebp553; X86-NEXT:    movl %esp, %ebp554; X86-NEXT:    andl $-8, %esp555; X86-NEXT:    subl $24, %esp556; X86-NEXT:    movl 8(%ebp), %eax557; X86-NEXT:    movl 12(%ebp), %ecx558; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)559; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)560; X86-NEXT:    movl 16(%ebp), %eax561; X86-NEXT:    movl 20(%ebp), %ecx562; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)563; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)564; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm0565; X86-NEXT:    punpckhbw {{[0-9]+}}(%esp), %mm0 # mm0 = mm0[4],mem[4],mm0[5],mem[5],mm0[6],mem[6],mm0[7],mem[7]566; X86-NEXT:    movq %mm0, (%esp)567; X86-NEXT:    movl (%esp), %eax568; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx569; X86-NEXT:    movl %ebp, %esp570; X86-NEXT:    popl %ebp571; X86-NEXT:    retl572;573; X64-LABEL: test77:574; X64:       # %bb.0: # %entry575; X64-NEXT:    movq %rsi, %mm0576; X64-NEXT:    movq %rdi, %mm1577; X64-NEXT:    punpckhbw %mm0, %mm1 # mm1 = mm1[4],mm0[4],mm1[5],mm0[5],mm1[6],mm0[6],mm1[7],mm0[7]578; X64-NEXT:    movq %mm1, %rax579; X64-NEXT:    retq580entry:581  %0 = bitcast <1 x i64> %b to <8 x i8>582  %1 = bitcast <1 x i64> %a to <8 x i8>583  %mmx_var.i = bitcast <8 x i8> %1 to <1 x i64>584  %mmx_var1.i = bitcast <8 x i8> %0 to <1 x i64>585  %2 = tail call <1 x i64> @llvm.x86.mmx.punpckhbw(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind586  %3 = bitcast <1 x i64> %2 to <8 x i8>587  %4 = bitcast <8 x i8> %3 to <1 x i64>588  %5 = extractelement <1 x i64> %4, i32 0589  ret i64 %5590}591 592declare <1 x i64> @llvm.x86.mmx.packuswb(<1 x i64>, <1 x i64>) nounwind readnone593 594define i64 @test76(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {595; X86-LABEL: test76:596; X86:       # %bb.0: # %entry597; X86-NEXT:    pushl %ebp598; X86-NEXT:    movl %esp, %ebp599; X86-NEXT:    andl $-8, %esp600; X86-NEXT:    subl $24, %esp601; X86-NEXT:    movl 8(%ebp), %eax602; X86-NEXT:    movl 12(%ebp), %ecx603; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)604; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)605; X86-NEXT:    movl 16(%ebp), %eax606; X86-NEXT:    movl 20(%ebp), %ecx607; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)608; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)609; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm0610; X86-NEXT:    packuswb {{[0-9]+}}(%esp), %mm0611; X86-NEXT:    movq %mm0, (%esp)612; X86-NEXT:    movl (%esp), %eax613; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx614; X86-NEXT:    movl %ebp, %esp615; X86-NEXT:    popl %ebp616; X86-NEXT:    retl617;618; X64-LABEL: test76:619; X64:       # %bb.0: # %entry620; X64-NEXT:    movq %rsi, %mm0621; X64-NEXT:    movq %rdi, %mm1622; X64-NEXT:    packuswb %mm0, %mm1623; X64-NEXT:    movq %mm1, %rax624; X64-NEXT:    retq625entry:626  %0 = bitcast <1 x i64> %b to <4 x i16>627  %1 = bitcast <1 x i64> %a to <4 x i16>628  %mmx_var.i = bitcast <4 x i16> %1 to <1 x i64>629  %mmx_var1.i = bitcast <4 x i16> %0 to <1 x i64>630  %2 = tail call <1 x i64> @llvm.x86.mmx.packuswb(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind631  %3 = bitcast <1 x i64> %2 to <8 x i8>632  %4 = bitcast <8 x i8> %3 to <1 x i64>633  %5 = extractelement <1 x i64> %4, i32 0634  ret i64 %5635}636 637declare <1 x i64> @llvm.x86.mmx.packssdw(<1 x i64>, <1 x i64>) nounwind readnone638 639define i64 @test75(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {640; X86-LABEL: test75:641; X86:       # %bb.0: # %entry642; X86-NEXT:    pushl %ebp643; X86-NEXT:    movl %esp, %ebp644; X86-NEXT:    andl $-8, %esp645; X86-NEXT:    subl $24, %esp646; X86-NEXT:    movl 8(%ebp), %eax647; X86-NEXT:    movl 12(%ebp), %ecx648; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)649; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)650; X86-NEXT:    movl 16(%ebp), %eax651; X86-NEXT:    movl 20(%ebp), %ecx652; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)653; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)654; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm0655; X86-NEXT:    packssdw {{[0-9]+}}(%esp), %mm0656; X86-NEXT:    movq %mm0, (%esp)657; X86-NEXT:    movl (%esp), %eax658; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx659; X86-NEXT:    movl %ebp, %esp660; X86-NEXT:    popl %ebp661; X86-NEXT:    retl662;663; X64-LABEL: test75:664; X64:       # %bb.0: # %entry665; X64-NEXT:    movq %rsi, %mm0666; X64-NEXT:    movq %rdi, %mm1667; X64-NEXT:    packssdw %mm0, %mm1668; X64-NEXT:    movq %mm1, %rax669; X64-NEXT:    retq670entry:671  %0 = bitcast <1 x i64> %b to <2 x i32>672  %1 = bitcast <1 x i64> %a to <2 x i32>673  %mmx_var.i = bitcast <2 x i32> %1 to <1 x i64>674  %mmx_var1.i = bitcast <2 x i32> %0 to <1 x i64>675  %2 = tail call <1 x i64> @llvm.x86.mmx.packssdw(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind676  %3 = bitcast <1 x i64> %2 to <4 x i16>677  %4 = bitcast <4 x i16> %3 to <1 x i64>678  %5 = extractelement <1 x i64> %4, i32 0679  ret i64 %5680}681 682declare <1 x i64> @llvm.x86.mmx.packsswb(<1 x i64>, <1 x i64>) nounwind readnone683 684define i64 @test74(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {685; X86-LABEL: test74:686; X86:       # %bb.0: # %entry687; X86-NEXT:    pushl %ebp688; X86-NEXT:    movl %esp, %ebp689; X86-NEXT:    andl $-8, %esp690; X86-NEXT:    subl $24, %esp691; X86-NEXT:    movl 8(%ebp), %eax692; X86-NEXT:    movl 12(%ebp), %ecx693; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)694; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)695; X86-NEXT:    movl 16(%ebp), %eax696; X86-NEXT:    movl 20(%ebp), %ecx697; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)698; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)699; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm0700; X86-NEXT:    packsswb {{[0-9]+}}(%esp), %mm0701; X86-NEXT:    movq %mm0, (%esp)702; X86-NEXT:    movl (%esp), %eax703; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx704; X86-NEXT:    movl %ebp, %esp705; X86-NEXT:    popl %ebp706; X86-NEXT:    retl707;708; X64-LABEL: test74:709; X64:       # %bb.0: # %entry710; X64-NEXT:    movq %rsi, %mm0711; X64-NEXT:    movq %rdi, %mm1712; X64-NEXT:    packsswb %mm0, %mm1713; X64-NEXT:    movq %mm1, %rax714; X64-NEXT:    retq715entry:716  %0 = bitcast <1 x i64> %b to <4 x i16>717  %1 = bitcast <1 x i64> %a to <4 x i16>718  %mmx_var.i = bitcast <4 x i16> %1 to <1 x i64>719  %mmx_var1.i = bitcast <4 x i16> %0 to <1 x i64>720  %2 = tail call <1 x i64> @llvm.x86.mmx.packsswb(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind721  %3 = bitcast <1 x i64> %2 to <8 x i8>722  %4 = bitcast <8 x i8> %3 to <1 x i64>723  %5 = extractelement <1 x i64> %4, i32 0724  ret i64 %5725}726 727declare <1 x i64> @llvm.x86.mmx.psrai.d(<1 x i64>, i32) nounwind readnone728 729define i64 @test73(<1 x i64> %a) nounwind readnone optsize ssp {730; X86-LABEL: test73:731; X86:       # %bb.0: # %entry732; X86-NEXT:    pushl %ebp733; X86-NEXT:    movl %esp, %ebp734; X86-NEXT:    andl $-8, %esp735; X86-NEXT:    subl $16, %esp736; X86-NEXT:    movl 8(%ebp), %eax737; X86-NEXT:    movl 12(%ebp), %ecx738; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)739; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)740; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm0741; X86-NEXT:    psrad $3, %mm0742; X86-NEXT:    movq %mm0, (%esp)743; X86-NEXT:    movl (%esp), %eax744; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx745; X86-NEXT:    movl %ebp, %esp746; X86-NEXT:    popl %ebp747; X86-NEXT:    retl748;749; X64-LABEL: test73:750; X64:       # %bb.0: # %entry751; X64-NEXT:    movq %rdi, %mm0752; X64-NEXT:    psrad $3, %mm0753; X64-NEXT:    movq %mm0, %rax754; X64-NEXT:    retq755entry:756  %0 = bitcast <1 x i64> %a to <2 x i32>757  %mmx_var.i = bitcast <2 x i32> %0 to <1 x i64>758  %1 = tail call <1 x i64> @llvm.x86.mmx.psrai.d(<1 x i64> %mmx_var.i, i32 3) nounwind759  %2 = bitcast <1 x i64> %1 to <2 x i32>760  %3 = bitcast <2 x i32> %2 to <1 x i64>761  %4 = extractelement <1 x i64> %3, i32 0762  ret i64 %4763}764 765declare <1 x i64> @llvm.x86.mmx.psrai.w(<1 x i64>, i32) nounwind readnone766 767define i64 @test72(<1 x i64> %a) nounwind readnone optsize ssp {768; X86-LABEL: test72:769; X86:       # %bb.0: # %entry770; X86-NEXT:    pushl %ebp771; X86-NEXT:    movl %esp, %ebp772; X86-NEXT:    andl $-8, %esp773; X86-NEXT:    subl $16, %esp774; X86-NEXT:    movl 8(%ebp), %eax775; X86-NEXT:    movl 12(%ebp), %ecx776; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)777; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)778; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm0779; X86-NEXT:    psraw $3, %mm0780; X86-NEXT:    movq %mm0, (%esp)781; X86-NEXT:    movl (%esp), %eax782; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx783; X86-NEXT:    movl %ebp, %esp784; X86-NEXT:    popl %ebp785; X86-NEXT:    retl786;787; X64-LABEL: test72:788; X64:       # %bb.0: # %entry789; X64-NEXT:    movq %rdi, %mm0790; X64-NEXT:    psraw $3, %mm0791; X64-NEXT:    movq %mm0, %rax792; X64-NEXT:    retq793entry:794  %0 = bitcast <1 x i64> %a to <4 x i16>795  %mmx_var.i = bitcast <4 x i16> %0 to <1 x i64>796  %1 = tail call <1 x i64> @llvm.x86.mmx.psrai.w(<1 x i64> %mmx_var.i, i32 3) nounwind797  %2 = bitcast <1 x i64> %1 to <4 x i16>798  %3 = bitcast <4 x i16> %2 to <1 x i64>799  %4 = extractelement <1 x i64> %3, i32 0800  ret i64 %4801}802 803define i64 @test72_2(<1 x i64> %a) nounwind readnone optsize ssp {804; X86-LABEL: test72_2:805; X86:       # %bb.0: # %entry806; X86-NEXT:    pushl %ebp807; X86-NEXT:    movl %esp, %ebp808; X86-NEXT:    andl $-8, %esp809; X86-NEXT:    subl $16, %esp810; X86-NEXT:    movl 8(%ebp), %eax811; X86-NEXT:    movl 12(%ebp), %ecx812; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)813; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)814; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm0815; X86-NEXT:    movq %mm0, (%esp)816; X86-NEXT:    movl (%esp), %eax817; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx818; X86-NEXT:    movl %ebp, %esp819; X86-NEXT:    popl %ebp820; X86-NEXT:    retl821;822; X64-LABEL: test72_2:823; X64:       # %bb.0: # %entry824; X64-NEXT:    movq %rdi, %rax825; X64-NEXT:    retq826entry:827  %0 = bitcast <1 x i64> %a to <4 x i16>828  %mmx_var.i = bitcast <4 x i16> %0 to <1 x i64>829  %1 = tail call <1 x i64> @llvm.x86.mmx.psrai.w(<1 x i64> %mmx_var.i, i32 0) nounwind830  %2 = bitcast <1 x i64> %1 to <4 x i16>831  %3 = bitcast <4 x i16> %2 to <1 x i64>832  %4 = extractelement <1 x i64> %3, i32 0833  ret i64 %4834}835 836declare <1 x i64> @llvm.x86.mmx.psrli.q(<1 x i64>, i32) nounwind readnone837 838define i64 @test71(<1 x i64> %a) nounwind readnone optsize ssp {839; X86-LABEL: test71:840; X86:       # %bb.0: # %entry841; X86-NEXT:    pushl %ebp842; X86-NEXT:    movl %esp, %ebp843; X86-NEXT:    andl $-8, %esp844; X86-NEXT:    subl $8, %esp845; X86-NEXT:    movq 8(%ebp), %mm0846; X86-NEXT:    psrlq $3, %mm0847; X86-NEXT:    movq %mm0, (%esp)848; X86-NEXT:    movl (%esp), %eax849; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx850; X86-NEXT:    movl %ebp, %esp851; X86-NEXT:    popl %ebp852; X86-NEXT:    retl853;854; X64-LABEL: test71:855; X64:       # %bb.0: # %entry856; X64-NEXT:    movq %rdi, %mm0857; X64-NEXT:    psrlq $3, %mm0858; X64-NEXT:    movq %mm0, %rax859; X64-NEXT:    retq860entry:861  %0 = extractelement <1 x i64> %a, i32 0862  %mmx_var.i = bitcast i64 %0 to <1 x i64>863  %1 = tail call <1 x i64> @llvm.x86.mmx.psrli.q(<1 x i64> %mmx_var.i, i32 3) nounwind864  %2 = bitcast <1 x i64> %1 to i64865  ret i64 %2866}867 868declare <1 x i64> @llvm.x86.mmx.psrli.d(<1 x i64>, i32) nounwind readnone869 870define i64 @test70(<1 x i64> %a) nounwind readnone optsize ssp {871; X86-LABEL: test70:872; X86:       # %bb.0: # %entry873; X86-NEXT:    pushl %ebp874; X86-NEXT:    movl %esp, %ebp875; X86-NEXT:    andl $-8, %esp876; X86-NEXT:    subl $16, %esp877; X86-NEXT:    movl 8(%ebp), %eax878; X86-NEXT:    movl 12(%ebp), %ecx879; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)880; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)881; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm0882; X86-NEXT:    psrld $3, %mm0883; X86-NEXT:    movq %mm0, (%esp)884; X86-NEXT:    movl (%esp), %eax885; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx886; X86-NEXT:    movl %ebp, %esp887; X86-NEXT:    popl %ebp888; X86-NEXT:    retl889;890; X64-LABEL: test70:891; X64:       # %bb.0: # %entry892; X64-NEXT:    movq %rdi, %mm0893; X64-NEXT:    psrld $3, %mm0894; X64-NEXT:    movq %mm0, %rax895; X64-NEXT:    retq896entry:897  %0 = bitcast <1 x i64> %a to <2 x i32>898  %mmx_var.i = bitcast <2 x i32> %0 to <1 x i64>899  %1 = tail call <1 x i64> @llvm.x86.mmx.psrli.d(<1 x i64> %mmx_var.i, i32 3) nounwind900  %2 = bitcast <1 x i64> %1 to <2 x i32>901  %3 = bitcast <2 x i32> %2 to <1 x i64>902  %4 = extractelement <1 x i64> %3, i32 0903  ret i64 %4904}905 906define i64 @test70_2(<1 x i64> %a) nounwind readnone optsize ssp {907; X86-LABEL: test70_2:908; X86:       # %bb.0: # %entry909; X86-NEXT:    pushl %ebp910; X86-NEXT:    movl %esp, %ebp911; X86-NEXT:    andl $-8, %esp912; X86-NEXT:    subl $16, %esp913; X86-NEXT:    movl 8(%ebp), %eax914; X86-NEXT:    movl 12(%ebp), %ecx915; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)916; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)917; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm0918; X86-NEXT:    movq %mm0, (%esp)919; X86-NEXT:    movl (%esp), %eax920; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx921; X86-NEXT:    movl %ebp, %esp922; X86-NEXT:    popl %ebp923; X86-NEXT:    retl924;925; X64-LABEL: test70_2:926; X64:       # %bb.0: # %entry927; X64-NEXT:    movq %rdi, %rax928; X64-NEXT:    retq929entry:930  %0 = bitcast <1 x i64> %a to <2 x i32>931  %mmx_var.i = bitcast <2 x i32> %0 to <1 x i64>932  %1 = tail call <1 x i64> @llvm.x86.mmx.psrli.d(<1 x i64> %mmx_var.i, i32 0) nounwind933  %2 = bitcast <1 x i64> %1 to <2 x i32>934  %3 = bitcast <2 x i32> %2 to <1 x i64>935  %4 = extractelement <1 x i64> %3, i32 0936  ret i64 %4937}938 939declare <1 x i64> @llvm.x86.mmx.psrli.w(<1 x i64>, i32) nounwind readnone940 941define i64 @test69(<1 x i64> %a) nounwind readnone optsize ssp {942; X86-LABEL: test69:943; X86:       # %bb.0: # %entry944; X86-NEXT:    pushl %ebp945; X86-NEXT:    movl %esp, %ebp946; X86-NEXT:    andl $-8, %esp947; X86-NEXT:    subl $16, %esp948; X86-NEXT:    movl 8(%ebp), %eax949; X86-NEXT:    movl 12(%ebp), %ecx950; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)951; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)952; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm0953; X86-NEXT:    psrlw $3, %mm0954; X86-NEXT:    movq %mm0, (%esp)955; X86-NEXT:    movl (%esp), %eax956; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx957; X86-NEXT:    movl %ebp, %esp958; X86-NEXT:    popl %ebp959; X86-NEXT:    retl960;961; X64-LABEL: test69:962; X64:       # %bb.0: # %entry963; X64-NEXT:    movq %rdi, %mm0964; X64-NEXT:    psrlw $3, %mm0965; X64-NEXT:    movq %mm0, %rax966; X64-NEXT:    retq967entry:968  %0 = bitcast <1 x i64> %a to <4 x i16>969  %mmx_var.i = bitcast <4 x i16> %0 to <1 x i64>970  %1 = tail call <1 x i64> @llvm.x86.mmx.psrli.w(<1 x i64> %mmx_var.i, i32 3) nounwind971  %2 = bitcast <1 x i64> %1 to <4 x i16>972  %3 = bitcast <4 x i16> %2 to <1 x i64>973  %4 = extractelement <1 x i64> %3, i32 0974  ret i64 %4975}976 977declare <1 x i64> @llvm.x86.mmx.pslli.q(<1 x i64>, i32) nounwind readnone978 979define i64 @test68(<1 x i64> %a) nounwind readnone optsize ssp {980; X86-LABEL: test68:981; X86:       # %bb.0: # %entry982; X86-NEXT:    pushl %ebp983; X86-NEXT:    movl %esp, %ebp984; X86-NEXT:    andl $-8, %esp985; X86-NEXT:    subl $8, %esp986; X86-NEXT:    movq 8(%ebp), %mm0987; X86-NEXT:    psllq $3, %mm0988; X86-NEXT:    movq %mm0, (%esp)989; X86-NEXT:    movl (%esp), %eax990; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx991; X86-NEXT:    movl %ebp, %esp992; X86-NEXT:    popl %ebp993; X86-NEXT:    retl994;995; X64-LABEL: test68:996; X64:       # %bb.0: # %entry997; X64-NEXT:    movq %rdi, %mm0998; X64-NEXT:    psllq $3, %mm0999; X64-NEXT:    movq %mm0, %rax1000; X64-NEXT:    retq1001entry:1002  %0 = extractelement <1 x i64> %a, i32 01003  %mmx_var.i = bitcast i64 %0 to <1 x i64>1004  %1 = tail call <1 x i64> @llvm.x86.mmx.pslli.q(<1 x i64> %mmx_var.i, i32 3) nounwind1005  %2 = bitcast <1 x i64> %1 to i641006  ret i64 %21007}1008 1009declare <1 x i64> @llvm.x86.mmx.pslli.d(<1 x i64>, i32) nounwind readnone1010 1011define i64 @test67(<1 x i64> %a) nounwind readnone optsize ssp {1012; X86-LABEL: test67:1013; X86:       # %bb.0: # %entry1014; X86-NEXT:    pushl %ebp1015; X86-NEXT:    movl %esp, %ebp1016; X86-NEXT:    andl $-8, %esp1017; X86-NEXT:    subl $16, %esp1018; X86-NEXT:    movl 8(%ebp), %eax1019; X86-NEXT:    movl 12(%ebp), %ecx1020; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)1021; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)1022; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm01023; X86-NEXT:    pslld $3, %mm01024; X86-NEXT:    movq %mm0, (%esp)1025; X86-NEXT:    movl (%esp), %eax1026; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx1027; X86-NEXT:    movl %ebp, %esp1028; X86-NEXT:    popl %ebp1029; X86-NEXT:    retl1030;1031; X64-LABEL: test67:1032; X64:       # %bb.0: # %entry1033; X64-NEXT:    movq %rdi, %mm01034; X64-NEXT:    pslld $3, %mm01035; X64-NEXT:    movq %mm0, %rax1036; X64-NEXT:    retq1037entry:1038  %0 = bitcast <1 x i64> %a to <2 x i32>1039  %mmx_var.i = bitcast <2 x i32> %0 to <1 x i64>1040  %1 = tail call <1 x i64> @llvm.x86.mmx.pslli.d(<1 x i64> %mmx_var.i, i32 3) nounwind1041  %2 = bitcast <1 x i64> %1 to <2 x i32>1042  %3 = bitcast <2 x i32> %2 to <1 x i64>1043  %4 = extractelement <1 x i64> %3, i32 01044  ret i64 %41045}1046 1047declare <1 x i64> @llvm.x86.mmx.pslli.w(<1 x i64>, i32) nounwind readnone1048 1049define i64 @test66(<1 x i64> %a) nounwind readnone optsize ssp {1050; X86-LABEL: test66:1051; X86:       # %bb.0: # %entry1052; X86-NEXT:    pushl %ebp1053; X86-NEXT:    movl %esp, %ebp1054; X86-NEXT:    andl $-8, %esp1055; X86-NEXT:    subl $16, %esp1056; X86-NEXT:    movl 8(%ebp), %eax1057; X86-NEXT:    movl 12(%ebp), %ecx1058; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)1059; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)1060; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm01061; X86-NEXT:    psllw $3, %mm01062; X86-NEXT:    movq %mm0, (%esp)1063; X86-NEXT:    movl (%esp), %eax1064; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx1065; X86-NEXT:    movl %ebp, %esp1066; X86-NEXT:    popl %ebp1067; X86-NEXT:    retl1068;1069; X64-LABEL: test66:1070; X64:       # %bb.0: # %entry1071; X64-NEXT:    movq %rdi, %mm01072; X64-NEXT:    psllw $3, %mm01073; X64-NEXT:    movq %mm0, %rax1074; X64-NEXT:    retq1075entry:1076  %0 = bitcast <1 x i64> %a to <4 x i16>1077  %mmx_var.i = bitcast <4 x i16> %0 to <1 x i64>1078  %1 = tail call <1 x i64> @llvm.x86.mmx.pslli.w(<1 x i64> %mmx_var.i, i32 3) nounwind1079  %2 = bitcast <1 x i64> %1 to <4 x i16>1080  %3 = bitcast <4 x i16> %2 to <1 x i64>1081  %4 = extractelement <1 x i64> %3, i32 01082  ret i64 %41083}1084 1085define i64 @test66_2(<1 x i64> %a) nounwind readnone optsize ssp {1086; X86-LABEL: test66_2:1087; X86:       # %bb.0: # %entry1088; X86-NEXT:    pushl %ebp1089; X86-NEXT:    movl %esp, %ebp1090; X86-NEXT:    andl $-8, %esp1091; X86-NEXT:    subl $16, %esp1092; X86-NEXT:    movl 8(%ebp), %eax1093; X86-NEXT:    movl 12(%ebp), %ecx1094; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)1095; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)1096; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm01097; X86-NEXT:    movq %mm0, (%esp)1098; X86-NEXT:    movl (%esp), %eax1099; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx1100; X86-NEXT:    movl %ebp, %esp1101; X86-NEXT:    popl %ebp1102; X86-NEXT:    retl1103;1104; X64-LABEL: test66_2:1105; X64:       # %bb.0: # %entry1106; X64-NEXT:    movq %rdi, %rax1107; X64-NEXT:    retq1108entry:1109  %0 = bitcast <1 x i64> %a to <4 x i16>1110  %mmx_var.i = bitcast <4 x i16> %0 to <1 x i64>1111  %1 = tail call <1 x i64> @llvm.x86.mmx.pslli.w(<1 x i64> %mmx_var.i, i32 0) nounwind1112  %2 = bitcast <1 x i64> %1 to <4 x i16>1113  %3 = bitcast <4 x i16> %2 to <1 x i64>1114  %4 = extractelement <1 x i64> %3, i32 01115  ret i64 %41116}1117 1118declare <1 x i64> @llvm.x86.mmx.psra.d(<1 x i64>, <1 x i64>) nounwind readnone1119 1120define i64 @test65(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {1121; X86-LABEL: test65:1122; X86:       # %bb.0: # %entry1123; X86-NEXT:    pushl %ebp1124; X86-NEXT:    movl %esp, %ebp1125; X86-NEXT:    andl $-8, %esp1126; X86-NEXT:    subl $16, %esp1127; X86-NEXT:    movl 8(%ebp), %eax1128; X86-NEXT:    movl 12(%ebp), %ecx1129; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)1130; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)1131; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm01132; X86-NEXT:    psrad 16(%ebp), %mm01133; X86-NEXT:    movq %mm0, (%esp)1134; X86-NEXT:    movl (%esp), %eax1135; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx1136; X86-NEXT:    movl %ebp, %esp1137; X86-NEXT:    popl %ebp1138; X86-NEXT:    retl1139;1140; X64-LABEL: test65:1141; X64:       # %bb.0: # %entry1142; X64-NEXT:    movq %rdi, %mm01143; X64-NEXT:    movq %rsi, %mm11144; X64-NEXT:    psrad %mm1, %mm01145; X64-NEXT:    movq %mm0, %rax1146; X64-NEXT:    retq1147entry:1148  %0 = bitcast <1 x i64> %a to <2 x i32>1149  %mmx_var.i = bitcast <2 x i32> %0 to <1 x i64>1150  %1 = extractelement <1 x i64> %b, i32 01151  %mmx_var1.i = bitcast i64 %1 to <1 x i64>1152  %2 = tail call <1 x i64> @llvm.x86.mmx.psra.d(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind1153  %3 = bitcast <1 x i64> %2 to <2 x i32>1154  %4 = bitcast <2 x i32> %3 to <1 x i64>1155  %5 = extractelement <1 x i64> %4, i32 01156  ret i64 %51157}1158 1159declare <1 x i64> @llvm.x86.mmx.psra.w(<1 x i64>, <1 x i64>) nounwind readnone1160 1161define i64 @test64(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {1162; X86-LABEL: test64:1163; X86:       # %bb.0: # %entry1164; X86-NEXT:    pushl %ebp1165; X86-NEXT:    movl %esp, %ebp1166; X86-NEXT:    andl $-8, %esp1167; X86-NEXT:    subl $16, %esp1168; X86-NEXT:    movl 8(%ebp), %eax1169; X86-NEXT:    movl 12(%ebp), %ecx1170; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)1171; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)1172; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm01173; X86-NEXT:    psraw 16(%ebp), %mm01174; X86-NEXT:    movq %mm0, (%esp)1175; X86-NEXT:    movl (%esp), %eax1176; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx1177; X86-NEXT:    movl %ebp, %esp1178; X86-NEXT:    popl %ebp1179; X86-NEXT:    retl1180;1181; X64-LABEL: test64:1182; X64:       # %bb.0: # %entry1183; X64-NEXT:    movq %rdi, %mm01184; X64-NEXT:    movq %rsi, %mm11185; X64-NEXT:    psraw %mm1, %mm01186; X64-NEXT:    movq %mm0, %rax1187; X64-NEXT:    retq1188entry:1189  %0 = bitcast <1 x i64> %a to <4 x i16>1190  %mmx_var.i = bitcast <4 x i16> %0 to <1 x i64>1191  %1 = extractelement <1 x i64> %b, i32 01192  %mmx_var1.i = bitcast i64 %1 to <1 x i64>1193  %2 = tail call <1 x i64> @llvm.x86.mmx.psra.w(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind1194  %3 = bitcast <1 x i64> %2 to <4 x i16>1195  %4 = bitcast <4 x i16> %3 to <1 x i64>1196  %5 = extractelement <1 x i64> %4, i32 01197  ret i64 %51198}1199 1200declare <1 x i64> @llvm.x86.mmx.psrl.q(<1 x i64>, <1 x i64>) nounwind readnone1201 1202define i64 @test63(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {1203; X86-LABEL: test63:1204; X86:       # %bb.0: # %entry1205; X86-NEXT:    pushl %ebp1206; X86-NEXT:    movl %esp, %ebp1207; X86-NEXT:    andl $-8, %esp1208; X86-NEXT:    subl $8, %esp1209; X86-NEXT:    movq 8(%ebp), %mm01210; X86-NEXT:    psrlq 16(%ebp), %mm01211; X86-NEXT:    movq %mm0, (%esp)1212; X86-NEXT:    movl (%esp), %eax1213; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx1214; X86-NEXT:    movl %ebp, %esp1215; X86-NEXT:    popl %ebp1216; X86-NEXT:    retl1217;1218; X64-LABEL: test63:1219; X64:       # %bb.0: # %entry1220; X64-NEXT:    movq %rdi, %mm01221; X64-NEXT:    movq %rsi, %mm11222; X64-NEXT:    psrlq %mm1, %mm01223; X64-NEXT:    movq %mm0, %rax1224; X64-NEXT:    retq1225entry:1226  %0 = extractelement <1 x i64> %a, i32 01227  %mmx_var.i = bitcast i64 %0 to <1 x i64>1228  %1 = extractelement <1 x i64> %b, i32 01229  %mmx_var1.i = bitcast i64 %1 to <1 x i64>1230  %2 = tail call <1 x i64> @llvm.x86.mmx.psrl.q(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind1231  %3 = bitcast <1 x i64> %2 to i641232  ret i64 %31233}1234 1235declare <1 x i64> @llvm.x86.mmx.psrl.d(<1 x i64>, <1 x i64>) nounwind readnone1236 1237define i64 @test62(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {1238; X86-LABEL: test62:1239; X86:       # %bb.0: # %entry1240; X86-NEXT:    pushl %ebp1241; X86-NEXT:    movl %esp, %ebp1242; X86-NEXT:    andl $-8, %esp1243; X86-NEXT:    subl $16, %esp1244; X86-NEXT:    movl 8(%ebp), %eax1245; X86-NEXT:    movl 12(%ebp), %ecx1246; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)1247; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)1248; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm01249; X86-NEXT:    psrld 16(%ebp), %mm01250; X86-NEXT:    movq %mm0, (%esp)1251; X86-NEXT:    movl (%esp), %eax1252; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx1253; X86-NEXT:    movl %ebp, %esp1254; X86-NEXT:    popl %ebp1255; X86-NEXT:    retl1256;1257; X64-LABEL: test62:1258; X64:       # %bb.0: # %entry1259; X64-NEXT:    movq %rdi, %mm01260; X64-NEXT:    movq %rsi, %mm11261; X64-NEXT:    psrld %mm1, %mm01262; X64-NEXT:    movq %mm0, %rax1263; X64-NEXT:    retq1264entry:1265  %0 = bitcast <1 x i64> %a to <2 x i32>1266  %mmx_var.i = bitcast <2 x i32> %0 to <1 x i64>1267  %1 = extractelement <1 x i64> %b, i32 01268  %mmx_var1.i = bitcast i64 %1 to <1 x i64>1269  %2 = tail call <1 x i64> @llvm.x86.mmx.psrl.d(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind1270  %3 = bitcast <1 x i64> %2 to <2 x i32>1271  %4 = bitcast <2 x i32> %3 to <1 x i64>1272  %5 = extractelement <1 x i64> %4, i32 01273  ret i64 %51274}1275 1276declare <1 x i64> @llvm.x86.mmx.psrl.w(<1 x i64>, <1 x i64>) nounwind readnone1277 1278define i64 @test61(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {1279; X86-LABEL: test61:1280; X86:       # %bb.0: # %entry1281; X86-NEXT:    pushl %ebp1282; X86-NEXT:    movl %esp, %ebp1283; X86-NEXT:    andl $-8, %esp1284; X86-NEXT:    subl $16, %esp1285; X86-NEXT:    movl 8(%ebp), %eax1286; X86-NEXT:    movl 12(%ebp), %ecx1287; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)1288; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)1289; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm01290; X86-NEXT:    psrlw 16(%ebp), %mm01291; X86-NEXT:    movq %mm0, (%esp)1292; X86-NEXT:    movl (%esp), %eax1293; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx1294; X86-NEXT:    movl %ebp, %esp1295; X86-NEXT:    popl %ebp1296; X86-NEXT:    retl1297;1298; X64-LABEL: test61:1299; X64:       # %bb.0: # %entry1300; X64-NEXT:    movq %rdi, %mm01301; X64-NEXT:    movq %rsi, %mm11302; X64-NEXT:    psrlw %mm1, %mm01303; X64-NEXT:    movq %mm0, %rax1304; X64-NEXT:    retq1305entry:1306  %0 = bitcast <1 x i64> %a to <4 x i16>1307  %mmx_var.i = bitcast <4 x i16> %0 to <1 x i64>1308  %1 = extractelement <1 x i64> %b, i32 01309  %mmx_var1.i = bitcast i64 %1 to <1 x i64>1310  %2 = tail call <1 x i64> @llvm.x86.mmx.psrl.w(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind1311  %3 = bitcast <1 x i64> %2 to <4 x i16>1312  %4 = bitcast <4 x i16> %3 to <1 x i64>1313  %5 = extractelement <1 x i64> %4, i32 01314  ret i64 %51315}1316 1317declare <1 x i64> @llvm.x86.mmx.psll.q(<1 x i64>, <1 x i64>) nounwind readnone1318 1319define i64 @test60(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {1320; X86-LABEL: test60:1321; X86:       # %bb.0: # %entry1322; X86-NEXT:    pushl %ebp1323; X86-NEXT:    movl %esp, %ebp1324; X86-NEXT:    andl $-8, %esp1325; X86-NEXT:    subl $8, %esp1326; X86-NEXT:    movq 8(%ebp), %mm01327; X86-NEXT:    psllq 16(%ebp), %mm01328; X86-NEXT:    movq %mm0, (%esp)1329; X86-NEXT:    movl (%esp), %eax1330; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx1331; X86-NEXT:    movl %ebp, %esp1332; X86-NEXT:    popl %ebp1333; X86-NEXT:    retl1334;1335; X64-LABEL: test60:1336; X64:       # %bb.0: # %entry1337; X64-NEXT:    movq %rdi, %mm01338; X64-NEXT:    movq %rsi, %mm11339; X64-NEXT:    psllq %mm1, %mm01340; X64-NEXT:    movq %mm0, %rax1341; X64-NEXT:    retq1342entry:1343  %0 = extractelement <1 x i64> %a, i32 01344  %mmx_var.i = bitcast i64 %0 to <1 x i64>1345  %1 = extractelement <1 x i64> %b, i32 01346  %mmx_var1.i = bitcast i64 %1 to <1 x i64>1347  %2 = tail call <1 x i64> @llvm.x86.mmx.psll.q(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind1348  %3 = bitcast <1 x i64> %2 to i641349  ret i64 %31350}1351 1352declare <1 x i64> @llvm.x86.mmx.psll.d(<1 x i64>, <1 x i64>) nounwind readnone1353 1354define i64 @test59(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {1355; X86-LABEL: test59:1356; X86:       # %bb.0: # %entry1357; X86-NEXT:    pushl %ebp1358; X86-NEXT:    movl %esp, %ebp1359; X86-NEXT:    andl $-8, %esp1360; X86-NEXT:    subl $16, %esp1361; X86-NEXT:    movl 8(%ebp), %eax1362; X86-NEXT:    movl 12(%ebp), %ecx1363; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)1364; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)1365; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm01366; X86-NEXT:    pslld 16(%ebp), %mm01367; X86-NEXT:    movq %mm0, (%esp)1368; X86-NEXT:    movl (%esp), %eax1369; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx1370; X86-NEXT:    movl %ebp, %esp1371; X86-NEXT:    popl %ebp1372; X86-NEXT:    retl1373;1374; X64-LABEL: test59:1375; X64:       # %bb.0: # %entry1376; X64-NEXT:    movq %rdi, %mm01377; X64-NEXT:    movq %rsi, %mm11378; X64-NEXT:    pslld %mm1, %mm01379; X64-NEXT:    movq %mm0, %rax1380; X64-NEXT:    retq1381entry:1382  %0 = bitcast <1 x i64> %a to <2 x i32>1383  %mmx_var.i = bitcast <2 x i32> %0 to <1 x i64>1384  %1 = extractelement <1 x i64> %b, i32 01385  %mmx_var1.i = bitcast i64 %1 to <1 x i64>1386  %2 = tail call <1 x i64> @llvm.x86.mmx.psll.d(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind1387  %3 = bitcast <1 x i64> %2 to <2 x i32>1388  %4 = bitcast <2 x i32> %3 to <1 x i64>1389  %5 = extractelement <1 x i64> %4, i32 01390  ret i64 %51391}1392 1393declare <1 x i64> @llvm.x86.mmx.psll.w(<1 x i64>, <1 x i64>) nounwind readnone1394 1395define i64 @test58(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {1396; X86-LABEL: test58:1397; X86:       # %bb.0: # %entry1398; X86-NEXT:    pushl %ebp1399; X86-NEXT:    movl %esp, %ebp1400; X86-NEXT:    andl $-8, %esp1401; X86-NEXT:    subl $16, %esp1402; X86-NEXT:    movl 8(%ebp), %eax1403; X86-NEXT:    movl 12(%ebp), %ecx1404; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)1405; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)1406; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm01407; X86-NEXT:    psllw 16(%ebp), %mm01408; X86-NEXT:    movq %mm0, (%esp)1409; X86-NEXT:    movl (%esp), %eax1410; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx1411; X86-NEXT:    movl %ebp, %esp1412; X86-NEXT:    popl %ebp1413; X86-NEXT:    retl1414;1415; X64-LABEL: test58:1416; X64:       # %bb.0: # %entry1417; X64-NEXT:    movq %rdi, %mm01418; X64-NEXT:    movq %rsi, %mm11419; X64-NEXT:    psllw %mm1, %mm01420; X64-NEXT:    movq %mm0, %rax1421; X64-NEXT:    retq1422entry:1423  %0 = bitcast <1 x i64> %a to <4 x i16>1424  %mmx_var.i = bitcast <4 x i16> %0 to <1 x i64>1425  %1 = extractelement <1 x i64> %b, i32 01426  %mmx_var1.i = bitcast i64 %1 to <1 x i64>1427  %2 = tail call <1 x i64> @llvm.x86.mmx.psll.w(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind1428  %3 = bitcast <1 x i64> %2 to <4 x i16>1429  %4 = bitcast <4 x i16> %3 to <1 x i64>1430  %5 = extractelement <1 x i64> %4, i32 01431  ret i64 %51432}1433 1434declare <1 x i64> @llvm.x86.mmx.pxor(<1 x i64>, <1 x i64>) nounwind readnone1435 1436define i64 @test56(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {1437; X86-LABEL: test56:1438; X86:       # %bb.0: # %entry1439; X86-NEXT:    pushl %ebp1440; X86-NEXT:    movl %esp, %ebp1441; X86-NEXT:    andl $-8, %esp1442; X86-NEXT:    subl $24, %esp1443; X86-NEXT:    movl 8(%ebp), %eax1444; X86-NEXT:    movl 12(%ebp), %ecx1445; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)1446; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)1447; X86-NEXT:    movl 16(%ebp), %eax1448; X86-NEXT:    movl 20(%ebp), %ecx1449; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)1450; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)1451; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm01452; X86-NEXT:    pxor {{[0-9]+}}(%esp), %mm01453; X86-NEXT:    movq %mm0, (%esp)1454; X86-NEXT:    movl (%esp), %eax1455; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx1456; X86-NEXT:    movl %ebp, %esp1457; X86-NEXT:    popl %ebp1458; X86-NEXT:    retl1459;1460; X64-LABEL: test56:1461; X64:       # %bb.0: # %entry1462; X64-NEXT:    movq %rsi, %mm01463; X64-NEXT:    movq %rdi, %mm11464; X64-NEXT:    pxor %mm0, %mm11465; X64-NEXT:    movq %mm1, %rax1466; X64-NEXT:    retq1467entry:1468  %0 = bitcast <1 x i64> %b to <2 x i32>1469  %1 = bitcast <1 x i64> %a to <2 x i32>1470  %mmx_var.i = bitcast <2 x i32> %1 to <1 x i64>1471  %mmx_var1.i = bitcast <2 x i32> %0 to <1 x i64>1472  %2 = tail call <1 x i64> @llvm.x86.mmx.pxor(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind1473  %3 = bitcast <1 x i64> %2 to <2 x i32>1474  %4 = bitcast <2 x i32> %3 to <1 x i64>1475  %5 = extractelement <1 x i64> %4, i32 01476  ret i64 %51477}1478 1479declare <1 x i64> @llvm.x86.mmx.por(<1 x i64>, <1 x i64>) nounwind readnone1480 1481define i64 @test55(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {1482; X86-LABEL: test55:1483; X86:       # %bb.0: # %entry1484; X86-NEXT:    pushl %ebp1485; X86-NEXT:    movl %esp, %ebp1486; X86-NEXT:    andl $-8, %esp1487; X86-NEXT:    subl $24, %esp1488; X86-NEXT:    movl 8(%ebp), %eax1489; X86-NEXT:    movl 12(%ebp), %ecx1490; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)1491; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)1492; X86-NEXT:    movl 16(%ebp), %eax1493; X86-NEXT:    movl 20(%ebp), %ecx1494; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)1495; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)1496; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm01497; X86-NEXT:    por {{[0-9]+}}(%esp), %mm01498; X86-NEXT:    movq %mm0, (%esp)1499; X86-NEXT:    movl (%esp), %eax1500; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx1501; X86-NEXT:    movl %ebp, %esp1502; X86-NEXT:    popl %ebp1503; X86-NEXT:    retl1504;1505; X64-LABEL: test55:1506; X64:       # %bb.0: # %entry1507; X64-NEXT:    movq %rsi, %mm01508; X64-NEXT:    movq %rdi, %mm11509; X64-NEXT:    por %mm0, %mm11510; X64-NEXT:    movq %mm1, %rax1511; X64-NEXT:    retq1512entry:1513  %0 = bitcast <1 x i64> %b to <2 x i32>1514  %1 = bitcast <1 x i64> %a to <2 x i32>1515  %mmx_var.i = bitcast <2 x i32> %1 to <1 x i64>1516  %mmx_var1.i = bitcast <2 x i32> %0 to <1 x i64>1517  %2 = tail call <1 x i64> @llvm.x86.mmx.por(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind1518  %3 = bitcast <1 x i64> %2 to <2 x i32>1519  %4 = bitcast <2 x i32> %3 to <1 x i64>1520  %5 = extractelement <1 x i64> %4, i32 01521  ret i64 %51522}1523 1524declare <1 x i64> @llvm.x86.mmx.pandn(<1 x i64>, <1 x i64>) nounwind readnone1525 1526define i64 @test54(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {1527; X86-LABEL: test54:1528; X86:       # %bb.0: # %entry1529; X86-NEXT:    pushl %ebp1530; X86-NEXT:    movl %esp, %ebp1531; X86-NEXT:    andl $-8, %esp1532; X86-NEXT:    subl $24, %esp1533; X86-NEXT:    movl 8(%ebp), %eax1534; X86-NEXT:    movl 12(%ebp), %ecx1535; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)1536; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)1537; X86-NEXT:    movl 16(%ebp), %eax1538; X86-NEXT:    movl 20(%ebp), %ecx1539; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)1540; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)1541; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm01542; X86-NEXT:    pandn {{[0-9]+}}(%esp), %mm01543; X86-NEXT:    movq %mm0, (%esp)1544; X86-NEXT:    movl (%esp), %eax1545; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx1546; X86-NEXT:    movl %ebp, %esp1547; X86-NEXT:    popl %ebp1548; X86-NEXT:    retl1549;1550; X64-LABEL: test54:1551; X64:       # %bb.0: # %entry1552; X64-NEXT:    movq %rsi, %mm01553; X64-NEXT:    movq %rdi, %mm11554; X64-NEXT:    pandn %mm0, %mm11555; X64-NEXT:    movq %mm1, %rax1556; X64-NEXT:    retq1557entry:1558  %0 = bitcast <1 x i64> %b to <2 x i32>1559  %1 = bitcast <1 x i64> %a to <2 x i32>1560  %mmx_var.i = bitcast <2 x i32> %1 to <1 x i64>1561  %mmx_var1.i = bitcast <2 x i32> %0 to <1 x i64>1562  %2 = tail call <1 x i64> @llvm.x86.mmx.pandn(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind1563  %3 = bitcast <1 x i64> %2 to <2 x i32>1564  %4 = bitcast <2 x i32> %3 to <1 x i64>1565  %5 = extractelement <1 x i64> %4, i32 01566  ret i64 %51567}1568 1569declare <1 x i64> @llvm.x86.mmx.pand(<1 x i64>, <1 x i64>) nounwind readnone1570 1571define i64 @test53(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {1572; X86-LABEL: test53:1573; X86:       # %bb.0: # %entry1574; X86-NEXT:    pushl %ebp1575; X86-NEXT:    movl %esp, %ebp1576; X86-NEXT:    andl $-8, %esp1577; X86-NEXT:    subl $24, %esp1578; X86-NEXT:    movl 8(%ebp), %eax1579; X86-NEXT:    movl 12(%ebp), %ecx1580; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)1581; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)1582; X86-NEXT:    movl 16(%ebp), %eax1583; X86-NEXT:    movl 20(%ebp), %ecx1584; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)1585; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)1586; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm01587; X86-NEXT:    pand {{[0-9]+}}(%esp), %mm01588; X86-NEXT:    movq %mm0, (%esp)1589; X86-NEXT:    movl (%esp), %eax1590; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx1591; X86-NEXT:    movl %ebp, %esp1592; X86-NEXT:    popl %ebp1593; X86-NEXT:    retl1594;1595; X64-LABEL: test53:1596; X64:       # %bb.0: # %entry1597; X64-NEXT:    movq %rsi, %mm01598; X64-NEXT:    movq %rdi, %mm11599; X64-NEXT:    pand %mm0, %mm11600; X64-NEXT:    movq %mm1, %rax1601; X64-NEXT:    retq1602entry:1603  %0 = bitcast <1 x i64> %b to <2 x i32>1604  %1 = bitcast <1 x i64> %a to <2 x i32>1605  %mmx_var.i = bitcast <2 x i32> %1 to <1 x i64>1606  %mmx_var1.i = bitcast <2 x i32> %0 to <1 x i64>1607  %2 = tail call <1 x i64> @llvm.x86.mmx.pand(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind1608  %3 = bitcast <1 x i64> %2 to <2 x i32>1609  %4 = bitcast <2 x i32> %3 to <1 x i64>1610  %5 = extractelement <1 x i64> %4, i32 01611  ret i64 %51612}1613 1614declare <1 x i64> @llvm.x86.mmx.pmull.w(<1 x i64>, <1 x i64>) nounwind readnone1615 1616define i64 @test52(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {1617; X86-LABEL: test52:1618; X86:       # %bb.0: # %entry1619; X86-NEXT:    pushl %ebp1620; X86-NEXT:    movl %esp, %ebp1621; X86-NEXT:    andl $-8, %esp1622; X86-NEXT:    subl $24, %esp1623; X86-NEXT:    movl 8(%ebp), %eax1624; X86-NEXT:    movl 12(%ebp), %ecx1625; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)1626; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)1627; X86-NEXT:    movl 16(%ebp), %eax1628; X86-NEXT:    movl 20(%ebp), %ecx1629; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)1630; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)1631; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm01632; X86-NEXT:    pmullw {{[0-9]+}}(%esp), %mm01633; X86-NEXT:    movq %mm0, (%esp)1634; X86-NEXT:    movl (%esp), %eax1635; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx1636; X86-NEXT:    movl %ebp, %esp1637; X86-NEXT:    popl %ebp1638; X86-NEXT:    retl1639;1640; X64-LABEL: test52:1641; X64:       # %bb.0: # %entry1642; X64-NEXT:    movq %rsi, %mm01643; X64-NEXT:    movq %rdi, %mm11644; X64-NEXT:    pmullw %mm0, %mm11645; X64-NEXT:    movq %mm1, %rax1646; X64-NEXT:    retq1647entry:1648  %0 = bitcast <1 x i64> %b to <4 x i16>1649  %1 = bitcast <1 x i64> %a to <4 x i16>1650  %mmx_var.i = bitcast <4 x i16> %1 to <1 x i64>1651  %mmx_var1.i = bitcast <4 x i16> %0 to <1 x i64>1652  %2 = tail call <1 x i64> @llvm.x86.mmx.pmull.w(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind1653  %3 = bitcast <1 x i64> %2 to <4 x i16>1654  %4 = bitcast <4 x i16> %3 to <1 x i64>1655  %5 = extractelement <1 x i64> %4, i32 01656  ret i64 %51657}1658 1659define i64 @test51(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {1660; X86-LABEL: test51:1661; X86:       # %bb.0: # %entry1662; X86-NEXT:    pushl %ebp1663; X86-NEXT:    movl %esp, %ebp1664; X86-NEXT:    andl $-8, %esp1665; X86-NEXT:    subl $24, %esp1666; X86-NEXT:    movl 8(%ebp), %eax1667; X86-NEXT:    movl 12(%ebp), %ecx1668; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)1669; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)1670; X86-NEXT:    movl 16(%ebp), %eax1671; X86-NEXT:    movl 20(%ebp), %ecx1672; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)1673; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)1674; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm01675; X86-NEXT:    pmullw {{[0-9]+}}(%esp), %mm01676; X86-NEXT:    movq %mm0, (%esp)1677; X86-NEXT:    movl (%esp), %eax1678; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx1679; X86-NEXT:    movl %ebp, %esp1680; X86-NEXT:    popl %ebp1681; X86-NEXT:    retl1682;1683; X64-LABEL: test51:1684; X64:       # %bb.0: # %entry1685; X64-NEXT:    movq %rsi, %mm01686; X64-NEXT:    movq %rdi, %mm11687; X64-NEXT:    pmullw %mm0, %mm11688; X64-NEXT:    movq %mm1, %rax1689; X64-NEXT:    retq1690entry:1691  %0 = bitcast <1 x i64> %b to <4 x i16>1692  %1 = bitcast <1 x i64> %a to <4 x i16>1693  %mmx_var.i = bitcast <4 x i16> %1 to <1 x i64>1694  %mmx_var1.i = bitcast <4 x i16> %0 to <1 x i64>1695  %2 = tail call <1 x i64> @llvm.x86.mmx.pmull.w(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind1696  %3 = bitcast <1 x i64> %2 to <4 x i16>1697  %4 = bitcast <4 x i16> %3 to <1 x i64>1698  %5 = extractelement <1 x i64> %4, i32 01699  ret i64 %51700}1701 1702declare <1 x i64> @llvm.x86.mmx.pmulh.w(<1 x i64>, <1 x i64>) nounwind readnone1703 1704define i64 @test50(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {1705; X86-LABEL: test50:1706; X86:       # %bb.0: # %entry1707; X86-NEXT:    pushl %ebp1708; X86-NEXT:    movl %esp, %ebp1709; X86-NEXT:    andl $-8, %esp1710; X86-NEXT:    subl $24, %esp1711; X86-NEXT:    movl 8(%ebp), %eax1712; X86-NEXT:    movl 12(%ebp), %ecx1713; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)1714; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)1715; X86-NEXT:    movl 16(%ebp), %eax1716; X86-NEXT:    movl 20(%ebp), %ecx1717; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)1718; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)1719; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm01720; X86-NEXT:    pmulhw {{[0-9]+}}(%esp), %mm01721; X86-NEXT:    movq %mm0, (%esp)1722; X86-NEXT:    movl (%esp), %eax1723; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx1724; X86-NEXT:    movl %ebp, %esp1725; X86-NEXT:    popl %ebp1726; X86-NEXT:    retl1727;1728; X64-LABEL: test50:1729; X64:       # %bb.0: # %entry1730; X64-NEXT:    movq %rsi, %mm01731; X64-NEXT:    movq %rdi, %mm11732; X64-NEXT:    pmulhw %mm0, %mm11733; X64-NEXT:    movq %mm1, %rax1734; X64-NEXT:    retq1735entry:1736  %0 = bitcast <1 x i64> %b to <4 x i16>1737  %1 = bitcast <1 x i64> %a to <4 x i16>1738  %mmx_var.i = bitcast <4 x i16> %1 to <1 x i64>1739  %mmx_var1.i = bitcast <4 x i16> %0 to <1 x i64>1740  %2 = tail call <1 x i64> @llvm.x86.mmx.pmulh.w(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind1741  %3 = bitcast <1 x i64> %2 to <4 x i16>1742  %4 = bitcast <4 x i16> %3 to <1 x i64>1743  %5 = extractelement <1 x i64> %4, i32 01744  ret i64 %51745}1746 1747declare <1 x i64> @llvm.x86.mmx.pmadd.wd(<1 x i64>, <1 x i64>) nounwind readnone1748 1749define i64 @test49(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {1750; X86-LABEL: test49:1751; X86:       # %bb.0: # %entry1752; X86-NEXT:    pushl %ebp1753; X86-NEXT:    movl %esp, %ebp1754; X86-NEXT:    andl $-8, %esp1755; X86-NEXT:    subl $24, %esp1756; X86-NEXT:    movl 8(%ebp), %eax1757; X86-NEXT:    movl 12(%ebp), %ecx1758; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)1759; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)1760; X86-NEXT:    movl 16(%ebp), %eax1761; X86-NEXT:    movl 20(%ebp), %ecx1762; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)1763; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)1764; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm01765; X86-NEXT:    pmaddwd {{[0-9]+}}(%esp), %mm01766; X86-NEXT:    movq %mm0, (%esp)1767; X86-NEXT:    movl (%esp), %eax1768; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx1769; X86-NEXT:    movl %ebp, %esp1770; X86-NEXT:    popl %ebp1771; X86-NEXT:    retl1772;1773; X64-LABEL: test49:1774; X64:       # %bb.0: # %entry1775; X64-NEXT:    movq %rsi, %mm01776; X64-NEXT:    movq %rdi, %mm11777; X64-NEXT:    pmaddwd %mm0, %mm11778; X64-NEXT:    movq %mm1, %rax1779; X64-NEXT:    retq1780entry:1781  %0 = bitcast <1 x i64> %b to <4 x i16>1782  %1 = bitcast <1 x i64> %a to <4 x i16>1783  %mmx_var.i = bitcast <4 x i16> %1 to <1 x i64>1784  %mmx_var1.i = bitcast <4 x i16> %0 to <1 x i64>1785  %2 = tail call <1 x i64> @llvm.x86.mmx.pmadd.wd(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind1786  %3 = bitcast <1 x i64> %2 to <2 x i32>1787  %4 = bitcast <2 x i32> %3 to <1 x i64>1788  %5 = extractelement <1 x i64> %4, i32 01789  ret i64 %51790}1791 1792declare <1 x i64> @llvm.x86.mmx.psubus.w(<1 x i64>, <1 x i64>) nounwind readnone1793 1794define i64 @test48(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {1795; X86-LABEL: test48:1796; X86:       # %bb.0: # %entry1797; X86-NEXT:    pushl %ebp1798; X86-NEXT:    movl %esp, %ebp1799; X86-NEXT:    andl $-8, %esp1800; X86-NEXT:    subl $24, %esp1801; X86-NEXT:    movl 8(%ebp), %eax1802; X86-NEXT:    movl 12(%ebp), %ecx1803; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)1804; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)1805; X86-NEXT:    movl 16(%ebp), %eax1806; X86-NEXT:    movl 20(%ebp), %ecx1807; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)1808; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)1809; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm01810; X86-NEXT:    psubusw {{[0-9]+}}(%esp), %mm01811; X86-NEXT:    movq %mm0, (%esp)1812; X86-NEXT:    movl (%esp), %eax1813; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx1814; X86-NEXT:    movl %ebp, %esp1815; X86-NEXT:    popl %ebp1816; X86-NEXT:    retl1817;1818; X64-LABEL: test48:1819; X64:       # %bb.0: # %entry1820; X64-NEXT:    movq %rsi, %mm01821; X64-NEXT:    movq %rdi, %mm11822; X64-NEXT:    psubusw %mm0, %mm11823; X64-NEXT:    movq %mm1, %rax1824; X64-NEXT:    retq1825entry:1826  %0 = bitcast <1 x i64> %b to <4 x i16>1827  %1 = bitcast <1 x i64> %a to <4 x i16>1828  %mmx_var.i = bitcast <4 x i16> %1 to <1 x i64>1829  %mmx_var1.i = bitcast <4 x i16> %0 to <1 x i64>1830  %2 = tail call <1 x i64> @llvm.x86.mmx.psubus.w(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind1831  %3 = bitcast <1 x i64> %2 to <4 x i16>1832  %4 = bitcast <4 x i16> %3 to <1 x i64>1833  %5 = extractelement <1 x i64> %4, i32 01834  ret i64 %51835}1836 1837declare <1 x i64> @llvm.x86.mmx.psubus.b(<1 x i64>, <1 x i64>) nounwind readnone1838 1839define i64 @test47(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {1840; X86-LABEL: test47:1841; X86:       # %bb.0: # %entry1842; X86-NEXT:    pushl %ebp1843; X86-NEXT:    movl %esp, %ebp1844; X86-NEXT:    andl $-8, %esp1845; X86-NEXT:    subl $24, %esp1846; X86-NEXT:    movl 8(%ebp), %eax1847; X86-NEXT:    movl 12(%ebp), %ecx1848; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)1849; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)1850; X86-NEXT:    movl 16(%ebp), %eax1851; X86-NEXT:    movl 20(%ebp), %ecx1852; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)1853; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)1854; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm01855; X86-NEXT:    psubusb {{[0-9]+}}(%esp), %mm01856; X86-NEXT:    movq %mm0, (%esp)1857; X86-NEXT:    movl (%esp), %eax1858; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx1859; X86-NEXT:    movl %ebp, %esp1860; X86-NEXT:    popl %ebp1861; X86-NEXT:    retl1862;1863; X64-LABEL: test47:1864; X64:       # %bb.0: # %entry1865; X64-NEXT:    movq %rsi, %mm01866; X64-NEXT:    movq %rdi, %mm11867; X64-NEXT:    psubusb %mm0, %mm11868; X64-NEXT:    movq %mm1, %rax1869; X64-NEXT:    retq1870entry:1871  %0 = bitcast <1 x i64> %b to <8 x i8>1872  %1 = bitcast <1 x i64> %a to <8 x i8>1873  %mmx_var.i = bitcast <8 x i8> %1 to <1 x i64>1874  %mmx_var1.i = bitcast <8 x i8> %0 to <1 x i64>1875  %2 = tail call <1 x i64> @llvm.x86.mmx.psubus.b(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind1876  %3 = bitcast <1 x i64> %2 to <8 x i8>1877  %4 = bitcast <8 x i8> %3 to <1 x i64>1878  %5 = extractelement <1 x i64> %4, i32 01879  ret i64 %51880}1881 1882declare <1 x i64> @llvm.x86.mmx.psubs.w(<1 x i64>, <1 x i64>) nounwind readnone1883 1884define i64 @test46(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {1885; X86-LABEL: test46:1886; X86:       # %bb.0: # %entry1887; X86-NEXT:    pushl %ebp1888; X86-NEXT:    movl %esp, %ebp1889; X86-NEXT:    andl $-8, %esp1890; X86-NEXT:    subl $24, %esp1891; X86-NEXT:    movl 8(%ebp), %eax1892; X86-NEXT:    movl 12(%ebp), %ecx1893; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)1894; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)1895; X86-NEXT:    movl 16(%ebp), %eax1896; X86-NEXT:    movl 20(%ebp), %ecx1897; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)1898; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)1899; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm01900; X86-NEXT:    psubsw {{[0-9]+}}(%esp), %mm01901; X86-NEXT:    movq %mm0, (%esp)1902; X86-NEXT:    movl (%esp), %eax1903; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx1904; X86-NEXT:    movl %ebp, %esp1905; X86-NEXT:    popl %ebp1906; X86-NEXT:    retl1907;1908; X64-LABEL: test46:1909; X64:       # %bb.0: # %entry1910; X64-NEXT:    movq %rsi, %mm01911; X64-NEXT:    movq %rdi, %mm11912; X64-NEXT:    psubsw %mm0, %mm11913; X64-NEXT:    movq %mm1, %rax1914; X64-NEXT:    retq1915entry:1916  %0 = bitcast <1 x i64> %b to <4 x i16>1917  %1 = bitcast <1 x i64> %a to <4 x i16>1918  %mmx_var.i = bitcast <4 x i16> %1 to <1 x i64>1919  %mmx_var1.i = bitcast <4 x i16> %0 to <1 x i64>1920  %2 = tail call <1 x i64> @llvm.x86.mmx.psubs.w(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind1921  %3 = bitcast <1 x i64> %2 to <4 x i16>1922  %4 = bitcast <4 x i16> %3 to <1 x i64>1923  %5 = extractelement <1 x i64> %4, i32 01924  ret i64 %51925}1926 1927declare <1 x i64> @llvm.x86.mmx.psubs.b(<1 x i64>, <1 x i64>) nounwind readnone1928 1929define i64 @test45(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {1930; X86-LABEL: test45:1931; X86:       # %bb.0: # %entry1932; X86-NEXT:    pushl %ebp1933; X86-NEXT:    movl %esp, %ebp1934; X86-NEXT:    andl $-8, %esp1935; X86-NEXT:    subl $24, %esp1936; X86-NEXT:    movl 8(%ebp), %eax1937; X86-NEXT:    movl 12(%ebp), %ecx1938; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)1939; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)1940; X86-NEXT:    movl 16(%ebp), %eax1941; X86-NEXT:    movl 20(%ebp), %ecx1942; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)1943; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)1944; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm01945; X86-NEXT:    psubsb {{[0-9]+}}(%esp), %mm01946; X86-NEXT:    movq %mm0, (%esp)1947; X86-NEXT:    movl (%esp), %eax1948; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx1949; X86-NEXT:    movl %ebp, %esp1950; X86-NEXT:    popl %ebp1951; X86-NEXT:    retl1952;1953; X64-LABEL: test45:1954; X64:       # %bb.0: # %entry1955; X64-NEXT:    movq %rsi, %mm01956; X64-NEXT:    movq %rdi, %mm11957; X64-NEXT:    psubsb %mm0, %mm11958; X64-NEXT:    movq %mm1, %rax1959; X64-NEXT:    retq1960entry:1961  %0 = bitcast <1 x i64> %b to <8 x i8>1962  %1 = bitcast <1 x i64> %a to <8 x i8>1963  %mmx_var.i = bitcast <8 x i8> %1 to <1 x i64>1964  %mmx_var1.i = bitcast <8 x i8> %0 to <1 x i64>1965  %2 = tail call <1 x i64> @llvm.x86.mmx.psubs.b(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind1966  %3 = bitcast <1 x i64> %2 to <8 x i8>1967  %4 = bitcast <8 x i8> %3 to <1 x i64>1968  %5 = extractelement <1 x i64> %4, i32 01969  ret i64 %51970}1971 1972define i64 @test44(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {1973; X86-LABEL: test44:1974; X86:       # %bb.0: # %entry1975; X86-NEXT:    pushl %ebp1976; X86-NEXT:    movl %esp, %ebp1977; X86-NEXT:    andl $-8, %esp1978; X86-NEXT:    subl $8, %esp1979; X86-NEXT:    movq 8(%ebp), %mm01980; X86-NEXT:    psubq 16(%ebp), %mm01981; X86-NEXT:    movq %mm0, (%esp)1982; X86-NEXT:    movl (%esp), %eax1983; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx1984; X86-NEXT:    movl %ebp, %esp1985; X86-NEXT:    popl %ebp1986; X86-NEXT:    retl1987;1988; X64-LABEL: test44:1989; X64:       # %bb.0: # %entry1990; X64-NEXT:    movq %rdi, %mm01991; X64-NEXT:    movq %rsi, %mm11992; X64-NEXT:    psubq %mm1, %mm01993; X64-NEXT:    movq %mm0, %rax1994; X64-NEXT:    retq1995entry:1996  %0 = extractelement <1 x i64> %a, i32 01997  %mmx_var = bitcast i64 %0 to <1 x i64>1998  %1 = extractelement <1 x i64> %b, i32 01999  %mmx_var1 = bitcast i64 %1 to <1 x i64>2000  %2 = tail call <1 x i64> @llvm.x86.mmx.psub.q(<1 x i64> %mmx_var, <1 x i64> %mmx_var1)2001  %3 = bitcast <1 x i64> %2 to i642002  ret i64 %32003}2004 2005declare <1 x i64> @llvm.x86.mmx.psub.q(<1 x i64>, <1 x i64>) nounwind readnone2006 2007declare <1 x i64> @llvm.x86.mmx.psub.d(<1 x i64>, <1 x i64>) nounwind readnone2008 2009define i64 @test43(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {2010; X86-LABEL: test43:2011; X86:       # %bb.0: # %entry2012; X86-NEXT:    pushl %ebp2013; X86-NEXT:    movl %esp, %ebp2014; X86-NEXT:    andl $-8, %esp2015; X86-NEXT:    subl $24, %esp2016; X86-NEXT:    movl 8(%ebp), %eax2017; X86-NEXT:    movl 12(%ebp), %ecx2018; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2019; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)2020; X86-NEXT:    movl 16(%ebp), %eax2021; X86-NEXT:    movl 20(%ebp), %ecx2022; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2023; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)2024; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm02025; X86-NEXT:    psubd {{[0-9]+}}(%esp), %mm02026; X86-NEXT:    movq %mm0, (%esp)2027; X86-NEXT:    movl (%esp), %eax2028; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx2029; X86-NEXT:    movl %ebp, %esp2030; X86-NEXT:    popl %ebp2031; X86-NEXT:    retl2032;2033; X64-LABEL: test43:2034; X64:       # %bb.0: # %entry2035; X64-NEXT:    movq %rsi, %mm02036; X64-NEXT:    movq %rdi, %mm12037; X64-NEXT:    psubd %mm0, %mm12038; X64-NEXT:    movq %mm1, %rax2039; X64-NEXT:    retq2040entry:2041  %0 = bitcast <1 x i64> %b to <2 x i32>2042  %1 = bitcast <1 x i64> %a to <2 x i32>2043  %mmx_var.i = bitcast <2 x i32> %1 to <1 x i64>2044  %mmx_var1.i = bitcast <2 x i32> %0 to <1 x i64>2045  %2 = tail call <1 x i64> @llvm.x86.mmx.psub.d(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind2046  %3 = bitcast <1 x i64> %2 to <2 x i32>2047  %4 = bitcast <2 x i32> %3 to <1 x i64>2048  %5 = extractelement <1 x i64> %4, i32 02049  ret i64 %52050}2051 2052declare <1 x i64> @llvm.x86.mmx.psub.w(<1 x i64>, <1 x i64>) nounwind readnone2053 2054define i64 @test42(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {2055; X86-LABEL: test42:2056; X86:       # %bb.0: # %entry2057; X86-NEXT:    pushl %ebp2058; X86-NEXT:    movl %esp, %ebp2059; X86-NEXT:    andl $-8, %esp2060; X86-NEXT:    subl $24, %esp2061; X86-NEXT:    movl 8(%ebp), %eax2062; X86-NEXT:    movl 12(%ebp), %ecx2063; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2064; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)2065; X86-NEXT:    movl 16(%ebp), %eax2066; X86-NEXT:    movl 20(%ebp), %ecx2067; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2068; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)2069; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm02070; X86-NEXT:    psubw {{[0-9]+}}(%esp), %mm02071; X86-NEXT:    movq %mm0, (%esp)2072; X86-NEXT:    movl (%esp), %eax2073; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx2074; X86-NEXT:    movl %ebp, %esp2075; X86-NEXT:    popl %ebp2076; X86-NEXT:    retl2077;2078; X64-LABEL: test42:2079; X64:       # %bb.0: # %entry2080; X64-NEXT:    movq %rsi, %mm02081; X64-NEXT:    movq %rdi, %mm12082; X64-NEXT:    psubw %mm0, %mm12083; X64-NEXT:    movq %mm1, %rax2084; X64-NEXT:    retq2085entry:2086  %0 = bitcast <1 x i64> %b to <4 x i16>2087  %1 = bitcast <1 x i64> %a to <4 x i16>2088  %mmx_var.i = bitcast <4 x i16> %1 to <1 x i64>2089  %mmx_var1.i = bitcast <4 x i16> %0 to <1 x i64>2090  %2 = tail call <1 x i64> @llvm.x86.mmx.psub.w(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind2091  %3 = bitcast <1 x i64> %2 to <4 x i16>2092  %4 = bitcast <4 x i16> %3 to <1 x i64>2093  %5 = extractelement <1 x i64> %4, i32 02094  ret i64 %52095}2096 2097declare <1 x i64> @llvm.x86.mmx.psub.b(<1 x i64>, <1 x i64>) nounwind readnone2098 2099define i64 @test41(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {2100; X86-LABEL: test41:2101; X86:       # %bb.0: # %entry2102; X86-NEXT:    pushl %ebp2103; X86-NEXT:    movl %esp, %ebp2104; X86-NEXT:    andl $-8, %esp2105; X86-NEXT:    subl $24, %esp2106; X86-NEXT:    movl 8(%ebp), %eax2107; X86-NEXT:    movl 12(%ebp), %ecx2108; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2109; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)2110; X86-NEXT:    movl 16(%ebp), %eax2111; X86-NEXT:    movl 20(%ebp), %ecx2112; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2113; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)2114; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm02115; X86-NEXT:    psubb {{[0-9]+}}(%esp), %mm02116; X86-NEXT:    movq %mm0, (%esp)2117; X86-NEXT:    movl (%esp), %eax2118; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx2119; X86-NEXT:    movl %ebp, %esp2120; X86-NEXT:    popl %ebp2121; X86-NEXT:    retl2122;2123; X64-LABEL: test41:2124; X64:       # %bb.0: # %entry2125; X64-NEXT:    movq %rsi, %mm02126; X64-NEXT:    movq %rdi, %mm12127; X64-NEXT:    psubb %mm0, %mm12128; X64-NEXT:    movq %mm1, %rax2129; X64-NEXT:    retq2130entry:2131  %0 = bitcast <1 x i64> %b to <8 x i8>2132  %1 = bitcast <1 x i64> %a to <8 x i8>2133  %mmx_var.i = bitcast <8 x i8> %1 to <1 x i64>2134  %mmx_var1.i = bitcast <8 x i8> %0 to <1 x i64>2135  %2 = tail call <1 x i64> @llvm.x86.mmx.psub.b(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind2136  %3 = bitcast <1 x i64> %2 to <8 x i8>2137  %4 = bitcast <8 x i8> %3 to <1 x i64>2138  %5 = extractelement <1 x i64> %4, i32 02139  ret i64 %52140}2141 2142declare <1 x i64> @llvm.x86.mmx.paddus.w(<1 x i64>, <1 x i64>) nounwind readnone2143 2144define i64 @test40(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {2145; X86-LABEL: test40:2146; X86:       # %bb.0: # %entry2147; X86-NEXT:    pushl %ebp2148; X86-NEXT:    movl %esp, %ebp2149; X86-NEXT:    andl $-8, %esp2150; X86-NEXT:    subl $24, %esp2151; X86-NEXT:    movl 8(%ebp), %eax2152; X86-NEXT:    movl 12(%ebp), %ecx2153; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2154; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)2155; X86-NEXT:    movl 16(%ebp), %eax2156; X86-NEXT:    movl 20(%ebp), %ecx2157; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2158; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)2159; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm02160; X86-NEXT:    paddusw {{[0-9]+}}(%esp), %mm02161; X86-NEXT:    movq %mm0, (%esp)2162; X86-NEXT:    movl (%esp), %eax2163; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx2164; X86-NEXT:    movl %ebp, %esp2165; X86-NEXT:    popl %ebp2166; X86-NEXT:    retl2167;2168; X64-LABEL: test40:2169; X64:       # %bb.0: # %entry2170; X64-NEXT:    movq %rsi, %mm02171; X64-NEXT:    movq %rdi, %mm12172; X64-NEXT:    paddusw %mm0, %mm12173; X64-NEXT:    movq %mm1, %rax2174; X64-NEXT:    retq2175entry:2176  %0 = bitcast <1 x i64> %b to <4 x i16>2177  %1 = bitcast <1 x i64> %a to <4 x i16>2178  %mmx_var.i = bitcast <4 x i16> %1 to <1 x i64>2179  %mmx_var1.i = bitcast <4 x i16> %0 to <1 x i64>2180  %2 = tail call <1 x i64> @llvm.x86.mmx.paddus.w(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind2181  %3 = bitcast <1 x i64> %2 to <4 x i16>2182  %4 = bitcast <4 x i16> %3 to <1 x i64>2183  %5 = extractelement <1 x i64> %4, i32 02184  ret i64 %52185}2186 2187declare <1 x i64> @llvm.x86.mmx.paddus.b(<1 x i64>, <1 x i64>) nounwind readnone2188 2189define i64 @test39(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {2190; X86-LABEL: test39:2191; X86:       # %bb.0: # %entry2192; X86-NEXT:    pushl %ebp2193; X86-NEXT:    movl %esp, %ebp2194; X86-NEXT:    andl $-8, %esp2195; X86-NEXT:    subl $24, %esp2196; X86-NEXT:    movl 8(%ebp), %eax2197; X86-NEXT:    movl 12(%ebp), %ecx2198; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2199; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)2200; X86-NEXT:    movl 16(%ebp), %eax2201; X86-NEXT:    movl 20(%ebp), %ecx2202; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2203; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)2204; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm02205; X86-NEXT:    paddusb {{[0-9]+}}(%esp), %mm02206; X86-NEXT:    movq %mm0, (%esp)2207; X86-NEXT:    movl (%esp), %eax2208; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx2209; X86-NEXT:    movl %ebp, %esp2210; X86-NEXT:    popl %ebp2211; X86-NEXT:    retl2212;2213; X64-LABEL: test39:2214; X64:       # %bb.0: # %entry2215; X64-NEXT:    movq %rsi, %mm02216; X64-NEXT:    movq %rdi, %mm12217; X64-NEXT:    paddusb %mm0, %mm12218; X64-NEXT:    movq %mm1, %rax2219; X64-NEXT:    retq2220entry:2221  %0 = bitcast <1 x i64> %b to <8 x i8>2222  %1 = bitcast <1 x i64> %a to <8 x i8>2223  %mmx_var.i = bitcast <8 x i8> %1 to <1 x i64>2224  %mmx_var1.i = bitcast <8 x i8> %0 to <1 x i64>2225  %2 = tail call <1 x i64> @llvm.x86.mmx.paddus.b(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind2226  %3 = bitcast <1 x i64> %2 to <8 x i8>2227  %4 = bitcast <8 x i8> %3 to <1 x i64>2228  %5 = extractelement <1 x i64> %4, i32 02229  ret i64 %52230}2231 2232declare <1 x i64> @llvm.x86.mmx.padds.w(<1 x i64>, <1 x i64>) nounwind readnone2233 2234define i64 @test38(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {2235; X86-LABEL: test38:2236; X86:       # %bb.0: # %entry2237; X86-NEXT:    pushl %ebp2238; X86-NEXT:    movl %esp, %ebp2239; X86-NEXT:    andl $-8, %esp2240; X86-NEXT:    subl $24, %esp2241; X86-NEXT:    movl 8(%ebp), %eax2242; X86-NEXT:    movl 12(%ebp), %ecx2243; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2244; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)2245; X86-NEXT:    movl 16(%ebp), %eax2246; X86-NEXT:    movl 20(%ebp), %ecx2247; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2248; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)2249; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm02250; X86-NEXT:    paddsw {{[0-9]+}}(%esp), %mm02251; X86-NEXT:    movq %mm0, (%esp)2252; X86-NEXT:    movl (%esp), %eax2253; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx2254; X86-NEXT:    movl %ebp, %esp2255; X86-NEXT:    popl %ebp2256; X86-NEXT:    retl2257;2258; X64-LABEL: test38:2259; X64:       # %bb.0: # %entry2260; X64-NEXT:    movq %rsi, %mm02261; X64-NEXT:    movq %rdi, %mm12262; X64-NEXT:    paddsw %mm0, %mm12263; X64-NEXT:    movq %mm1, %rax2264; X64-NEXT:    retq2265entry:2266  %0 = bitcast <1 x i64> %b to <4 x i16>2267  %1 = bitcast <1 x i64> %a to <4 x i16>2268  %mmx_var.i = bitcast <4 x i16> %1 to <1 x i64>2269  %mmx_var1.i = bitcast <4 x i16> %0 to <1 x i64>2270  %2 = tail call <1 x i64> @llvm.x86.mmx.padds.w(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind2271  %3 = bitcast <1 x i64> %2 to <4 x i16>2272  %4 = bitcast <4 x i16> %3 to <1 x i64>2273  %5 = extractelement <1 x i64> %4, i32 02274  ret i64 %52275}2276 2277declare <1 x i64> @llvm.x86.mmx.padds.b(<1 x i64>, <1 x i64>) nounwind readnone2278 2279define i64 @test37(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {2280; X86-LABEL: test37:2281; X86:       # %bb.0: # %entry2282; X86-NEXT:    pushl %ebp2283; X86-NEXT:    movl %esp, %ebp2284; X86-NEXT:    andl $-8, %esp2285; X86-NEXT:    subl $24, %esp2286; X86-NEXT:    movl 8(%ebp), %eax2287; X86-NEXT:    movl 12(%ebp), %ecx2288; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2289; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)2290; X86-NEXT:    movl 16(%ebp), %eax2291; X86-NEXT:    movl 20(%ebp), %ecx2292; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2293; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)2294; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm02295; X86-NEXT:    paddsb {{[0-9]+}}(%esp), %mm02296; X86-NEXT:    movq %mm0, (%esp)2297; X86-NEXT:    movl (%esp), %eax2298; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx2299; X86-NEXT:    movl %ebp, %esp2300; X86-NEXT:    popl %ebp2301; X86-NEXT:    retl2302;2303; X64-LABEL: test37:2304; X64:       # %bb.0: # %entry2305; X64-NEXT:    movq %rsi, %mm02306; X64-NEXT:    movq %rdi, %mm12307; X64-NEXT:    paddsb %mm0, %mm12308; X64-NEXT:    movq %mm1, %rax2309; X64-NEXT:    retq2310entry:2311  %0 = bitcast <1 x i64> %b to <8 x i8>2312  %1 = bitcast <1 x i64> %a to <8 x i8>2313  %mmx_var.i = bitcast <8 x i8> %1 to <1 x i64>2314  %mmx_var1.i = bitcast <8 x i8> %0 to <1 x i64>2315  %2 = tail call <1 x i64> @llvm.x86.mmx.padds.b(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind2316  %3 = bitcast <1 x i64> %2 to <8 x i8>2317  %4 = bitcast <8 x i8> %3 to <1 x i64>2318  %5 = extractelement <1 x i64> %4, i32 02319  ret i64 %52320}2321 2322declare <1 x i64> @llvm.x86.mmx.padd.q(<1 x i64>, <1 x i64>) nounwind readnone2323 2324define i64 @test36(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {2325; X86-LABEL: test36:2326; X86:       # %bb.0: # %entry2327; X86-NEXT:    pushl %ebp2328; X86-NEXT:    movl %esp, %ebp2329; X86-NEXT:    andl $-8, %esp2330; X86-NEXT:    subl $8, %esp2331; X86-NEXT:    movq 8(%ebp), %mm02332; X86-NEXT:    paddq 16(%ebp), %mm02333; X86-NEXT:    movq %mm0, (%esp)2334; X86-NEXT:    movl (%esp), %eax2335; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx2336; X86-NEXT:    movl %ebp, %esp2337; X86-NEXT:    popl %ebp2338; X86-NEXT:    retl2339;2340; X64-LABEL: test36:2341; X64:       # %bb.0: # %entry2342; X64-NEXT:    movq %rdi, %mm02343; X64-NEXT:    movq %rsi, %mm12344; X64-NEXT:    paddq %mm0, %mm12345; X64-NEXT:    movq %mm1, %rax2346; X64-NEXT:    retq2347entry:2348  %0 = extractelement <1 x i64> %a, i32 02349  %mmx_var = bitcast i64 %0 to <1 x i64>2350  %1 = extractelement <1 x i64> %b, i32 02351  %mmx_var1 = bitcast i64 %1 to <1 x i64>2352  %2 = tail call <1 x i64> @llvm.x86.mmx.padd.q(<1 x i64> %mmx_var, <1 x i64> %mmx_var1)2353  %3 = bitcast <1 x i64> %2 to i642354  ret i64 %32355}2356 2357declare <1 x i64> @llvm.x86.mmx.padd.d(<1 x i64>, <1 x i64>) nounwind readnone2358 2359define i64 @test35(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {2360; X86-LABEL: test35:2361; X86:       # %bb.0: # %entry2362; X86-NEXT:    pushl %ebp2363; X86-NEXT:    movl %esp, %ebp2364; X86-NEXT:    andl $-8, %esp2365; X86-NEXT:    subl $24, %esp2366; X86-NEXT:    movl 8(%ebp), %eax2367; X86-NEXT:    movl 12(%ebp), %ecx2368; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2369; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)2370; X86-NEXT:    movl 16(%ebp), %eax2371; X86-NEXT:    movl 20(%ebp), %ecx2372; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2373; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)2374; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm02375; X86-NEXT:    paddd {{[0-9]+}}(%esp), %mm02376; X86-NEXT:    movq %mm0, (%esp)2377; X86-NEXT:    movl (%esp), %eax2378; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx2379; X86-NEXT:    movl %ebp, %esp2380; X86-NEXT:    popl %ebp2381; X86-NEXT:    retl2382;2383; X64-LABEL: test35:2384; X64:       # %bb.0: # %entry2385; X64-NEXT:    movq %rsi, %mm02386; X64-NEXT:    movq %rdi, %mm12387; X64-NEXT:    paddd %mm0, %mm12388; X64-NEXT:    movq %mm1, %rax2389; X64-NEXT:    retq2390entry:2391  %0 = bitcast <1 x i64> %b to <2 x i32>2392  %1 = bitcast <1 x i64> %a to <2 x i32>2393  %mmx_var.i = bitcast <2 x i32> %1 to <1 x i64>2394  %mmx_var1.i = bitcast <2 x i32> %0 to <1 x i64>2395  %2 = tail call <1 x i64> @llvm.x86.mmx.padd.d(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind2396  %3 = bitcast <1 x i64> %2 to <2 x i32>2397  %4 = bitcast <2 x i32> %3 to <1 x i64>2398  %5 = extractelement <1 x i64> %4, i32 02399  ret i64 %52400}2401 2402declare <1 x i64> @llvm.x86.mmx.padd.w(<1 x i64>, <1 x i64>) nounwind readnone2403 2404define i64 @test34(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {2405; X86-LABEL: test34:2406; X86:       # %bb.0: # %entry2407; X86-NEXT:    pushl %ebp2408; X86-NEXT:    movl %esp, %ebp2409; X86-NEXT:    andl $-8, %esp2410; X86-NEXT:    subl $24, %esp2411; X86-NEXT:    movl 8(%ebp), %eax2412; X86-NEXT:    movl 12(%ebp), %ecx2413; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2414; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)2415; X86-NEXT:    movl 16(%ebp), %eax2416; X86-NEXT:    movl 20(%ebp), %ecx2417; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2418; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)2419; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm02420; X86-NEXT:    paddw {{[0-9]+}}(%esp), %mm02421; X86-NEXT:    movq %mm0, (%esp)2422; X86-NEXT:    movl (%esp), %eax2423; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx2424; X86-NEXT:    movl %ebp, %esp2425; X86-NEXT:    popl %ebp2426; X86-NEXT:    retl2427;2428; X64-LABEL: test34:2429; X64:       # %bb.0: # %entry2430; X64-NEXT:    movq %rsi, %mm02431; X64-NEXT:    movq %rdi, %mm12432; X64-NEXT:    paddw %mm0, %mm12433; X64-NEXT:    movq %mm1, %rax2434; X64-NEXT:    retq2435entry:2436  %0 = bitcast <1 x i64> %b to <4 x i16>2437  %1 = bitcast <1 x i64> %a to <4 x i16>2438  %mmx_var.i = bitcast <4 x i16> %1 to <1 x i64>2439  %mmx_var1.i = bitcast <4 x i16> %0 to <1 x i64>2440  %2 = tail call <1 x i64> @llvm.x86.mmx.padd.w(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind2441  %3 = bitcast <1 x i64> %2 to <4 x i16>2442  %4 = bitcast <4 x i16> %3 to <1 x i64>2443  %5 = extractelement <1 x i64> %4, i32 02444  ret i64 %52445}2446 2447declare <1 x i64> @llvm.x86.mmx.padd.b(<1 x i64>, <1 x i64>) nounwind readnone2448 2449define i64 @test33(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {2450; X86-LABEL: test33:2451; X86:       # %bb.0: # %entry2452; X86-NEXT:    pushl %ebp2453; X86-NEXT:    movl %esp, %ebp2454; X86-NEXT:    andl $-8, %esp2455; X86-NEXT:    subl $24, %esp2456; X86-NEXT:    movl 8(%ebp), %eax2457; X86-NEXT:    movl 12(%ebp), %ecx2458; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2459; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)2460; X86-NEXT:    movl 16(%ebp), %eax2461; X86-NEXT:    movl 20(%ebp), %ecx2462; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2463; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)2464; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm02465; X86-NEXT:    paddb {{[0-9]+}}(%esp), %mm02466; X86-NEXT:    movq %mm0, (%esp)2467; X86-NEXT:    movl (%esp), %eax2468; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx2469; X86-NEXT:    movl %ebp, %esp2470; X86-NEXT:    popl %ebp2471; X86-NEXT:    retl2472;2473; X64-LABEL: test33:2474; X64:       # %bb.0: # %entry2475; X64-NEXT:    movq %rsi, %mm02476; X64-NEXT:    movq %rdi, %mm12477; X64-NEXT:    paddb %mm0, %mm12478; X64-NEXT:    movq %mm1, %rax2479; X64-NEXT:    retq2480entry:2481  %0 = bitcast <1 x i64> %b to <8 x i8>2482  %1 = bitcast <1 x i64> %a to <8 x i8>2483  %mmx_var.i = bitcast <8 x i8> %1 to <1 x i64>2484  %mmx_var1.i = bitcast <8 x i8> %0 to <1 x i64>2485  %2 = tail call <1 x i64> @llvm.x86.mmx.padd.b(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind2486  %3 = bitcast <1 x i64> %2 to <8 x i8>2487  %4 = bitcast <8 x i8> %3 to <1 x i64>2488  %5 = extractelement <1 x i64> %4, i32 02489  ret i64 %52490}2491 2492declare <1 x i64> @llvm.x86.mmx.psad.bw(<1 x i64>, <1 x i64>) nounwind readnone2493 2494define i64 @test32(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {2495; X86-LABEL: test32:2496; X86:       # %bb.0: # %entry2497; X86-NEXT:    pushl %ebp2498; X86-NEXT:    movl %esp, %ebp2499; X86-NEXT:    andl $-8, %esp2500; X86-NEXT:    subl $24, %esp2501; X86-NEXT:    movl 8(%ebp), %eax2502; X86-NEXT:    movl 12(%ebp), %ecx2503; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2504; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)2505; X86-NEXT:    movl 16(%ebp), %eax2506; X86-NEXT:    movl 20(%ebp), %ecx2507; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2508; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)2509; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm02510; X86-NEXT:    psadbw {{[0-9]+}}(%esp), %mm02511; X86-NEXT:    movq %mm0, (%esp)2512; X86-NEXT:    movl (%esp), %eax2513; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx2514; X86-NEXT:    movl %ebp, %esp2515; X86-NEXT:    popl %ebp2516; X86-NEXT:    retl2517;2518; X64-LABEL: test32:2519; X64:       # %bb.0: # %entry2520; X64-NEXT:    movq %rsi, %mm02521; X64-NEXT:    movq %rdi, %mm12522; X64-NEXT:    psadbw %mm0, %mm12523; X64-NEXT:    movq %mm1, %rax2524; X64-NEXT:    retq2525entry:2526  %0 = bitcast <1 x i64> %b to <8 x i8>2527  %1 = bitcast <1 x i64> %a to <8 x i8>2528  %mmx_var.i = bitcast <8 x i8> %1 to <1 x i64>2529  %mmx_var1.i = bitcast <8 x i8> %0 to <1 x i64>2530  %2 = tail call <1 x i64> @llvm.x86.mmx.psad.bw(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind2531  %3 = bitcast <1 x i64> %2 to i642532  ret i64 %32533}2534 2535declare <1 x i64> @llvm.x86.mmx.pmins.w(<1 x i64>, <1 x i64>) nounwind readnone2536 2537define i64 @test31(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {2538; X86-LABEL: test31:2539; X86:       # %bb.0: # %entry2540; X86-NEXT:    pushl %ebp2541; X86-NEXT:    movl %esp, %ebp2542; X86-NEXT:    andl $-8, %esp2543; X86-NEXT:    subl $24, %esp2544; X86-NEXT:    movl 8(%ebp), %eax2545; X86-NEXT:    movl 12(%ebp), %ecx2546; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2547; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)2548; X86-NEXT:    movl 16(%ebp), %eax2549; X86-NEXT:    movl 20(%ebp), %ecx2550; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2551; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)2552; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm02553; X86-NEXT:    pminsw {{[0-9]+}}(%esp), %mm02554; X86-NEXT:    movq %mm0, (%esp)2555; X86-NEXT:    movl (%esp), %eax2556; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx2557; X86-NEXT:    movl %ebp, %esp2558; X86-NEXT:    popl %ebp2559; X86-NEXT:    retl2560;2561; X64-LABEL: test31:2562; X64:       # %bb.0: # %entry2563; X64-NEXT:    movq %rsi, %mm02564; X64-NEXT:    movq %rdi, %mm12565; X64-NEXT:    pminsw %mm0, %mm12566; X64-NEXT:    movq %mm1, %rax2567; X64-NEXT:    retq2568entry:2569  %0 = bitcast <1 x i64> %b to <4 x i16>2570  %1 = bitcast <1 x i64> %a to <4 x i16>2571  %mmx_var.i = bitcast <4 x i16> %1 to <1 x i64>2572  %mmx_var1.i = bitcast <4 x i16> %0 to <1 x i64>2573  %2 = tail call <1 x i64> @llvm.x86.mmx.pmins.w(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind2574  %3 = bitcast <1 x i64> %2 to <4 x i16>2575  %4 = bitcast <4 x i16> %3 to <1 x i64>2576  %5 = extractelement <1 x i64> %4, i32 02577  ret i64 %52578}2579 2580declare <1 x i64> @llvm.x86.mmx.pminu.b(<1 x i64>, <1 x i64>) nounwind readnone2581 2582define i64 @test30(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {2583; X86-LABEL: test30:2584; X86:       # %bb.0: # %entry2585; X86-NEXT:    pushl %ebp2586; X86-NEXT:    movl %esp, %ebp2587; X86-NEXT:    andl $-8, %esp2588; X86-NEXT:    subl $24, %esp2589; X86-NEXT:    movl 8(%ebp), %eax2590; X86-NEXT:    movl 12(%ebp), %ecx2591; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2592; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)2593; X86-NEXT:    movl 16(%ebp), %eax2594; X86-NEXT:    movl 20(%ebp), %ecx2595; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2596; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)2597; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm02598; X86-NEXT:    pminub {{[0-9]+}}(%esp), %mm02599; X86-NEXT:    movq %mm0, (%esp)2600; X86-NEXT:    movl (%esp), %eax2601; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx2602; X86-NEXT:    movl %ebp, %esp2603; X86-NEXT:    popl %ebp2604; X86-NEXT:    retl2605;2606; X64-LABEL: test30:2607; X64:       # %bb.0: # %entry2608; X64-NEXT:    movq %rsi, %mm02609; X64-NEXT:    movq %rdi, %mm12610; X64-NEXT:    pminub %mm0, %mm12611; X64-NEXT:    movq %mm1, %rax2612; X64-NEXT:    retq2613entry:2614  %0 = bitcast <1 x i64> %b to <8 x i8>2615  %1 = bitcast <1 x i64> %a to <8 x i8>2616  %mmx_var.i = bitcast <8 x i8> %1 to <1 x i64>2617  %mmx_var1.i = bitcast <8 x i8> %0 to <1 x i64>2618  %2 = tail call <1 x i64> @llvm.x86.mmx.pminu.b(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind2619  %3 = bitcast <1 x i64> %2 to <8 x i8>2620  %4 = bitcast <8 x i8> %3 to <1 x i64>2621  %5 = extractelement <1 x i64> %4, i32 02622  ret i64 %52623}2624 2625declare <1 x i64> @llvm.x86.mmx.pmaxs.w(<1 x i64>, <1 x i64>) nounwind readnone2626 2627define i64 @test29(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {2628; X86-LABEL: test29:2629; X86:       # %bb.0: # %entry2630; X86-NEXT:    pushl %ebp2631; X86-NEXT:    movl %esp, %ebp2632; X86-NEXT:    andl $-8, %esp2633; X86-NEXT:    subl $24, %esp2634; X86-NEXT:    movl 8(%ebp), %eax2635; X86-NEXT:    movl 12(%ebp), %ecx2636; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2637; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)2638; X86-NEXT:    movl 16(%ebp), %eax2639; X86-NEXT:    movl 20(%ebp), %ecx2640; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2641; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)2642; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm02643; X86-NEXT:    pmaxsw {{[0-9]+}}(%esp), %mm02644; X86-NEXT:    movq %mm0, (%esp)2645; X86-NEXT:    movl (%esp), %eax2646; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx2647; X86-NEXT:    movl %ebp, %esp2648; X86-NEXT:    popl %ebp2649; X86-NEXT:    retl2650;2651; X64-LABEL: test29:2652; X64:       # %bb.0: # %entry2653; X64-NEXT:    movq %rsi, %mm02654; X64-NEXT:    movq %rdi, %mm12655; X64-NEXT:    pmaxsw %mm0, %mm12656; X64-NEXT:    movq %mm1, %rax2657; X64-NEXT:    retq2658entry:2659  %0 = bitcast <1 x i64> %b to <4 x i16>2660  %1 = bitcast <1 x i64> %a to <4 x i16>2661  %mmx_var.i = bitcast <4 x i16> %1 to <1 x i64>2662  %mmx_var1.i = bitcast <4 x i16> %0 to <1 x i64>2663  %2 = tail call <1 x i64> @llvm.x86.mmx.pmaxs.w(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind2664  %3 = bitcast <1 x i64> %2 to <4 x i16>2665  %4 = bitcast <4 x i16> %3 to <1 x i64>2666  %5 = extractelement <1 x i64> %4, i32 02667  ret i64 %52668}2669 2670declare <1 x i64> @llvm.x86.mmx.pmaxu.b(<1 x i64>, <1 x i64>) nounwind readnone2671 2672define i64 @test28(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {2673; X86-LABEL: test28:2674; X86:       # %bb.0: # %entry2675; X86-NEXT:    pushl %ebp2676; X86-NEXT:    movl %esp, %ebp2677; X86-NEXT:    andl $-8, %esp2678; X86-NEXT:    subl $24, %esp2679; X86-NEXT:    movl 8(%ebp), %eax2680; X86-NEXT:    movl 12(%ebp), %ecx2681; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2682; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)2683; X86-NEXT:    movl 16(%ebp), %eax2684; X86-NEXT:    movl 20(%ebp), %ecx2685; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2686; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)2687; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm02688; X86-NEXT:    pmaxub {{[0-9]+}}(%esp), %mm02689; X86-NEXT:    movq %mm0, (%esp)2690; X86-NEXT:    movl (%esp), %eax2691; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx2692; X86-NEXT:    movl %ebp, %esp2693; X86-NEXT:    popl %ebp2694; X86-NEXT:    retl2695;2696; X64-LABEL: test28:2697; X64:       # %bb.0: # %entry2698; X64-NEXT:    movq %rsi, %mm02699; X64-NEXT:    movq %rdi, %mm12700; X64-NEXT:    pmaxub %mm0, %mm12701; X64-NEXT:    movq %mm1, %rax2702; X64-NEXT:    retq2703entry:2704  %0 = bitcast <1 x i64> %b to <8 x i8>2705  %1 = bitcast <1 x i64> %a to <8 x i8>2706  %mmx_var.i = bitcast <8 x i8> %1 to <1 x i64>2707  %mmx_var1.i = bitcast <8 x i8> %0 to <1 x i64>2708  %2 = tail call <1 x i64> @llvm.x86.mmx.pmaxu.b(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind2709  %3 = bitcast <1 x i64> %2 to <8 x i8>2710  %4 = bitcast <8 x i8> %3 to <1 x i64>2711  %5 = extractelement <1 x i64> %4, i32 02712  ret i64 %52713}2714 2715declare <1 x i64> @llvm.x86.mmx.pavg.w(<1 x i64>, <1 x i64>) nounwind readnone2716 2717define i64 @test27(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {2718; X86-LABEL: test27:2719; X86:       # %bb.0: # %entry2720; X86-NEXT:    pushl %ebp2721; X86-NEXT:    movl %esp, %ebp2722; X86-NEXT:    andl $-8, %esp2723; X86-NEXT:    subl $24, %esp2724; X86-NEXT:    movl 8(%ebp), %eax2725; X86-NEXT:    movl 12(%ebp), %ecx2726; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2727; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)2728; X86-NEXT:    movl 16(%ebp), %eax2729; X86-NEXT:    movl 20(%ebp), %ecx2730; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2731; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)2732; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm02733; X86-NEXT:    pavgw {{[0-9]+}}(%esp), %mm02734; X86-NEXT:    movq %mm0, (%esp)2735; X86-NEXT:    movl (%esp), %eax2736; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx2737; X86-NEXT:    movl %ebp, %esp2738; X86-NEXT:    popl %ebp2739; X86-NEXT:    retl2740;2741; X64-LABEL: test27:2742; X64:       # %bb.0: # %entry2743; X64-NEXT:    movq %rsi, %mm02744; X64-NEXT:    movq %rdi, %mm12745; X64-NEXT:    pavgw %mm0, %mm12746; X64-NEXT:    movq %mm1, %rax2747; X64-NEXT:    retq2748entry:2749  %0 = bitcast <1 x i64> %b to <4 x i16>2750  %1 = bitcast <1 x i64> %a to <4 x i16>2751  %mmx_var.i = bitcast <4 x i16> %1 to <1 x i64>2752  %mmx_var1.i = bitcast <4 x i16> %0 to <1 x i64>2753  %2 = tail call <1 x i64> @llvm.x86.mmx.pavg.w(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind2754  %3 = bitcast <1 x i64> %2 to <4 x i16>2755  %4 = bitcast <4 x i16> %3 to <1 x i64>2756  %5 = extractelement <1 x i64> %4, i32 02757  ret i64 %52758}2759 2760declare <1 x i64> @llvm.x86.mmx.pavg.b(<1 x i64>, <1 x i64>) nounwind readnone2761 2762define i64 @test26(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {2763; X86-LABEL: test26:2764; X86:       # %bb.0: # %entry2765; X86-NEXT:    pushl %ebp2766; X86-NEXT:    movl %esp, %ebp2767; X86-NEXT:    andl $-8, %esp2768; X86-NEXT:    subl $24, %esp2769; X86-NEXT:    movl 8(%ebp), %eax2770; X86-NEXT:    movl 12(%ebp), %ecx2771; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2772; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)2773; X86-NEXT:    movl 16(%ebp), %eax2774; X86-NEXT:    movl 20(%ebp), %ecx2775; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2776; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)2777; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm02778; X86-NEXT:    pavgb {{[0-9]+}}(%esp), %mm02779; X86-NEXT:    movq %mm0, (%esp)2780; X86-NEXT:    movl (%esp), %eax2781; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx2782; X86-NEXT:    movl %ebp, %esp2783; X86-NEXT:    popl %ebp2784; X86-NEXT:    retl2785;2786; X64-LABEL: test26:2787; X64:       # %bb.0: # %entry2788; X64-NEXT:    movq %rsi, %mm02789; X64-NEXT:    movq %rdi, %mm12790; X64-NEXT:    pavgb %mm0, %mm12791; X64-NEXT:    movq %mm1, %rax2792; X64-NEXT:    retq2793entry:2794  %0 = bitcast <1 x i64> %b to <8 x i8>2795  %1 = bitcast <1 x i64> %a to <8 x i8>2796  %mmx_var.i = bitcast <8 x i8> %1 to <1 x i64>2797  %mmx_var1.i = bitcast <8 x i8> %0 to <1 x i64>2798  %2 = tail call <1 x i64> @llvm.x86.mmx.pavg.b(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind2799  %3 = bitcast <1 x i64> %2 to <8 x i8>2800  %4 = bitcast <8 x i8> %3 to <1 x i64>2801  %5 = extractelement <1 x i64> %4, i32 02802  ret i64 %52803}2804 2805declare void @llvm.x86.mmx.movnt.dq(ptr, <1 x i64>) nounwind2806 2807define void @test25(ptr %p, <1 x i64> %a) nounwind optsize ssp {2808; X86-LABEL: test25:2809; X86:       # %bb.0: # %entry2810; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm02811; X86-NEXT:    movl {{[0-9]+}}(%esp), %eax2812; X86-NEXT:    movntq %mm0, (%eax)2813; X86-NEXT:    retl2814;2815; X64-LABEL: test25:2816; X64:       # %bb.0: # %entry2817; X64-NEXT:    movq %rsi, %mm02818; X64-NEXT:    movntq %mm0, (%rdi)2819; X64-NEXT:    retq2820entry:2821  %0 = extractelement <1 x i64> %a, i32 02822  %mmx_var.i = bitcast i64 %0 to <1 x i64>2823  tail call void @llvm.x86.mmx.movnt.dq(ptr %p, <1 x i64> %mmx_var.i) nounwind2824  ret void2825}2826 2827declare i32 @llvm.x86.mmx.pmovmskb(<1 x i64>) nounwind readnone2828 2829define i32 @test24(<1 x i64> %a) nounwind readnone optsize ssp {2830; X86-LABEL: test24:2831; X86:       # %bb.0: # %entry2832; X86-NEXT:    pushl %ebp2833; X86-NEXT:    movl %esp, %ebp2834; X86-NEXT:    andl $-8, %esp2835; X86-NEXT:    subl $8, %esp2836; X86-NEXT:    movl 8(%ebp), %eax2837; X86-NEXT:    movl 12(%ebp), %ecx2838; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2839; X86-NEXT:    movl %eax, (%esp)2840; X86-NEXT:    movq (%esp), %mm02841; X86-NEXT:    pmovmskb %mm0, %eax2842; X86-NEXT:    movl %ebp, %esp2843; X86-NEXT:    popl %ebp2844; X86-NEXT:    retl2845;2846; X64-LABEL: test24:2847; X64:       # %bb.0: # %entry2848; X64-NEXT:    movq %rdi, %mm02849; X64-NEXT:    pmovmskb %mm0, %eax2850; X64-NEXT:    retq2851entry:2852  %0 = bitcast <1 x i64> %a to <8 x i8>2853  %mmx_var.i = bitcast <8 x i8> %0 to <1 x i64>2854  %1 = tail call i32 @llvm.x86.mmx.pmovmskb(<1 x i64> %mmx_var.i) nounwind2855  ret i32 %12856}2857 2858declare void @llvm.x86.mmx.maskmovq(<1 x i64>, <1 x i64>, ptr) nounwind2859 2860define void @test23(<1 x i64> %d, <1 x i64> %n, ptr %p) nounwind optsize ssp {2861; X86-LABEL: test23:2862; X86:       # %bb.0: # %entry2863; X86-NEXT:    pushl %ebp2864; X86-NEXT:    movl %esp, %ebp2865; X86-NEXT:    pushl %edi2866; X86-NEXT:    andl $-8, %esp2867; X86-NEXT:    subl $24, %esp2868; X86-NEXT:    movl 16(%ebp), %eax2869; X86-NEXT:    movl 20(%ebp), %ecx2870; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2871; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)2872; X86-NEXT:    movl 8(%ebp), %eax2873; X86-NEXT:    movl 12(%ebp), %ecx2874; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2875; X86-NEXT:    movl %eax, (%esp)2876; X86-NEXT:    movl 24(%ebp), %edi2877; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm02878; X86-NEXT:    movq (%esp), %mm12879; X86-NEXT:    maskmovq %mm0, %mm12880; X86-NEXT:    leal -4(%ebp), %esp2881; X86-NEXT:    popl %edi2882; X86-NEXT:    popl %ebp2883; X86-NEXT:    retl2884;2885; X64-LABEL: test23:2886; X64:       # %bb.0: # %entry2887; X64-NEXT:    movq %rsi, %mm02888; X64-NEXT:    movq %rdi, %mm12889; X64-NEXT:    movq %rdx, %rdi2890; X64-NEXT:    maskmovq %mm0, %mm12891; X64-NEXT:    retq2892entry:2893  %0 = bitcast <1 x i64> %n to <8 x i8>2894  %1 = bitcast <1 x i64> %d to <8 x i8>2895  %mmx_var.i = bitcast <8 x i8> %1 to <1 x i64>2896  %mmx_var1.i = bitcast <8 x i8> %0 to <1 x i64>2897  tail call void @llvm.x86.mmx.maskmovq(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i, ptr %p) nounwind2898  ret void2899}2900 2901declare <1 x i64> @llvm.x86.mmx.pmulhu.w(<1 x i64>, <1 x i64>) nounwind readnone2902 2903define i64 @test22(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {2904; X86-LABEL: test22:2905; X86:       # %bb.0: # %entry2906; X86-NEXT:    pushl %ebp2907; X86-NEXT:    movl %esp, %ebp2908; X86-NEXT:    andl $-8, %esp2909; X86-NEXT:    subl $24, %esp2910; X86-NEXT:    movl 8(%ebp), %eax2911; X86-NEXT:    movl 12(%ebp), %ecx2912; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2913; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)2914; X86-NEXT:    movl 16(%ebp), %eax2915; X86-NEXT:    movl 20(%ebp), %ecx2916; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2917; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)2918; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm02919; X86-NEXT:    pmulhuw {{[0-9]+}}(%esp), %mm02920; X86-NEXT:    movq %mm0, (%esp)2921; X86-NEXT:    movl (%esp), %eax2922; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx2923; X86-NEXT:    movl %ebp, %esp2924; X86-NEXT:    popl %ebp2925; X86-NEXT:    retl2926;2927; X64-LABEL: test22:2928; X64:       # %bb.0: # %entry2929; X64-NEXT:    movq %rsi, %mm02930; X64-NEXT:    movq %rdi, %mm12931; X64-NEXT:    pmulhuw %mm0, %mm12932; X64-NEXT:    movq %mm1, %rax2933; X64-NEXT:    retq2934entry:2935  %0 = bitcast <1 x i64> %b to <4 x i16>2936  %1 = bitcast <1 x i64> %a to <4 x i16>2937  %mmx_var.i = bitcast <4 x i16> %1 to <1 x i64>2938  %mmx_var1.i = bitcast <4 x i16> %0 to <1 x i64>2939  %2 = tail call <1 x i64> @llvm.x86.mmx.pmulhu.w(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind2940  %3 = bitcast <1 x i64> %2 to <4 x i16>2941  %4 = bitcast <4 x i16> %3 to <1 x i64>2942  %5 = extractelement <1 x i64> %4, i32 02943  ret i64 %52944}2945 2946declare <1 x i64> @llvm.x86.sse.pshuf.w(<1 x i64>, i8) nounwind readnone2947 2948define i64 @test21(<1 x i64> %a) nounwind readnone optsize ssp {2949; X86-LABEL: test21:2950; X86:       # %bb.0: # %entry2951; X86-NEXT:    pushl %ebp2952; X86-NEXT:    movl %esp, %ebp2953; X86-NEXT:    andl $-8, %esp2954; X86-NEXT:    subl $16, %esp2955; X86-NEXT:    movl 8(%ebp), %eax2956; X86-NEXT:    movl 12(%ebp), %ecx2957; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2958; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)2959; X86-NEXT:    pshufw $3, {{[0-9]+}}(%esp), %mm0 # mm0 = mem[3,0,0,0]2960; X86-NEXT:    movq %mm0, (%esp)2961; X86-NEXT:    movl (%esp), %eax2962; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx2963; X86-NEXT:    movl %ebp, %esp2964; X86-NEXT:    popl %ebp2965; X86-NEXT:    retl2966;2967; X64-LABEL: test21:2968; X64:       # %bb.0: # %entry2969; X64-NEXT:    movq %rdi, %mm02970; X64-NEXT:    pshufw $3, %mm0, %mm0 # mm0 = mm0[3,0,0,0]2971; X64-NEXT:    movq %mm0, %rax2972; X64-NEXT:    retq2973entry:2974  %0 = bitcast <1 x i64> %a to <4 x i16>2975  %1 = bitcast <4 x i16> %0 to <1 x i64>2976  %2 = tail call <1 x i64> @llvm.x86.sse.pshuf.w(<1 x i64> %1, i8 3) nounwind readnone2977  %3 = bitcast <1 x i64> %2 to <4 x i16>2978  %4 = bitcast <4 x i16> %3 to <1 x i64>2979  %5 = extractelement <1 x i64> %4, i32 02980  ret i64 %52981}2982 2983define i32 @test21_2(<1 x i64> %a) nounwind readnone optsize ssp {2984; X86-LABEL: test21_2:2985; X86:       # %bb.0: # %entry2986; X86-NEXT:    pushl %ebp2987; X86-NEXT:    movl %esp, %ebp2988; X86-NEXT:    andl $-8, %esp2989; X86-NEXT:    subl $8, %esp2990; X86-NEXT:    movl 8(%ebp), %eax2991; X86-NEXT:    movl 12(%ebp), %ecx2992; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)2993; X86-NEXT:    movl %eax, (%esp)2994; X86-NEXT:    pshufw $3, (%esp), %mm0 # mm0 = mem[3,0,0,0]2995; X86-NEXT:    movd %mm0, %eax2996; X86-NEXT:    movl %ebp, %esp2997; X86-NEXT:    popl %ebp2998; X86-NEXT:    retl2999;3000; X64-LABEL: test21_2:3001; X64:       # %bb.0: # %entry3002; X64-NEXT:    movq %rdi, %mm03003; X64-NEXT:    pshufw $3, %mm0, %mm0 # mm0 = mm0[3,0,0,0]3004; X64-NEXT:    movd %mm0, %eax3005; X64-NEXT:    retq3006entry:3007  %0 = bitcast <1 x i64> %a to <4 x i16>3008  %1 = bitcast <4 x i16> %0 to <1 x i64>3009  %2 = tail call <1 x i64> @llvm.x86.sse.pshuf.w(<1 x i64> %1, i8 3) nounwind readnone3010  %3 = bitcast <1 x i64> %2 to <4 x i16>3011  %4 = bitcast <4 x i16> %3 to <2 x i32>3012  %5 = extractelement <2 x i32> %4, i32 03013  ret i32 %53014}3015 3016declare <1 x i64> @llvm.x86.mmx.pmulu.dq(<1 x i64>, <1 x i64>) nounwind readnone3017 3018define i64 @test20(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {3019; X86-LABEL: test20:3020; X86:       # %bb.0: # %entry3021; X86-NEXT:    pushl %ebp3022; X86-NEXT:    movl %esp, %ebp3023; X86-NEXT:    andl $-8, %esp3024; X86-NEXT:    subl $24, %esp3025; X86-NEXT:    movl 8(%ebp), %eax3026; X86-NEXT:    movl 12(%ebp), %ecx3027; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)3028; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)3029; X86-NEXT:    movl 16(%ebp), %eax3030; X86-NEXT:    movl 20(%ebp), %ecx3031; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)3032; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)3033; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm03034; X86-NEXT:    pmuludq {{[0-9]+}}(%esp), %mm03035; X86-NEXT:    movq %mm0, (%esp)3036; X86-NEXT:    movl (%esp), %eax3037; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx3038; X86-NEXT:    movl %ebp, %esp3039; X86-NEXT:    popl %ebp3040; X86-NEXT:    retl3041;3042; X64-LABEL: test20:3043; X64:       # %bb.0: # %entry3044; X64-NEXT:    movq %rsi, %mm03045; X64-NEXT:    movq %rdi, %mm13046; X64-NEXT:    pmuludq %mm0, %mm13047; X64-NEXT:    movq %mm1, %rax3048; X64-NEXT:    retq3049entry:3050  %0 = bitcast <1 x i64> %b to <2 x i32>3051  %1 = bitcast <1 x i64> %a to <2 x i32>3052  %mmx_var.i = bitcast <2 x i32> %1 to <1 x i64>3053  %mmx_var1.i = bitcast <2 x i32> %0 to <1 x i64>3054  %2 = tail call <1 x i64> @llvm.x86.mmx.pmulu.dq(<1 x i64> %mmx_var.i, <1 x i64> %mmx_var1.i) nounwind3055  %3 = bitcast <1 x i64> %2 to i643056  ret i64 %33057}3058 3059declare <2 x double> @llvm.x86.sse.cvtpi2pd(<1 x i64>) nounwind readnone3060 3061define <2 x double> @test19(<1 x i64> %a) nounwind readnone optsize ssp {3062; X86-LABEL: test19:3063; X86:       # %bb.0: # %entry3064; X86-NEXT:    pushl %ebp3065; X86-NEXT:    movl %esp, %ebp3066; X86-NEXT:    andl $-8, %esp3067; X86-NEXT:    subl $8, %esp3068; X86-NEXT:    movl 8(%ebp), %eax3069; X86-NEXT:    movl 12(%ebp), %ecx3070; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)3071; X86-NEXT:    movl %eax, (%esp)3072; X86-NEXT:    cvtpi2pd (%esp), %xmm03073; X86-NEXT:    movl %ebp, %esp3074; X86-NEXT:    popl %ebp3075; X86-NEXT:    retl3076;3077; X64-LABEL: test19:3078; X64:       # %bb.0: # %entry3079; X64-NEXT:    movq %rdi, %mm03080; X64-NEXT:    cvtpi2pd %mm0, %xmm03081; X64-NEXT:    retq3082entry:3083  %0 = bitcast <1 x i64> %a to <2 x i32>3084  %1 = bitcast <2 x i32> %0 to <1 x i64>3085  %2 = tail call <2 x double> @llvm.x86.sse.cvtpi2pd(<1 x i64> %1) nounwind readnone3086  ret <2 x double> %23087}3088 3089declare <1 x i64> @llvm.x86.sse.cvttpd2pi(<2 x double>) nounwind readnone3090 3091define i64 @test18(<2 x double> %a) nounwind readnone optsize ssp {3092; X86-LABEL: test18:3093; X86:       # %bb.0: # %entry3094; X86-NEXT:    pushl %ebp3095; X86-NEXT:    movl %esp, %ebp3096; X86-NEXT:    andl $-8, %esp3097; X86-NEXT:    subl $8, %esp3098; X86-NEXT:    cvttpd2pi %xmm0, %mm03099; X86-NEXT:    movq %mm0, (%esp)3100; X86-NEXT:    movl (%esp), %eax3101; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx3102; X86-NEXT:    movl %ebp, %esp3103; X86-NEXT:    popl %ebp3104; X86-NEXT:    retl3105;3106; X64-LABEL: test18:3107; X64:       # %bb.0: # %entry3108; X64-NEXT:    cvttpd2pi %xmm0, %mm03109; X64-NEXT:    movq %mm0, %rax3110; X64-NEXT:    retq3111entry:3112  %0 = tail call <1 x i64> @llvm.x86.sse.cvttpd2pi(<2 x double> %a) nounwind readnone3113  %1 = bitcast <1 x i64> %0 to <2 x i32>3114  %2 = bitcast <2 x i32> %1 to <1 x i64>3115  %3 = extractelement <1 x i64> %2, i32 03116  ret i64 %33117}3118 3119declare <1 x i64> @llvm.x86.sse.cvtpd2pi(<2 x double>) nounwind readnone3120 3121define i64 @test17(<2 x double> %a) nounwind readnone optsize ssp {3122; X86-LABEL: test17:3123; X86:       # %bb.0: # %entry3124; X86-NEXT:    pushl %ebp3125; X86-NEXT:    movl %esp, %ebp3126; X86-NEXT:    andl $-8, %esp3127; X86-NEXT:    subl $8, %esp3128; X86-NEXT:    cvtpd2pi %xmm0, %mm03129; X86-NEXT:    movq %mm0, (%esp)3130; X86-NEXT:    movl (%esp), %eax3131; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx3132; X86-NEXT:    movl %ebp, %esp3133; X86-NEXT:    popl %ebp3134; X86-NEXT:    retl3135;3136; X64-LABEL: test17:3137; X64:       # %bb.0: # %entry3138; X64-NEXT:    cvtpd2pi %xmm0, %mm03139; X64-NEXT:    movq %mm0, %rax3140; X64-NEXT:    retq3141entry:3142  %0 = tail call <1 x i64> @llvm.x86.sse.cvtpd2pi(<2 x double> %a) nounwind readnone3143  %1 = bitcast <1 x i64> %0 to <2 x i32>3144  %2 = bitcast <2 x i32> %1 to <1 x i64>3145  %3 = extractelement <1 x i64> %2, i32 03146  ret i64 %33147}3148 3149declare <1 x i64> @llvm.x86.mmx.palignr.b(<1 x i64>, <1 x i64>, i8) nounwind readnone3150 3151define i64 @test16(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {3152; X86-LABEL: test16:3153; X86:       # %bb.0: # %entry3154; X86-NEXT:    pushl %ebp3155; X86-NEXT:    movl %esp, %ebp3156; X86-NEXT:    andl $-8, %esp3157; X86-NEXT:    subl $8, %esp3158; X86-NEXT:    movq 8(%ebp), %mm03159; X86-NEXT:    palignr $16, 16(%ebp), %mm03160; X86-NEXT:    movq %mm0, (%esp)3161; X86-NEXT:    movl (%esp), %eax3162; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx3163; X86-NEXT:    movl %ebp, %esp3164; X86-NEXT:    popl %ebp3165; X86-NEXT:    retl3166;3167; X64-LABEL: test16:3168; X64:       # %bb.0: # %entry3169; X64-NEXT:    movq %rdi, %mm03170; X64-NEXT:    movq %rsi, %mm13171; X64-NEXT:    palignr $16, %mm1, %mm03172; X64-NEXT:    movq %mm0, %rax3173; X64-NEXT:    retq3174entry:3175  %0 = extractelement <1 x i64> %a, i32 03176  %mmx_var = bitcast i64 %0 to <1 x i64>3177  %1 = extractelement <1 x i64> %b, i32 03178  %mmx_var1 = bitcast i64 %1 to <1 x i64>3179  %2 = tail call <1 x i64> @llvm.x86.mmx.palignr.b(<1 x i64> %mmx_var, <1 x i64> %mmx_var1, i8 16)3180  %3 = bitcast <1 x i64> %2 to i643181  ret i64 %33182}3183 3184declare <1 x i64> @llvm.x86.ssse3.pabs.d(<1 x i64>) nounwind readnone3185 3186define i64 @test15(<1 x i64> %a) nounwind readnone optsize ssp {3187; X86-LABEL: test15:3188; X86:       # %bb.0: # %entry3189; X86-NEXT:    pushl %ebp3190; X86-NEXT:    movl %esp, %ebp3191; X86-NEXT:    andl $-8, %esp3192; X86-NEXT:    subl $16, %esp3193; X86-NEXT:    movl 8(%ebp), %eax3194; X86-NEXT:    movl 12(%ebp), %ecx3195; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)3196; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)3197; X86-NEXT:    pabsd {{[0-9]+}}(%esp), %mm03198; X86-NEXT:    movq %mm0, (%esp)3199; X86-NEXT:    movl (%esp), %eax3200; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx3201; X86-NEXT:    movl %ebp, %esp3202; X86-NEXT:    popl %ebp3203; X86-NEXT:    retl3204;3205; X64-LABEL: test15:3206; X64:       # %bb.0: # %entry3207; X64-NEXT:    movq %rdi, %mm03208; X64-NEXT:    pabsd %mm0, %mm03209; X64-NEXT:    movq %mm0, %rax3210; X64-NEXT:    retq3211entry:3212  %0 = bitcast <1 x i64> %a to <2 x i32>3213  %1 = bitcast <2 x i32> %0 to <1 x i64>3214  %2 = tail call <1 x i64> @llvm.x86.ssse3.pabs.d(<1 x i64> %1) nounwind readnone3215  %3 = bitcast <1 x i64> %2 to <2 x i32>3216  %4 = bitcast <2 x i32> %3 to <1 x i64>3217  %5 = extractelement <1 x i64> %4, i32 03218  ret i64 %53219}3220 3221declare <1 x i64> @llvm.x86.ssse3.pabs.w(<1 x i64>) nounwind readnone3222 3223define i64 @test14(<1 x i64> %a) nounwind readnone optsize ssp {3224; X86-LABEL: test14:3225; X86:       # %bb.0: # %entry3226; X86-NEXT:    pushl %ebp3227; X86-NEXT:    movl %esp, %ebp3228; X86-NEXT:    andl $-8, %esp3229; X86-NEXT:    subl $16, %esp3230; X86-NEXT:    movl 8(%ebp), %eax3231; X86-NEXT:    movl 12(%ebp), %ecx3232; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)3233; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)3234; X86-NEXT:    pabsw {{[0-9]+}}(%esp), %mm03235; X86-NEXT:    movq %mm0, (%esp)3236; X86-NEXT:    movl (%esp), %eax3237; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx3238; X86-NEXT:    movl %ebp, %esp3239; X86-NEXT:    popl %ebp3240; X86-NEXT:    retl3241;3242; X64-LABEL: test14:3243; X64:       # %bb.0: # %entry3244; X64-NEXT:    movq %rdi, %mm03245; X64-NEXT:    pabsw %mm0, %mm03246; X64-NEXT:    movq %mm0, %rax3247; X64-NEXT:    retq3248entry:3249  %0 = bitcast <1 x i64> %a to <4 x i16>3250  %1 = bitcast <4 x i16> %0 to <1 x i64>3251  %2 = tail call <1 x i64> @llvm.x86.ssse3.pabs.w(<1 x i64> %1) nounwind readnone3252  %3 = bitcast <1 x i64> %2 to <4 x i16>3253  %4 = bitcast <4 x i16> %3 to <1 x i64>3254  %5 = extractelement <1 x i64> %4, i32 03255  ret i64 %53256}3257 3258declare <1 x i64> @llvm.x86.ssse3.pabs.b(<1 x i64>) nounwind readnone3259 3260define i64 @test13(<1 x i64> %a) nounwind readnone optsize ssp {3261; X86-LABEL: test13:3262; X86:       # %bb.0: # %entry3263; X86-NEXT:    pushl %ebp3264; X86-NEXT:    movl %esp, %ebp3265; X86-NEXT:    andl $-8, %esp3266; X86-NEXT:    subl $16, %esp3267; X86-NEXT:    movl 8(%ebp), %eax3268; X86-NEXT:    movl 12(%ebp), %ecx3269; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)3270; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)3271; X86-NEXT:    pabsb {{[0-9]+}}(%esp), %mm03272; X86-NEXT:    movq %mm0, (%esp)3273; X86-NEXT:    movl (%esp), %eax3274; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx3275; X86-NEXT:    movl %ebp, %esp3276; X86-NEXT:    popl %ebp3277; X86-NEXT:    retl3278;3279; X64-LABEL: test13:3280; X64:       # %bb.0: # %entry3281; X64-NEXT:    movq %rdi, %mm03282; X64-NEXT:    pabsb %mm0, %mm03283; X64-NEXT:    movq %mm0, %rax3284; X64-NEXT:    retq3285entry:3286  %0 = bitcast <1 x i64> %a to <8 x i8>3287  %1 = bitcast <8 x i8> %0 to <1 x i64>3288  %2 = tail call <1 x i64> @llvm.x86.ssse3.pabs.b(<1 x i64> %1) nounwind readnone3289  %3 = bitcast <1 x i64> %2 to <8 x i8>3290  %4 = bitcast <8 x i8> %3 to <1 x i64>3291  %5 = extractelement <1 x i64> %4, i32 03292  ret i64 %53293}3294 3295declare <1 x i64> @llvm.x86.ssse3.psign.d(<1 x i64>, <1 x i64>) nounwind readnone3296 3297define i64 @test12(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {3298; X86-LABEL: test12:3299; X86:       # %bb.0: # %entry3300; X86-NEXT:    pushl %ebp3301; X86-NEXT:    movl %esp, %ebp3302; X86-NEXT:    andl $-8, %esp3303; X86-NEXT:    subl $24, %esp3304; X86-NEXT:    movl 8(%ebp), %eax3305; X86-NEXT:    movl 12(%ebp), %ecx3306; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)3307; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)3308; X86-NEXT:    movl 16(%ebp), %eax3309; X86-NEXT:    movl 20(%ebp), %ecx3310; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)3311; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)3312; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm03313; X86-NEXT:    psignd {{[0-9]+}}(%esp), %mm03314; X86-NEXT:    movq %mm0, (%esp)3315; X86-NEXT:    movl (%esp), %eax3316; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx3317; X86-NEXT:    movl %ebp, %esp3318; X86-NEXT:    popl %ebp3319; X86-NEXT:    retl3320;3321; X64-LABEL: test12:3322; X64:       # %bb.0: # %entry3323; X64-NEXT:    movq %rsi, %mm03324; X64-NEXT:    movq %rdi, %mm13325; X64-NEXT:    psignd %mm0, %mm13326; X64-NEXT:    movq %mm1, %rax3327; X64-NEXT:    retq3328entry:3329  %0 = bitcast <1 x i64> %b to <2 x i32>3330  %1 = bitcast <1 x i64> %a to <2 x i32>3331  %2 = bitcast <2 x i32> %1 to <1 x i64>3332  %3 = bitcast <2 x i32> %0 to <1 x i64>3333  %4 = tail call <1 x i64> @llvm.x86.ssse3.psign.d(<1 x i64> %2, <1 x i64> %3) nounwind readnone3334  %5 = bitcast <1 x i64> %4 to <2 x i32>3335  %6 = bitcast <2 x i32> %5 to <1 x i64>3336  %7 = extractelement <1 x i64> %6, i32 03337  ret i64 %73338}3339 3340declare <1 x i64> @llvm.x86.ssse3.psign.w(<1 x i64>, <1 x i64>) nounwind readnone3341 3342define i64 @test11(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {3343; X86-LABEL: test11:3344; X86:       # %bb.0: # %entry3345; X86-NEXT:    pushl %ebp3346; X86-NEXT:    movl %esp, %ebp3347; X86-NEXT:    andl $-8, %esp3348; X86-NEXT:    subl $24, %esp3349; X86-NEXT:    movl 8(%ebp), %eax3350; X86-NEXT:    movl 12(%ebp), %ecx3351; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)3352; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)3353; X86-NEXT:    movl 16(%ebp), %eax3354; X86-NEXT:    movl 20(%ebp), %ecx3355; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)3356; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)3357; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm03358; X86-NEXT:    psignw {{[0-9]+}}(%esp), %mm03359; X86-NEXT:    movq %mm0, (%esp)3360; X86-NEXT:    movl (%esp), %eax3361; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx3362; X86-NEXT:    movl %ebp, %esp3363; X86-NEXT:    popl %ebp3364; X86-NEXT:    retl3365;3366; X64-LABEL: test11:3367; X64:       # %bb.0: # %entry3368; X64-NEXT:    movq %rsi, %mm03369; X64-NEXT:    movq %rdi, %mm13370; X64-NEXT:    psignw %mm0, %mm13371; X64-NEXT:    movq %mm1, %rax3372; X64-NEXT:    retq3373entry:3374  %0 = bitcast <1 x i64> %b to <4 x i16>3375  %1 = bitcast <1 x i64> %a to <4 x i16>3376  %2 = bitcast <4 x i16> %1 to <1 x i64>3377  %3 = bitcast <4 x i16> %0 to <1 x i64>3378  %4 = tail call <1 x i64> @llvm.x86.ssse3.psign.w(<1 x i64> %2, <1 x i64> %3) nounwind readnone3379  %5 = bitcast <1 x i64> %4 to <4 x i16>3380  %6 = bitcast <4 x i16> %5 to <1 x i64>3381  %7 = extractelement <1 x i64> %6, i32 03382  ret i64 %73383}3384 3385declare <1 x i64> @llvm.x86.ssse3.psign.b(<1 x i64>, <1 x i64>) nounwind readnone3386 3387define i64 @test10(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {3388; X86-LABEL: test10:3389; X86:       # %bb.0: # %entry3390; X86-NEXT:    pushl %ebp3391; X86-NEXT:    movl %esp, %ebp3392; X86-NEXT:    andl $-8, %esp3393; X86-NEXT:    subl $24, %esp3394; X86-NEXT:    movl 8(%ebp), %eax3395; X86-NEXT:    movl 12(%ebp), %ecx3396; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)3397; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)3398; X86-NEXT:    movl 16(%ebp), %eax3399; X86-NEXT:    movl 20(%ebp), %ecx3400; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)3401; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)3402; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm03403; X86-NEXT:    psignb {{[0-9]+}}(%esp), %mm03404; X86-NEXT:    movq %mm0, (%esp)3405; X86-NEXT:    movl (%esp), %eax3406; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx3407; X86-NEXT:    movl %ebp, %esp3408; X86-NEXT:    popl %ebp3409; X86-NEXT:    retl3410;3411; X64-LABEL: test10:3412; X64:       # %bb.0: # %entry3413; X64-NEXT:    movq %rsi, %mm03414; X64-NEXT:    movq %rdi, %mm13415; X64-NEXT:    psignb %mm0, %mm13416; X64-NEXT:    movq %mm1, %rax3417; X64-NEXT:    retq3418entry:3419  %0 = bitcast <1 x i64> %b to <8 x i8>3420  %1 = bitcast <1 x i64> %a to <8 x i8>3421  %2 = bitcast <8 x i8> %1 to <1 x i64>3422  %3 = bitcast <8 x i8> %0 to <1 x i64>3423  %4 = tail call <1 x i64> @llvm.x86.ssse3.psign.b(<1 x i64> %2, <1 x i64> %3) nounwind readnone3424  %5 = bitcast <1 x i64> %4 to <8 x i8>3425  %6 = bitcast <8 x i8> %5 to <1 x i64>3426  %7 = extractelement <1 x i64> %6, i32 03427  ret i64 %73428}3429 3430declare <1 x i64> @llvm.x86.ssse3.pshuf.b(<1 x i64>, <1 x i64>) nounwind readnone3431 3432define i64 @test9(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {3433; X86-LABEL: test9:3434; X86:       # %bb.0: # %entry3435; X86-NEXT:    pushl %ebp3436; X86-NEXT:    movl %esp, %ebp3437; X86-NEXT:    andl $-8, %esp3438; X86-NEXT:    subl $24, %esp3439; X86-NEXT:    movl 8(%ebp), %eax3440; X86-NEXT:    movl 12(%ebp), %ecx3441; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)3442; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)3443; X86-NEXT:    movl 16(%ebp), %eax3444; X86-NEXT:    movl 20(%ebp), %ecx3445; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)3446; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)3447; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm03448; X86-NEXT:    pshufb {{[0-9]+}}(%esp), %mm03449; X86-NEXT:    movq %mm0, (%esp)3450; X86-NEXT:    movl (%esp), %eax3451; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx3452; X86-NEXT:    movl %ebp, %esp3453; X86-NEXT:    popl %ebp3454; X86-NEXT:    retl3455;3456; X64-LABEL: test9:3457; X64:       # %bb.0: # %entry3458; X64-NEXT:    movq %rsi, %mm03459; X64-NEXT:    movq %rdi, %mm13460; X64-NEXT:    pshufb %mm0, %mm13461; X64-NEXT:    movq %mm1, %rax3462; X64-NEXT:    retq3463entry:3464  %0 = bitcast <1 x i64> %b to <8 x i8>3465  %1 = bitcast <1 x i64> %a to <8 x i8>3466  %2 = bitcast <8 x i8> %1 to <1 x i64>3467  %3 = bitcast <8 x i8> %0 to <1 x i64>3468  %4 = tail call <1 x i64> @llvm.x86.ssse3.pshuf.b(<1 x i64> %2, <1 x i64> %3) nounwind readnone3469  %5 = bitcast <1 x i64> %4 to <8 x i8>3470  %6 = bitcast <8 x i8> %5 to <1 x i64>3471  %7 = extractelement <1 x i64> %6, i32 03472  ret i64 %73473}3474 3475declare <1 x i64> @llvm.x86.ssse3.pmul.hr.sw(<1 x i64>, <1 x i64>) nounwind readnone3476 3477define i64 @test8(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {3478; X86-LABEL: test8:3479; X86:       # %bb.0: # %entry3480; X86-NEXT:    pushl %ebp3481; X86-NEXT:    movl %esp, %ebp3482; X86-NEXT:    andl $-8, %esp3483; X86-NEXT:    subl $24, %esp3484; X86-NEXT:    movl 8(%ebp), %eax3485; X86-NEXT:    movl 12(%ebp), %ecx3486; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)3487; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)3488; X86-NEXT:    movl 16(%ebp), %eax3489; X86-NEXT:    movl 20(%ebp), %ecx3490; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)3491; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)3492; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm03493; X86-NEXT:    pmulhrsw {{[0-9]+}}(%esp), %mm03494; X86-NEXT:    movq %mm0, (%esp)3495; X86-NEXT:    movl (%esp), %eax3496; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx3497; X86-NEXT:    movl %ebp, %esp3498; X86-NEXT:    popl %ebp3499; X86-NEXT:    retl3500;3501; X64-LABEL: test8:3502; X64:       # %bb.0: # %entry3503; X64-NEXT:    movq %rsi, %mm03504; X64-NEXT:    movq %rdi, %mm13505; X64-NEXT:    pmulhrsw %mm0, %mm13506; X64-NEXT:    movq %mm1, %rax3507; X64-NEXT:    retq3508entry:3509  %0 = bitcast <1 x i64> %b to <4 x i16>3510  %1 = bitcast <1 x i64> %a to <4 x i16>3511  %2 = bitcast <4 x i16> %1 to <1 x i64>3512  %3 = bitcast <4 x i16> %0 to <1 x i64>3513  %4 = tail call <1 x i64> @llvm.x86.ssse3.pmul.hr.sw(<1 x i64> %2, <1 x i64> %3) nounwind readnone3514  %5 = bitcast <1 x i64> %4 to <4 x i16>3515  %6 = bitcast <4 x i16> %5 to <1 x i64>3516  %7 = extractelement <1 x i64> %6, i32 03517  ret i64 %73518}3519 3520declare <1 x i64> @llvm.x86.ssse3.pmadd.ub.sw(<1 x i64>, <1 x i64>) nounwind readnone3521 3522define i64 @test7(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {3523; X86-LABEL: test7:3524; X86:       # %bb.0: # %entry3525; X86-NEXT:    pushl %ebp3526; X86-NEXT:    movl %esp, %ebp3527; X86-NEXT:    andl $-8, %esp3528; X86-NEXT:    subl $24, %esp3529; X86-NEXT:    movl 8(%ebp), %eax3530; X86-NEXT:    movl 12(%ebp), %ecx3531; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)3532; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)3533; X86-NEXT:    movl 16(%ebp), %eax3534; X86-NEXT:    movl 20(%ebp), %ecx3535; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)3536; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)3537; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm03538; X86-NEXT:    pmaddubsw {{[0-9]+}}(%esp), %mm03539; X86-NEXT:    movq %mm0, (%esp)3540; X86-NEXT:    movl (%esp), %eax3541; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx3542; X86-NEXT:    movl %ebp, %esp3543; X86-NEXT:    popl %ebp3544; X86-NEXT:    retl3545;3546; X64-LABEL: test7:3547; X64:       # %bb.0: # %entry3548; X64-NEXT:    movq %rsi, %mm03549; X64-NEXT:    movq %rdi, %mm13550; X64-NEXT:    pmaddubsw %mm0, %mm13551; X64-NEXT:    movq %mm1, %rax3552; X64-NEXT:    retq3553entry:3554  %0 = bitcast <1 x i64> %b to <8 x i8>3555  %1 = bitcast <1 x i64> %a to <8 x i8>3556  %2 = bitcast <8 x i8> %1 to <1 x i64>3557  %3 = bitcast <8 x i8> %0 to <1 x i64>3558  %4 = tail call <1 x i64> @llvm.x86.ssse3.pmadd.ub.sw(<1 x i64> %2, <1 x i64> %3) nounwind readnone3559  %5 = bitcast <1 x i64> %4 to <8 x i8>3560  %6 = bitcast <8 x i8> %5 to <1 x i64>3561  %7 = extractelement <1 x i64> %6, i32 03562  ret i64 %73563}3564 3565declare <1 x i64> @llvm.x86.ssse3.phsub.sw(<1 x i64>, <1 x i64>) nounwind readnone3566 3567define i64 @test6(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {3568; X86-LABEL: test6:3569; X86:       # %bb.0: # %entry3570; X86-NEXT:    pushl %ebp3571; X86-NEXT:    movl %esp, %ebp3572; X86-NEXT:    andl $-8, %esp3573; X86-NEXT:    subl $24, %esp3574; X86-NEXT:    movl 8(%ebp), %eax3575; X86-NEXT:    movl 12(%ebp), %ecx3576; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)3577; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)3578; X86-NEXT:    movl 16(%ebp), %eax3579; X86-NEXT:    movl 20(%ebp), %ecx3580; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)3581; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)3582; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm03583; X86-NEXT:    phsubsw {{[0-9]+}}(%esp), %mm03584; X86-NEXT:    movq %mm0, (%esp)3585; X86-NEXT:    movl (%esp), %eax3586; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx3587; X86-NEXT:    movl %ebp, %esp3588; X86-NEXT:    popl %ebp3589; X86-NEXT:    retl3590;3591; X64-LABEL: test6:3592; X64:       # %bb.0: # %entry3593; X64-NEXT:    movq %rsi, %mm03594; X64-NEXT:    movq %rdi, %mm13595; X64-NEXT:    phsubsw %mm0, %mm13596; X64-NEXT:    movq %mm1, %rax3597; X64-NEXT:    retq3598entry:3599  %0 = bitcast <1 x i64> %b to <4 x i16>3600  %1 = bitcast <1 x i64> %a to <4 x i16>3601  %2 = bitcast <4 x i16> %1 to <1 x i64>3602  %3 = bitcast <4 x i16> %0 to <1 x i64>3603  %4 = tail call <1 x i64> @llvm.x86.ssse3.phsub.sw(<1 x i64> %2, <1 x i64> %3) nounwind readnone3604  %5 = bitcast <1 x i64> %4 to <4 x i16>3605  %6 = bitcast <4 x i16> %5 to <1 x i64>3606  %7 = extractelement <1 x i64> %6, i32 03607  ret i64 %73608}3609 3610declare <1 x i64> @llvm.x86.ssse3.phsub.d(<1 x i64>, <1 x i64>) nounwind readnone3611 3612define i64 @test5(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {3613; X86-LABEL: test5:3614; X86:       # %bb.0: # %entry3615; X86-NEXT:    pushl %ebp3616; X86-NEXT:    movl %esp, %ebp3617; X86-NEXT:    andl $-8, %esp3618; X86-NEXT:    subl $24, %esp3619; X86-NEXT:    movl 8(%ebp), %eax3620; X86-NEXT:    movl 12(%ebp), %ecx3621; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)3622; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)3623; X86-NEXT:    movl 16(%ebp), %eax3624; X86-NEXT:    movl 20(%ebp), %ecx3625; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)3626; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)3627; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm03628; X86-NEXT:    phsubd {{[0-9]+}}(%esp), %mm03629; X86-NEXT:    movq %mm0, (%esp)3630; X86-NEXT:    movl (%esp), %eax3631; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx3632; X86-NEXT:    movl %ebp, %esp3633; X86-NEXT:    popl %ebp3634; X86-NEXT:    retl3635;3636; X64-LABEL: test5:3637; X64:       # %bb.0: # %entry3638; X64-NEXT:    movq %rsi, %mm03639; X64-NEXT:    movq %rdi, %mm13640; X64-NEXT:    phsubd %mm0, %mm13641; X64-NEXT:    movq %mm1, %rax3642; X64-NEXT:    retq3643entry:3644  %0 = bitcast <1 x i64> %b to <2 x i32>3645  %1 = bitcast <1 x i64> %a to <2 x i32>3646  %2 = bitcast <2 x i32> %1 to <1 x i64>3647  %3 = bitcast <2 x i32> %0 to <1 x i64>3648  %4 = tail call <1 x i64> @llvm.x86.ssse3.phsub.d(<1 x i64> %2, <1 x i64> %3) nounwind readnone3649  %5 = bitcast <1 x i64> %4 to <2 x i32>3650  %6 = bitcast <2 x i32> %5 to <1 x i64>3651  %7 = extractelement <1 x i64> %6, i32 03652  ret i64 %73653}3654 3655declare <1 x i64> @llvm.x86.ssse3.phsub.w(<1 x i64>, <1 x i64>) nounwind readnone3656 3657define i64 @test4(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {3658; X86-LABEL: test4:3659; X86:       # %bb.0: # %entry3660; X86-NEXT:    pushl %ebp3661; X86-NEXT:    movl %esp, %ebp3662; X86-NEXT:    andl $-8, %esp3663; X86-NEXT:    subl $24, %esp3664; X86-NEXT:    movl 8(%ebp), %eax3665; X86-NEXT:    movl 12(%ebp), %ecx3666; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)3667; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)3668; X86-NEXT:    movl 16(%ebp), %eax3669; X86-NEXT:    movl 20(%ebp), %ecx3670; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)3671; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)3672; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm03673; X86-NEXT:    phsubw {{[0-9]+}}(%esp), %mm03674; X86-NEXT:    movq %mm0, (%esp)3675; X86-NEXT:    movl (%esp), %eax3676; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx3677; X86-NEXT:    movl %ebp, %esp3678; X86-NEXT:    popl %ebp3679; X86-NEXT:    retl3680;3681; X64-LABEL: test4:3682; X64:       # %bb.0: # %entry3683; X64-NEXT:    movq %rsi, %mm03684; X64-NEXT:    movq %rdi, %mm13685; X64-NEXT:    phsubw %mm0, %mm13686; X64-NEXT:    movq %mm1, %rax3687; X64-NEXT:    retq3688entry:3689  %0 = bitcast <1 x i64> %b to <4 x i16>3690  %1 = bitcast <1 x i64> %a to <4 x i16>3691  %2 = bitcast <4 x i16> %1 to <1 x i64>3692  %3 = bitcast <4 x i16> %0 to <1 x i64>3693  %4 = tail call <1 x i64> @llvm.x86.ssse3.phsub.w(<1 x i64> %2, <1 x i64> %3) nounwind readnone3694  %5 = bitcast <1 x i64> %4 to <4 x i16>3695  %6 = bitcast <4 x i16> %5 to <1 x i64>3696  %7 = extractelement <1 x i64> %6, i32 03697  ret i64 %73698}3699 3700declare <1 x i64> @llvm.x86.ssse3.phadd.sw(<1 x i64>, <1 x i64>) nounwind readnone3701 3702define i64 @test3(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {3703; X86-LABEL: test3:3704; X86:       # %bb.0: # %entry3705; X86-NEXT:    pushl %ebp3706; X86-NEXT:    movl %esp, %ebp3707; X86-NEXT:    andl $-8, %esp3708; X86-NEXT:    subl $24, %esp3709; X86-NEXT:    movl 8(%ebp), %eax3710; X86-NEXT:    movl 12(%ebp), %ecx3711; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)3712; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)3713; X86-NEXT:    movl 16(%ebp), %eax3714; X86-NEXT:    movl 20(%ebp), %ecx3715; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)3716; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)3717; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm03718; X86-NEXT:    phaddsw {{[0-9]+}}(%esp), %mm03719; X86-NEXT:    movq %mm0, (%esp)3720; X86-NEXT:    movl (%esp), %eax3721; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx3722; X86-NEXT:    movl %ebp, %esp3723; X86-NEXT:    popl %ebp3724; X86-NEXT:    retl3725;3726; X64-LABEL: test3:3727; X64:       # %bb.0: # %entry3728; X64-NEXT:    movq %rsi, %mm03729; X64-NEXT:    movq %rdi, %mm13730; X64-NEXT:    phaddsw %mm0, %mm13731; X64-NEXT:    movq %mm1, %rax3732; X64-NEXT:    retq3733entry:3734  %0 = bitcast <1 x i64> %b to <4 x i16>3735  %1 = bitcast <1 x i64> %a to <4 x i16>3736  %2 = bitcast <4 x i16> %1 to <1 x i64>3737  %3 = bitcast <4 x i16> %0 to <1 x i64>3738  %4 = tail call <1 x i64> @llvm.x86.ssse3.phadd.sw(<1 x i64> %2, <1 x i64> %3) nounwind readnone3739  %5 = bitcast <1 x i64> %4 to <4 x i16>3740  %6 = bitcast <4 x i16> %5 to <1 x i64>3741  %7 = extractelement <1 x i64> %6, i32 03742  ret i64 %73743}3744 3745declare <1 x i64> @llvm.x86.ssse3.phadd.d(<1 x i64>, <1 x i64>) nounwind readnone3746 3747define i64 @test2(<1 x i64> %a, <1 x i64> %b) nounwind readnone optsize ssp {3748; X86-LABEL: test2:3749; X86:       # %bb.0: # %entry3750; X86-NEXT:    pushl %ebp3751; X86-NEXT:    movl %esp, %ebp3752; X86-NEXT:    andl $-8, %esp3753; X86-NEXT:    subl $24, %esp3754; X86-NEXT:    movl 8(%ebp), %eax3755; X86-NEXT:    movl 12(%ebp), %ecx3756; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)3757; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)3758; X86-NEXT:    movl 16(%ebp), %eax3759; X86-NEXT:    movl 20(%ebp), %ecx3760; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)3761; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)3762; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm03763; X86-NEXT:    phaddd {{[0-9]+}}(%esp), %mm03764; X86-NEXT:    movq %mm0, (%esp)3765; X86-NEXT:    movl (%esp), %eax3766; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx3767; X86-NEXT:    movl %ebp, %esp3768; X86-NEXT:    popl %ebp3769; X86-NEXT:    retl3770;3771; X64-LABEL: test2:3772; X64:       # %bb.0: # %entry3773; X64-NEXT:    movq %rsi, %mm03774; X64-NEXT:    movq %rdi, %mm13775; X64-NEXT:    phaddd %mm0, %mm13776; X64-NEXT:    movq %mm1, %rax3777; X64-NEXT:    retq3778entry:3779  %0 = bitcast <1 x i64> %b to <2 x i32>3780  %1 = bitcast <1 x i64> %a to <2 x i32>3781  %2 = bitcast <2 x i32> %1 to <1 x i64>3782  %3 = bitcast <2 x i32> %0 to <1 x i64>3783  %4 = tail call <1 x i64> @llvm.x86.ssse3.phadd.d(<1 x i64> %2, <1 x i64> %3) nounwind readnone3784  %5 = bitcast <1 x i64> %4 to <2 x i32>3785  %6 = bitcast <2 x i32> %5 to <1 x i64>3786  %7 = extractelement <1 x i64> %6, i32 03787  ret i64 %73788}3789 3790define <4 x float> @test89(<4 x float> %a, <1 x i64> %b) nounwind {3791; X86-LABEL: test89:3792; X86:       # %bb.0:3793; X86-NEXT:    pushl %ebp3794; X86-NEXT:    movl %esp, %ebp3795; X86-NEXT:    andl $-8, %esp3796; X86-NEXT:    subl $8, %esp3797; X86-NEXT:    movl 8(%ebp), %eax3798; X86-NEXT:    movl 12(%ebp), %ecx3799; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)3800; X86-NEXT:    movl %eax, (%esp)3801; X86-NEXT:    cvtpi2ps (%esp), %xmm03802; X86-NEXT:    movl %ebp, %esp3803; X86-NEXT:    popl %ebp3804; X86-NEXT:    retl3805;3806; X64-LABEL: test89:3807; X64:       # %bb.0:3808; X64-NEXT:    movq %rdi, %mm03809; X64-NEXT:    cvtpi2ps %mm0, %xmm03810; X64-NEXT:    retq3811  %c = tail call <4 x float> @llvm.x86.sse.cvtpi2ps(<4 x float> %a, <1 x i64> %b)3812  ret <4 x float> %c3813}3814 3815declare <4 x float> @llvm.x86.sse.cvtpi2ps(<4 x float>, <1 x i64>) nounwind readnone3816 3817define void @test90() {3818; ALL-LABEL: test90:3819; ALL:       # %bb.0:3820; ALL-NEXT:    emms3821; ALL-NEXT:    ret{{[l|q]}}3822  call void @llvm.x86.mmx.emms()3823  ret void3824}3825 3826declare void @llvm.x86.mmx.emms()3827 3828define <1 x i64> @test_mm_insert_pi16(<1 x i64> %a.coerce, i32 %d) nounwind {3829; X86-LABEL: test_mm_insert_pi16:3830; X86:       # %bb.0: # %entry3831; X86-NEXT:    pushl %ebp3832; X86-NEXT:    movl %esp, %ebp3833; X86-NEXT:    andl $-8, %esp3834; X86-NEXT:    subl $16, %esp3835; X86-NEXT:    movl 8(%ebp), %eax3836; X86-NEXT:    movl 12(%ebp), %ecx3837; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)3838; X86-NEXT:    movl %eax, {{[0-9]+}}(%esp)3839; X86-NEXT:    movq {{[0-9]+}}(%esp), %mm03840; X86-NEXT:    pinsrw $2, 16(%ebp), %mm03841; X86-NEXT:    movq %mm0, (%esp)3842; X86-NEXT:    movl (%esp), %eax3843; X86-NEXT:    movl {{[0-9]+}}(%esp), %edx3844; X86-NEXT:    movl %ebp, %esp3845; X86-NEXT:    popl %ebp3846; X86-NEXT:    retl3847;3848; X64-LABEL: test_mm_insert_pi16:3849; X64:       # %bb.0: # %entry3850; X64-NEXT:    movq %rdi, %mm03851; X64-NEXT:    pinsrw $2, %esi, %mm03852; X64-NEXT:    movq %mm0, %rax3853; X64-NEXT:    retq3854entry:3855  %1 = tail call <1 x i64> @llvm.x86.mmx.pinsr.w(<1 x i64> %a.coerce, i32 %d, i32 2)3856  ret <1 x i64> %13857}3858 3859declare <1 x i64> @llvm.x86.mmx.pinsr.w(<1 x i64>, i32, i32 immarg)3860 3861define i32 @test_mm_extract_pi16(<1 x i64> %a.coerce) nounwind {3862; X86-LABEL: test_mm_extract_pi16:3863; X86:       # %bb.0: # %entry3864; X86-NEXT:    pushl %ebp3865; X86-NEXT:    movl %esp, %ebp3866; X86-NEXT:    andl $-8, %esp3867; X86-NEXT:    subl $8, %esp3868; X86-NEXT:    movl 8(%ebp), %eax3869; X86-NEXT:    movl 12(%ebp), %ecx3870; X86-NEXT:    movl %ecx, {{[0-9]+}}(%esp)3871; X86-NEXT:    movl %eax, (%esp)3872; X86-NEXT:    movq (%esp), %mm03873; X86-NEXT:    pextrw $2, %mm0, %eax3874; X86-NEXT:    movl %ebp, %esp3875; X86-NEXT:    popl %ebp3876; X86-NEXT:    retl3877;3878; X64-LABEL: test_mm_extract_pi16:3879; X64:       # %bb.0: # %entry3880; X64-NEXT:    movq %rdi, %mm03881; X64-NEXT:    pextrw $2, %mm0, %eax3882; X64-NEXT:    retq3883entry:3884  %1 = tail call i32 @llvm.x86.mmx.pextr.w(<1 x i64> %a.coerce, i32 2)3885  ret i32 %13886}3887 3888declare i32 @llvm.x86.mmx.pextr.w(<1 x i64>, i32 immarg)3889