[DAGCombine] Fold insert_subvector(bitcast(x),bitcast(y),c1) -> bitcast(insert_subvec...
authorSimon Pilgrim <llvm-dev@redking.me.uk>
Sun, 2 Jun 2019 14:42:11 +0000 (14:42 +0000)
committerSimon Pilgrim <llvm-dev@redking.me.uk>
Sun, 2 Jun 2019 14:42:11 +0000 (14:42 +0000)
commit7a869e70367757ca322cdec534504881f11ec731
tree1a359dd14e4a2588c5cdcfc9a9dbce3451edb679
parentffb4d2bff7f1024aa3accd1c387017003b8ce94d
[DAGCombine] Fold insert_subvector(bitcast(x),bitcast(y),c1) -> bitcast(insert_subvector(x,y),c2)

Move this combine from x86 into generic DAGCombine, which currently only manages cases where the bitcast is between types of the same scalarsize.

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

llvm-svn: 362324
llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
llvm/lib/Target/X86/X86ISelLowering.cpp