Skip to content
Merged
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 3 additions & 4 deletions llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1773,10 +1773,9 @@ SDValue SelectionDAG::getConstant(const ConstantInt &Val, const SDLoc &DL,
SDValue SelectionDAG::getSignedConstant(int64_t Val, const SDLoc &DL, EVT VT,
bool isT, bool isO) {
unsigned Size = VT.getScalarSizeInBits();
assert(
isIntN(Size, Val) &&
"getSignedConstant with a int64_t value that doesn't fit in the type!");
return getConstant(APInt(Size, Val, true), DL, VT, isT, isO);
return getConstant(
APInt(Size, Val, /*isSigned=*/true, /*implicitTrunc=*/false), DL, VT, isT,
isO);
}

SDValue SelectionDAG::getAllOnesConstant(const SDLoc &DL, EVT VT, bool IsTarget,
Expand Down
Loading