[llvm-commits] [llvm] r149367 - in /llvm/trunk: include/llvm/IntrinsicsX86.td lib/Target/X86/X86ISelLowering.cpp test/CodeGen/X86/2006-05-11-InstrSched.ll test/CodeGen/X86/avx-intrinsics-x86.ll test/CodeGen/X86/avx2-intrinsics-x86.ll
Duncan Sands
baldrick at free.fr
Tue Jan 31 02:35:29 PST 2012
Hi Craig,
> Remove pcmpgt/pcmpeq intrinsics as clang is not using them.
dragonegg is using them. Can the same effect be obtained some other way?
Ciao, Duncan.
>
> Modified:
> llvm/trunk/include/llvm/IntrinsicsX86.td
> llvm/trunk/lib/Target/X86/X86ISelLowering.cpp
> llvm/trunk/test/CodeGen/X86/2006-05-11-InstrSched.ll
> llvm/trunk/test/CodeGen/X86/avx-intrinsics-x86.ll
> llvm/trunk/test/CodeGen/X86/avx2-intrinsics-x86.ll
>
> Modified: llvm/trunk/include/llvm/IntrinsicsX86.td
> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/IntrinsicsX86.td?rev=149367&r1=149366&r2=149367&view=diff
> ==============================================================================
> --- llvm/trunk/include/llvm/IntrinsicsX86.td (original)
> +++ llvm/trunk/include/llvm/IntrinsicsX86.td Tue Jan 31 00:52:44 2012
> @@ -452,28 +452,6 @@
> llvm_i32_ty], [IntrNoMem]>;
> }
>
> -// Integer comparison ops
> -let TargetPrefix = "x86" in { // All intrinsics start with "llvm.x86.".
> - def int_x86_sse2_pcmpeq_b : GCCBuiltin<"__builtin_ia32_pcmpeqb128">,
> - Intrinsic<[llvm_v16i8_ty], [llvm_v16i8_ty,
> - llvm_v16i8_ty], [IntrNoMem, Commutative]>;
> - def int_x86_sse2_pcmpeq_w : GCCBuiltin<"__builtin_ia32_pcmpeqw128">,
> - Intrinsic<[llvm_v8i16_ty], [llvm_v8i16_ty,
> - llvm_v8i16_ty], [IntrNoMem, Commutative]>;
> - def int_x86_sse2_pcmpeq_d : GCCBuiltin<"__builtin_ia32_pcmpeqd128">,
> - Intrinsic<[llvm_v4i32_ty], [llvm_v4i32_ty,
> - llvm_v4i32_ty], [IntrNoMem, Commutative]>;
> - def int_x86_sse2_pcmpgt_b : GCCBuiltin<"__builtin_ia32_pcmpgtb128">,
> - Intrinsic<[llvm_v16i8_ty], [llvm_v16i8_ty,
> - llvm_v16i8_ty], [IntrNoMem]>;
> - def int_x86_sse2_pcmpgt_w : GCCBuiltin<"__builtin_ia32_pcmpgtw128">,
> - Intrinsic<[llvm_v8i16_ty], [llvm_v8i16_ty,
> - llvm_v8i16_ty], [IntrNoMem]>;
> - def int_x86_sse2_pcmpgt_d : GCCBuiltin<"__builtin_ia32_pcmpgtd128">,
> - Intrinsic<[llvm_v4i32_ty], [llvm_v4i32_ty,
> - llvm_v4i32_ty], [IntrNoMem]>;
> -}
> -
> // Conversion ops
> let TargetPrefix = "x86" in { // All intrinsics start with "llvm.x86.".
> def int_x86_sse2_cvtdq2pd : GCCBuiltin<"__builtin_ia32_cvtdq2pd">,
> @@ -792,12 +770,6 @@
>
> // Vector compare, min, max
> let TargetPrefix = "x86" in { // All intrinsics start with "llvm.x86.".
> - def int_x86_sse41_pcmpeqq : GCCBuiltin<"__builtin_ia32_pcmpeqq">,
> - Intrinsic<[llvm_v2i64_ty], [llvm_v2i64_ty, llvm_v2i64_ty],
> - [IntrNoMem, Commutative]>;
> - def int_x86_sse42_pcmpgtq : GCCBuiltin<"__builtin_ia32_pcmpgtq">,
> - Intrinsic<[llvm_v2i64_ty], [llvm_v2i64_ty, llvm_v2i64_ty],
> - [IntrNoMem]>;
> def int_x86_sse41_pmaxsb : GCCBuiltin<"__builtin_ia32_pmaxsb128">,
> Intrinsic<[llvm_v16i8_ty], [llvm_v16i8_ty, llvm_v16i8_ty],
> [IntrNoMem, Commutative]>;
> @@ -1515,34 +1487,6 @@
> llvm_i32_ty], [IntrNoMem]>;
> }
>
> -// Integer comparison ops
> -let TargetPrefix = "x86" in { // All intrinsics start with "llvm.x86.".
> - def int_x86_avx2_pcmpeq_b : GCCBuiltin<"__builtin_ia32_pcmpeqb256">,
> - Intrinsic<[llvm_v32i8_ty], [llvm_v32i8_ty, llvm_v32i8_ty],
> - [IntrNoMem, Commutative]>;
> - def int_x86_avx2_pcmpeq_w : GCCBuiltin<"__builtin_ia32_pcmpeqw256">,
> - Intrinsic<[llvm_v16i16_ty], [llvm_v16i16_ty, llvm_v16i16_ty],
> - [IntrNoMem, Commutative]>;
> - def int_x86_avx2_pcmpeq_d : GCCBuiltin<"__builtin_ia32_pcmpeqd256">,
> - Intrinsic<[llvm_v8i32_ty], [llvm_v8i32_ty, llvm_v8i32_ty],
> - [IntrNoMem, Commutative]>;
> - def int_x86_avx2_pcmpeq_q : GCCBuiltin<"__builtin_ia32_pcmpeqq256">,
> - Intrinsic<[llvm_v4i64_ty], [llvm_v4i64_ty, llvm_v4i64_ty],
> - [IntrNoMem, Commutative]>;
> - def int_x86_avx2_pcmpgt_b : GCCBuiltin<"__builtin_ia32_pcmpgtb256">,
> - Intrinsic<[llvm_v32i8_ty], [llvm_v32i8_ty, llvm_v32i8_ty],
> - [IntrNoMem]>;
> - def int_x86_avx2_pcmpgt_w : GCCBuiltin<"__builtin_ia32_pcmpgtw256">,
> - Intrinsic<[llvm_v16i16_ty], [llvm_v16i16_ty, llvm_v16i16_ty],
> - [IntrNoMem]>;
> - def int_x86_avx2_pcmpgt_d : GCCBuiltin<"__builtin_ia32_pcmpgtd256">,
> - Intrinsic<[llvm_v8i32_ty], [llvm_v8i32_ty, llvm_v8i32_ty],
> - [IntrNoMem]>;
> - def int_x86_avx2_pcmpgt_q : GCCBuiltin<"__builtin_ia32_pcmpgtq256">,
> - Intrinsic<[llvm_v4i64_ty], [llvm_v4i64_ty, llvm_v4i64_ty],
> - [IntrNoMem]>;
> -}
> -
> // Pack ops.
> let TargetPrefix = "x86" in { // All intrinsics start with "llvm.x86.".
> def int_x86_avx2_packsswb : GCCBuiltin<"__builtin_ia32_packsswb256">,
>
> Modified: llvm/trunk/lib/Target/X86/X86ISelLowering.cpp
> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/X86/X86ISelLowering.cpp?rev=149367&r1=149366&r2=149367&view=diff
> ==============================================================================
> --- llvm/trunk/lib/Target/X86/X86ISelLowering.cpp (original)
> +++ llvm/trunk/lib/Target/X86/X86ISelLowering.cpp Tue Jan 31 00:52:44 2012
> @@ -9492,26 +9492,6 @@
> case Intrinsic::x86_avx2_psrav_d_256:
> return DAG.getNode(ISD::SRA, dl, Op.getValueType(),
> Op.getOperand(1), Op.getOperand(2));
> - case Intrinsic::x86_sse2_pcmpeq_b:
> - case Intrinsic::x86_sse2_pcmpeq_w:
> - case Intrinsic::x86_sse2_pcmpeq_d:
> - case Intrinsic::x86_sse41_pcmpeqq:
> - case Intrinsic::x86_avx2_pcmpeq_b:
> - case Intrinsic::x86_avx2_pcmpeq_w:
> - case Intrinsic::x86_avx2_pcmpeq_d:
> - case Intrinsic::x86_avx2_pcmpeq_q:
> - return DAG.getNode(X86ISD::PCMPEQ, dl, Op.getValueType(),
> - Op.getOperand(1), Op.getOperand(2));
> - case Intrinsic::x86_sse2_pcmpgt_b:
> - case Intrinsic::x86_sse2_pcmpgt_w:
> - case Intrinsic::x86_sse2_pcmpgt_d:
> - case Intrinsic::x86_sse42_pcmpgtq:
> - case Intrinsic::x86_avx2_pcmpgt_b:
> - case Intrinsic::x86_avx2_pcmpgt_w:
> - case Intrinsic::x86_avx2_pcmpgt_d:
> - case Intrinsic::x86_avx2_pcmpgt_q:
> - return DAG.getNode(X86ISD::PCMPGT, dl, Op.getValueType(),
> - Op.getOperand(1), Op.getOperand(2));
> case Intrinsic::x86_ssse3_pshuf_b_128:
> case Intrinsic::x86_avx2_pshuf_b:
> return DAG.getNode(X86ISD::PSHUFB, dl, Op.getValueType(),
>
> Modified: llvm/trunk/test/CodeGen/X86/2006-05-11-InstrSched.ll
> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/X86/2006-05-11-InstrSched.ll?rev=149367&r1=149366&r2=149367&view=diff
> ==============================================================================
> --- llvm/trunk/test/CodeGen/X86/2006-05-11-InstrSched.ll (original)
> +++ llvm/trunk/test/CodeGen/X86/2006-05-11-InstrSched.ll Tue Jan 31 00:52:44 2012
> @@ -30,7 +30,7 @@
> %tmp87 = bitcast<16 x i8> %tmp66 to<4 x i32> ;<<4 x i32>> [#uses=1]
> %tmp88 = add<4 x i32> %tmp87, %tmp77 ;<<4 x i32>> [#uses=2]
> %tmp88.upgrd.4 = bitcast<4 x i32> %tmp88 to<2 x i64> ;<<2 x i64>> [#uses=1]
> - %tmp99 = tail call<4 x i32> @llvm.x86.sse2.pcmpgt.d(<4 x i32> %tmp88,<4 x i32> %tmp55 ) ;<<4 x i32>> [#uses=1]
> + %tmp99 = tail call<4 x i32> @llvm.x86.sse2.psra.d(<4 x i32> %tmp88,<4 x i32> %tmp55 ) ;<<4 x i32>> [#uses=1]
> %tmp99.upgrd.5 = bitcast<4 x i32> %tmp99 to<2 x i64> ;<<2 x i64>> [#uses=2]
> %tmp110 = xor<2 x i64> %tmp99.upgrd.5,< i64 -1, i64 -1> ;<<2 x i64>> [#uses=1]
> %tmp111 = and<2 x i64> %tmp110, %tmp55.upgrd.2 ;<<2 x i64>> [#uses=1]
> @@ -48,4 +48,4 @@
> ret void
> }
>
> -declare<4 x i32> @llvm.x86.sse2.pcmpgt.d(<4 x i32>,<4 x i32>)
> +declare<4 x i32> @llvm.x86.sse2.psra.d(<4 x i32>,<4 x i32>)
>
> Modified: llvm/trunk/test/CodeGen/X86/avx-intrinsics-x86.ll
> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/X86/avx-intrinsics-x86.ll?rev=149367&r1=149366&r2=149367&view=diff
> ==============================================================================
> --- llvm/trunk/test/CodeGen/X86/avx-intrinsics-x86.ll (original)
> +++ llvm/trunk/test/CodeGen/X86/avx-intrinsics-x86.ll Tue Jan 31 00:52:44 2012
> @@ -369,54 +369,6 @@
> declare<8 x i16> @llvm.x86.sse2.pavg.w(<8 x i16>,<8 x i16>) nounwind readnone
>
>
> -define<16 x i8> @test_x86_sse2_pcmpeq_b(<16 x i8> %a0,<16 x i8> %a1) {
> - ; CHECK: vpcmpeqb
> - %res = call<16 x i8> @llvm.x86.sse2.pcmpeq.b(<16 x i8> %a0,<16 x i8> %a1) ;<<16 x i8>> [#uses=1]
> - ret<16 x i8> %res
> -}
> -declare<16 x i8> @llvm.x86.sse2.pcmpeq.b(<16 x i8>,<16 x i8>) nounwind readnone
> -
> -
> -define<4 x i32> @test_x86_sse2_pcmpeq_d(<4 x i32> %a0,<4 x i32> %a1) {
> - ; CHECK: vpcmpeqd
> - %res = call<4 x i32> @llvm.x86.sse2.pcmpeq.d(<4 x i32> %a0,<4 x i32> %a1) ;<<4 x i32>> [#uses=1]
> - ret<4 x i32> %res
> -}
> -declare<4 x i32> @llvm.x86.sse2.pcmpeq.d(<4 x i32>,<4 x i32>) nounwind readnone
> -
> -
> -define<8 x i16> @test_x86_sse2_pcmpeq_w(<8 x i16> %a0,<8 x i16> %a1) {
> - ; CHECK: vpcmpeqw
> - %res = call<8 x i16> @llvm.x86.sse2.pcmpeq.w(<8 x i16> %a0,<8 x i16> %a1) ;<<8 x i16>> [#uses=1]
> - ret<8 x i16> %res
> -}
> -declare<8 x i16> @llvm.x86.sse2.pcmpeq.w(<8 x i16>,<8 x i16>) nounwind readnone
> -
> -
> -define<16 x i8> @test_x86_sse2_pcmpgt_b(<16 x i8> %a0,<16 x i8> %a1) {
> - ; CHECK: vpcmpgtb
> - %res = call<16 x i8> @llvm.x86.sse2.pcmpgt.b(<16 x i8> %a0,<16 x i8> %a1) ;<<16 x i8>> [#uses=1]
> - ret<16 x i8> %res
> -}
> -declare<16 x i8> @llvm.x86.sse2.pcmpgt.b(<16 x i8>,<16 x i8>) nounwind readnone
> -
> -
> -define<4 x i32> @test_x86_sse2_pcmpgt_d(<4 x i32> %a0,<4 x i32> %a1) {
> - ; CHECK: vpcmpgtd
> - %res = call<4 x i32> @llvm.x86.sse2.pcmpgt.d(<4 x i32> %a0,<4 x i32> %a1) ;<<4 x i32>> [#uses=1]
> - ret<4 x i32> %res
> -}
> -declare<4 x i32> @llvm.x86.sse2.pcmpgt.d(<4 x i32>,<4 x i32>) nounwind readnone
> -
> -
> -define<8 x i16> @test_x86_sse2_pcmpgt_w(<8 x i16> %a0,<8 x i16> %a1) {
> - ; CHECK: vpcmpgtw
> - %res = call<8 x i16> @llvm.x86.sse2.pcmpgt.w(<8 x i16> %a0,<8 x i16> %a1) ;<<8 x i16>> [#uses=1]
> - ret<8 x i16> %res
> -}
> -declare<8 x i16> @llvm.x86.sse2.pcmpgt.w(<8 x i16>,<8 x i16>) nounwind readnone
> -
> -
> define<4 x i32> @test_x86_sse2_pmadd_wd(<8 x i16> %a0,<8 x i16> %a1) {
> ; CHECK: vpmaddwd
> %res = call<4 x i32> @llvm.x86.sse2.pmadd.wd(<8 x i16> %a0,<8 x i16> %a1) ;<<4 x i32>> [#uses=1]
> @@ -950,14 +902,6 @@
> declare<8 x i16> @llvm.x86.sse41.pblendw(<8 x i16>,<8 x i16>, i32) nounwind readnone
>
>
> -define<2 x i64> @test_x86_sse41_pcmpeqq(<2 x i64> %a0,<2 x i64> %a1) {
> - ; CHECK: vpcmpeqq
> - %res = call<2 x i64> @llvm.x86.sse41.pcmpeqq(<2 x i64> %a0,<2 x i64> %a1) ;<<2 x i64>> [#uses=1]
> - ret<2 x i64> %res
> -}
> -declare<2 x i64> @llvm.x86.sse41.pcmpeqq(<2 x i64>,<2 x i64>) nounwind readnone
> -
> -
> define<8 x i16> @test_x86_sse41_phminposuw(<8 x i16> %a0) {
> ; CHECK: vphminposuw
> %res = call<8 x i16> @llvm.x86.sse41.phminposuw(<8 x i16> %a0) ;<<8 x i16>> [#uses=1]
> @@ -1271,14 +1215,6 @@
> declare<16 x i8> @llvm.x86.sse42.pcmpestrm128(<16 x i8>, i32,<16 x i8>, i32, i8) nounwind readnone
>
>
> -define<2 x i64> @test_x86_sse42_pcmpgtq(<2 x i64> %a0,<2 x i64> %a1) {
> - ; CHECK: vpcmpgtq
> - %res = call<2 x i64> @llvm.x86.sse42.pcmpgtq(<2 x i64> %a0,<2 x i64> %a1) ;<<2 x i64>> [#uses=1]
> - ret<2 x i64> %res
> -}
> -declare<2 x i64> @llvm.x86.sse42.pcmpgtq(<2 x i64>,<2 x i64>) nounwind readnone
> -
> -
> define i32 @test_x86_sse42_pcmpistri128(<16 x i8> %a0,<16 x i8> %a1) {
> ; CHECK: vpcmpistri
> ; CHECK: movl
>
> Modified: llvm/trunk/test/CodeGen/X86/avx2-intrinsics-x86.ll
> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/X86/avx2-intrinsics-x86.ll?rev=149367&r1=149366&r2=149367&view=diff
> ==============================================================================
> --- llvm/trunk/test/CodeGen/X86/avx2-intrinsics-x86.ll (original)
> +++ llvm/trunk/test/CodeGen/X86/avx2-intrinsics-x86.ll Tue Jan 31 00:52:44 2012
> @@ -72,54 +72,6 @@
> declare<16 x i16> @llvm.x86.avx2.pavg.w(<16 x i16>,<16 x i16>) nounwind readnone
>
>
> -define<32 x i8> @test_x86_avx2_pcmpeq_b(<32 x i8> %a0,<32 x i8> %a1) {
> - ; CHECK: vpcmpeqb
> - %res = call<32 x i8> @llvm.x86.avx2.pcmpeq.b(<32 x i8> %a0,<32 x i8> %a1) ;<<32 x i8>> [#uses=1]
> - ret<32 x i8> %res
> -}
> -declare<32 x i8> @llvm.x86.avx2.pcmpeq.b(<32 x i8>,<32 x i8>) nounwind readnone
> -
> -
> -define<8 x i32> @test_x86_avx2_pcmpeq_d(<8 x i32> %a0,<8 x i32> %a1) {
> - ; CHECK: vpcmpeqd
> - %res = call<8 x i32> @llvm.x86.avx2.pcmpeq.d(<8 x i32> %a0,<8 x i32> %a1) ;<<8 x i32>> [#uses=1]
> - ret<8 x i32> %res
> -}
> -declare<8 x i32> @llvm.x86.avx2.pcmpeq.d(<8 x i32>,<8 x i32>) nounwind readnone
> -
> -
> -define<16 x i16> @test_x86_avx2_pcmpeq_w(<16 x i16> %a0,<16 x i16> %a1) {
> - ; CHECK: vpcmpeqw
> - %res = call<16 x i16> @llvm.x86.avx2.pcmpeq.w(<16 x i16> %a0,<16 x i16> %a1) ;<<16 x i16>> [#uses=1]
> - ret<16 x i16> %res
> -}
> -declare<16 x i16> @llvm.x86.avx2.pcmpeq.w(<16 x i16>,<16 x i16>) nounwind readnone
> -
> -
> -define<32 x i8> @test_x86_avx2_pcmpgt_b(<32 x i8> %a0,<32 x i8> %a1) {
> - ; CHECK: vpcmpgtb
> - %res = call<32 x i8> @llvm.x86.avx2.pcmpgt.b(<32 x i8> %a0,<32 x i8> %a1) ;<<32 x i8>> [#uses=1]
> - ret<32 x i8> %res
> -}
> -declare<32 x i8> @llvm.x86.avx2.pcmpgt.b(<32 x i8>,<32 x i8>) nounwind readnone
> -
> -
> -define<8 x i32> @test_x86_avx2_pcmpgt_d(<8 x i32> %a0,<8 x i32> %a1) {
> - ; CHECK: vpcmpgtd
> - %res = call<8 x i32> @llvm.x86.avx2.pcmpgt.d(<8 x i32> %a0,<8 x i32> %a1) ;<<8 x i32>> [#uses=1]
> - ret<8 x i32> %res
> -}
> -declare<8 x i32> @llvm.x86.avx2.pcmpgt.d(<8 x i32>,<8 x i32>) nounwind readnone
> -
> -
> -define<16 x i16> @test_x86_avx2_pcmpgt_w(<16 x i16> %a0,<16 x i16> %a1) {
> - ; CHECK: vpcmpgtw
> - %res = call<16 x i16> @llvm.x86.avx2.pcmpgt.w(<16 x i16> %a0,<16 x i16> %a1) ;<<16 x i16>> [#uses=1]
> - ret<16 x i16> %res
> -}
> -declare<16 x i16> @llvm.x86.avx2.pcmpgt.w(<16 x i16>,<16 x i16>) nounwind readnone
> -
> -
> define<8 x i32> @test_x86_avx2_pmadd_wd(<16 x i16> %a0,<16 x i16> %a1) {
> ; CHECK: vpmaddwd
> %res = call<8 x i32> @llvm.x86.avx2.pmadd.wd(<16 x i16> %a0,<16 x i16> %a1) ;<<8 x i32>> [#uses=1]
> @@ -553,14 +505,6 @@
> declare<16 x i16> @llvm.x86.avx2.pblendw(<16 x i16>,<16 x i16>, i32) nounwind readnone
>
>
> -define<4 x i64> @test_x86_avx2_pcmpeqq(<4 x i64> %a0,<4 x i64> %a1) {
> - ; CHECK: vpcmpeqq
> - %res = call<4 x i64> @llvm.x86.avx2.pcmpeq.q(<4 x i64> %a0,<4 x i64> %a1) ;<<4 x i64>> [#uses=1]
> - ret<4 x i64> %res
> -}
> -declare<4 x i64> @llvm.x86.avx2.pcmpeq.q(<4 x i64>,<4 x i64>) nounwind readnone
> -
> -
> define<32 x i8> @test_x86_avx2_pmaxsb(<32 x i8> %a0,<32 x i8> %a1) {
> ; CHECK: vpmaxsb
> %res = call<32 x i8> @llvm.x86.avx2.pmaxs.b(<32 x i8> %a0,<32 x i8> %a1) ;<<32 x i8>> [#uses=1]
> @@ -729,14 +673,6 @@
> declare<4 x i64> @llvm.x86.avx2.pmul.dq(<8 x i32>,<8 x i32>) nounwind readnone
>
>
> -define<4 x i64> @test_x86_avx2_pcmpgtq(<4 x i64> %a0,<4 x i64> %a1) {
> - ; CHECK: vpcmpgtq
> - %res = call<4 x i64> @llvm.x86.avx2.pcmpgt.q(<4 x i64> %a0,<4 x i64> %a1) ;<<4 x i64>> [#uses=1]
> - ret<4 x i64> %res
> -}
> -declare<4 x i64> @llvm.x86.avx2.pcmpgt.q(<4 x i64>,<4 x i64>) nounwind readnone
> -
> -
> define<4 x i64> @test_x86_avx2_vbroadcasti128(i8* %a0) {
> ; CHECK: vbroadcasti128
> %res = call<4 x i64> @llvm.x86.avx2.vbroadcasti128(i8* %a0) ;<<4 x i64>> [#uses=1]
>
>
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
More information about the llvm-commits
mailing list