[InstCombine] Remove redundant splats in InstCombineVectorOps
authorMatt Devereau <matthew.devereau@arm.com>
Wed, 12 Oct 2022 09:20:05 +0000 (09:20 +0000)
committerMatt Devereau <matthew.devereau@arm.com>
Mon, 7 Nov 2022 15:39:05 +0000 (15:39 +0000)
commita8c24d57b81703b5730460d7cb12af9783a02539
treec01ae18a77b880df7aad4b15a3e267985e3fa573
parent9b800bf79d9d2fa18ed5be891346155238015515
[InstCombine] Remove redundant splats in InstCombineVectorOps

Splatting the first vector element of the result of a BinOp, where any of the
BinOp's operands are the result of a first vector element splat can be simplified to
splatting the first vector element of the result of the BinOp

Differential Revision: https://reviews.llvm.org/D135876
llvm/lib/Transforms/InstCombine/InstCombineInternal.h
llvm/lib/Transforms/InstCombine/InstCombineVectorOps.cpp
llvm/test/Transforms/InstCombine/shuffle-binop.ll
llvm/test/Transforms/VectorCombine/AArch64/insert-shuffle-binop.ll [deleted file]