Skip to content

Commit 3f1d70f

Browse files
authored
1 parent 68a08dd commit 3f1d70f

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed

lib/Conversion/TritonGPUToLLVM/ConvertLayoutOpToLLVM.cpp

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -376,13 +376,16 @@ struct ConvertLayoutOpUsingLinearLayoutsConversion
376376
// completed before we can remove the layoutIsOK check:
377377
// 1. Support for AMD's WMMA
378378
std::function<bool(Attribute)> layoutIsOK = [&](Attribute layout) {
379-
if (auto dotOperand = dyn_cast<DotOperandEncodingAttr>(layout)) {
380-
layout = dotOperand.getParent();
381-
}
382-
383379
if (isa<NvidiaMmaEncodingAttr, AMDMfmaEncodingAttr>(layout)) {
384380
return !useLegacyMMAConversion;
385381
}
382+
if (auto dotOperand = dyn_cast<DotOperandEncodingAttr>(layout)) {
383+
if (isa<NvidiaMmaEncodingAttr, AMDMfmaEncodingAttr>(
384+
dotOperand.getParent())) {
385+
return !useLegacyMMAConversion;
386+
}
387+
return false;
388+
}
386389
if (isa<BlockedEncodingAttr, LinearEncodingAttr>(layout)) {
387390
return true;
388391
}

0 commit comments

Comments
 (0)