[PATCH] D38689: [X86] Fix a bug with i386 subtarget in LowerCONCAT_VECTORSvXi1 func
Ayman Musa via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Oct 10 00:30:31 PDT 2017
aymanmus added inline comments.
================
Comment at: lib/Target/X86/X86ISelLowering.cpp:8032
- SDValue ZeroC = DAG.getConstant(0, dl, MVT::i64);
+ SDValue ZeroC = DAG.getConstant(0, dl,
+ Subtarget.is64Bit() ? MVT::i64 : MVT::i32);
SDValue AllZeros = DAG.getSplatBuildVector(ResVT, dl, ZeroC);
return DAG.getNode(ISD::INSERT_SUBVECTOR, dl, ResVT, AllZeros, Promoted,
----------------
craig.topper wrote:
> RKSimon wrote:
> > Surely you could just use DAG.getIntPtrConstant(0, dl) ?
> Should this just be calling getZeroVector?
It's possible. But since the ZeroC has an additional use (cannot be removed), it will end up the same.
https://reviews.llvm.org/D38689
More information about the llvm-commits
mailing list