Skip to content

Commit

Permalink
[X86][AVX] combineInsertSubvector - remove concat_vectors(load(x),loa…
Browse files Browse the repository at this point in the history
…d(x)) --> sub_vbroadcast(x)

D58053/rL354340 added this to EltsFromConsecutiveLoads directly

llvm-svn: 354732
  • Loading branch information
RKSimon committed Feb 23, 2019
1 parent 398d0b9 commit f383a47
Showing 1 changed file with 0 additions and 5 deletions.
5 changes: 0 additions & 5 deletions llvm/lib/Target/X86/X86ISelLowering.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -41949,11 +41949,6 @@ static SDValue combineInsertSubvector(SDNode *N, SelectionDAG &DAG,
return Ld;
}
}
// If lower/upper loads are the same and there's no other use of the lower
// load, then splat the loaded value with a broadcast.
if (auto *Ld = dyn_cast<LoadSDNode>(peekThroughOneUseBitcasts(SubVec2)))
if (SubVec2 == SubVec && ISD::isNormalLoad(Ld) && Vec.hasOneUse())
return DAG.getNode(X86ISD::SUBV_BROADCAST, dl, OpVT, SubVec);

// If this broadcast/subv_broadcast is inserted into both halves, use a
// larger broadcast/subv_broadcast.
Expand Down

0 comments on commit f383a47

Please sign in to comment.