Skip to content

Commit e7bfbf6

Browse files
committed
Formatting
1 parent e45669a commit e7bfbf6

File tree

3 files changed

+18
-16
lines changed

3 files changed

+18
-16
lines changed

llvm/include/llvm/Target/TargetSelectionDAG.td

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -840,8 +840,8 @@ def vector_insert_subvec : SDNode<"ISD::INSERT_SUBVECTOR",
840840
def extract_subvector : SDNode<"ISD::EXTRACT_SUBVECTOR", SDTSubVecExtract, []>;
841841
def insert_subvector : SDNode<"ISD::INSERT_SUBVECTOR", SDTSubVecInsert, []>;
842842

843-
def find_last_active : SDNode<"ISD::VECTOR_FIND_LAST_ACTIVE",
844-
SDTypeProfile<1, 1, []>, []>;
843+
def find_last_active
844+
: SDNode<"ISD::VECTOR_FIND_LAST_ACTIVE", SDTypeProfile<1, 1, []>, []>;
845845

846846
// Nodes for intrinsics, you should use the intrinsic itself and let tblgen use
847847
// these internally. Don't reference these directly.

llvm/lib/Target/AArch64/AArch64ISelLowering.cpp

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -19946,8 +19946,7 @@ performLastTrueTestVectorCombine(SDNode *N,
1994619946
}
1994719947

1994819948
static SDValue
19949-
performExtractLastActiveCombine(SDNode *N,
19950-
TargetLowering::DAGCombinerInfo &DCI,
19949+
performExtractLastActiveCombine(SDNode *N, TargetLowering::DAGCombinerInfo &DCI,
1995119950
const AArch64Subtarget *Subtarget) {
1995219951
assert(N->getOpcode() == ISD::EXTRACT_VECTOR_ELT);
1995319952
SelectionDAG &DAG = DCI.DAG;
@@ -19960,12 +19959,12 @@ performExtractLastActiveCombine(SDNode *N,
1996019959

1996119960
SDValue Mask = Idx.getOperand(0);
1996219961
const TargetLowering &TLI = DAG.getTargetLoweringInfo();
19963-
if (TLI.getOperationAction(ISD::VECTOR_FIND_LAST_ACTIVE, Mask.getValueType())
19964-
!= TargetLowering::Legal)
19962+
if (TLI.getOperationAction(ISD::VECTOR_FIND_LAST_ACTIVE,
19963+
Mask.getValueType()) != TargetLowering::Legal)
1996519964
return SDValue();
1996619965

19967-
return DAG.getNode(AArch64ISD::LASTB, SDLoc(N), N->getValueType(0),
19968-
Mask, Vec);
19966+
return DAG.getNode(AArch64ISD::LASTB, SDLoc(N), N->getValueType(0), Mask,
19967+
Vec);
1996919968
}
1997019969

1997119970
static SDValue

llvm/lib/Target/AArch64/AArch64SVEInstrInfo.td

Lines changed: 11 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -3381,14 +3381,17 @@ let Predicates = [HasSVE_or_SME] in {
33813381

33823382
// Find index of last active lane. This is a fallback in case we miss the
33833383
// opportunity to fold into a lastb or clastb directly.
3384-
def : Pat<(i64 (find_last_active nxv16i1:$P1)),
3385-
(INSERT_SUBREG (IMPLICIT_DEF), (LASTB_RPZ_B $P1, (INDEX_II_B 0, 1)), sub_32)>;
3386-
def : Pat<(i64 (find_last_active nxv8i1:$P1)),
3387-
(INSERT_SUBREG (IMPLICIT_DEF), (LASTB_RPZ_H $P1, (INDEX_II_H 0, 1)), sub_32)>;
3388-
def : Pat<(i64 (find_last_active nxv4i1:$P1)),
3389-
(INSERT_SUBREG (IMPLICIT_DEF), (LASTB_RPZ_S $P1, (INDEX_II_S 0, 1)), sub_32)>;
3390-
def : Pat<(i64 (find_last_active nxv2i1:$P1)),
3391-
(LASTB_RPZ_D $P1, (INDEX_II_D 0, 1))>;
3384+
def : Pat<(i64(find_last_active nxv16i1:$P1)),
3385+
(INSERT_SUBREG(IMPLICIT_DEF), (LASTB_RPZ_B $P1, (INDEX_II_B 0, 1)),
3386+
sub_32)>;
3387+
def : Pat<(i64(find_last_active nxv8i1:$P1)),
3388+
(INSERT_SUBREG(IMPLICIT_DEF), (LASTB_RPZ_H $P1, (INDEX_II_H 0, 1)),
3389+
sub_32)>;
3390+
def : Pat<(i64(find_last_active nxv4i1:$P1)),
3391+
(INSERT_SUBREG(IMPLICIT_DEF), (LASTB_RPZ_S $P1, (INDEX_II_S 0, 1)),
3392+
sub_32)>;
3393+
def : Pat<(i64(find_last_active nxv2i1:$P1)), (LASTB_RPZ_D $P1, (INDEX_II_D 0,
3394+
1))>;
33923395

33933396
// Move element from the bottom 128-bits of a scalable vector to a single-element vector.
33943397
// Alternative case where insertelement is just scalar_to_vector rather than vector_insert.

0 commit comments

Comments
 (0)