Skip to content

Commit

Permalink
NFC changes to SelectionDAGBuilder::visitBitTestHeader(), preparing f…
Browse files Browse the repository at this point in the history
…or PR43129

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@373191 91177308-0d34-0410-b5e6-96231b3b80d8
  • Loading branch information
zmodem committed Sep 30, 2019
1 parent f608f8a commit 4d6b6c6
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2619,13 +2619,13 @@ void SelectionDAGBuilder::visitBitTestHeader(BitTestBlock &B,
MachineBasicBlock *SwitchBB) {
SDLoc dl = getCurSDLoc();

// Subtract the minimum value
// Subtract the minimum value.
SDValue SwitchOp = getValue(B.SValue);
EVT VT = SwitchOp.getValueType();
SDValue Sub = DAG.getNode(ISD::SUB, dl, VT, SwitchOp,
DAG.getConstant(B.First, dl, VT));

// Check range
// Check range.
const TargetLowering &TLI = DAG.getTargetLoweringInfo();
SDValue RangeCmp = DAG.getSetCC(
dl, TLI.getSetCCResultType(DAG.getDataLayout(), *DAG.getContext(),
Expand All @@ -2634,9 +2634,9 @@ void SelectionDAGBuilder::visitBitTestHeader(BitTestBlock &B,

// Determine the type of the test operands.
bool UsePtrType = false;
if (!TLI.isTypeLegal(VT))
if (!TLI.isTypeLegal(VT)) {
UsePtrType = true;
else {
} else {
for (unsigned i = 0, e = B.Cases.size(); i != e; ++i)
if (!isUIntN(VT.getSizeInBits(), B.Cases[i].Mask)) {
// Switch table case range are encoded into series of masks.
Expand Down

0 comments on commit 4d6b6c6

Please sign in to comment.