]> granicus.if.org Git - clang/commit
[X86] Emit native IR for pmuldq/pmuludq builtins.
authorCraig Topper <craig.topper@intel.com>
Mon, 9 Apr 2018 19:17:54 +0000 (19:17 +0000)
committerCraig Topper <craig.topper@intel.com>
Mon, 9 Apr 2018 19:17:54 +0000 (19:17 +0000)
commit55aa0b574a6890505d73b0df23e66a47541103ab
tree6949557f371db0cac74e1b4c3b3e6e99f772f316
parent0314cfe5d65defac1f794710cd44ab2d5cc106d8
[X86] Emit native IR for pmuldq/pmuludq builtins.

I believe all the pieces are now in place in the backend to make this work correctly. We can either mask the input to 32 bits for pmuludg or shl/ashr for pmuldq and use a regular mul instruction. The backend should combine this to PMULUDQ/PMULDQ and then SimplifyDemandedBits will remove the and/shifts.

Differential Revision: https://reviews.llvm.org/D45421

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@329605 91177308-0d34-0410-b5e6-96231b3b80d8
lib/CodeGen/CGBuiltin.cpp
test/CodeGen/avx2-builtins.c
test/CodeGen/avx512f-builtins.c
test/CodeGen/avx512vl-builtins.c
test/CodeGen/sse2-builtins.c
test/CodeGen/sse41-builtins.c