Skip to content

Commit fc6c465

Browse files
committed
address comments
1 parent 57b9c81 commit fc6c465

File tree

2 files changed

+12
-3
lines changed

2 files changed

+12
-3
lines changed

llvm/lib/Target/NVPTX/NVPTXISelLowering.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2764,11 +2764,11 @@ static SDValue lowerCTLZCTPOP(SDValue Op, SelectionDAG &DAG) {
27642764
return DAG.getNode(ISD::ZERO_EXTEND, DL, MVT::i64, CT, SDNodeFlags::NonNeg);
27652765
}
27662766

2767-
static SDValue expandFSH64(SDValue A, SDValue B, SDValue AmtVal, SDLoc DL,
2767+
static SDValue expandFSH64(SDValue A, SDValue B, SDValue ShiftAmount, SDLoc DL,
27682768
unsigned Opcode, SelectionDAG &DAG) {
27692769
assert(A.getValueType() == MVT::i64 && B.getValueType() == MVT::i64);
27702770

2771-
const auto *AmtConst = dyn_cast<ConstantSDNode>(AmtVal);
2771+
const auto *AmtConst = dyn_cast<ConstantSDNode>(ShiftAmount);
27722772
if (!AmtConst)
27732773
return SDValue();
27742774
const auto Amt = AmtConst->getZExtValue() & 63;

llvm/lib/Target/NVPTX/NVPTXISelLowering.h

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,8 +61,17 @@ enum NodeType : unsigned {
6161
BFE,
6262
BFI,
6363
PRMT,
64-
UNPACK_VECTOR,
64+
65+
/// This node is similar to ISD::BUILD_VECTOR except that the output may be
66+
/// implicitly bitcast to a scalar. This allows for the representation of
67+
/// packing move instructions for vector types which are not legal i.e. v2i32
6568
BUILD_VECTOR,
69+
70+
/// This node is the inverse of NVPTX::BUILD_VECTOR. It takes a single value
71+
/// which may be a scalar and unpacks it into multiple values by implicitly
72+
/// converting it to a vector.
73+
UNPACK_VECTOR,
74+
6675
FCOPYSIGN,
6776
DYNAMIC_STACKALLOC,
6877
STACKRESTORE,

0 commit comments

Comments
 (0)