Skip to content

Commit 1b5a55a

Browse files
committed
fixup
1 parent efc8e2a commit 1b5a55a

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

third_party/intel/lib/TritonIntelGPUTransforms/AccelerateMatmul.cpp

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -120,14 +120,13 @@ class BlockedToDPAS : public OpRewritePattern<tt::DotOp> {
120120

121121
SmallVector<unsigned> order = {0, 1};
122122
Operation *aOp = a.getDefiningOp();
123-
if (isa<ttg::ConvertLayoutOp>(aOp)) {
123+
if (aOp && isa<ttg::ConvertLayoutOp>(aOp)) {
124124
auto valueToConvert = aOp->getOperand(0);
125125
aOp = valueToConvert.getDefiningOp();
126126
}
127127
if (aOp && isa<tt::LoadOp>(aOp)) {
128-
Attribute layout;
129128
assert(aOp->getNumResults() == 1);
130-
layout =
129+
Attribute layout =
131130
cast<RankedTensorType>(aOp->getResult(0).getType()).getEncoding();
132131
order = triton::gpu::getOrder(layout);
133132
}

0 commit comments

Comments
 (0)