[X86, AVX2] Replace inserti128 and extracti128 intrinsics with generic shuffles
authorSanjay Patel <spatel@rotateright.com>
Thu, 12 Mar 2015 23:16:18 +0000 (23:16 +0000)
committerSanjay Patel <spatel@rotateright.com>
Thu, 12 Mar 2015 23:16:18 +0000 (23:16 +0000)
commitcae9695fbb56c139e3150194f40a98007bb44494
tree39d8e03185beed1decd94d77895945de475d2a6e
parent740aee4b5341ec217eda0902d4ad340a831b4cee
[X86, AVX2] Replace inserti128 and extracti128 intrinsics with generic shuffles

This should complete the job started in r231794 and continued in r232045:
We want to replace as much custom x86 shuffling via intrinsics
as possible because pushing the code down the generic shuffle
optimization path allows for better codegen and less complexity
in LLVM.

AVX2 introduced proper integer variants of the hacked integer insert/extract
C intrinsics that were created for this same functionality with AVX1.

This should complete the removal of insert/extract128 intrinsics.

The Clang precursor patch for this change was checked in at r232109.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@232120 91177308-0d34-0410-b5e6-96231b3b80d8
include/llvm/IR/IntrinsicsX86.td
lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp
lib/IR/AutoUpgrade.cpp
lib/Target/X86/X86InstrSSE.td
test/CodeGen/X86/avx2-intrinsics-x86-upgrade.ll
test/CodeGen/X86/avx2-intrinsics-x86.ll