File tree 1 file changed +6
-4
lines changed
lib/Dialect/TritonGPU/Transforms
1 file changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -131,19 +131,21 @@ class HoistLayoutConversion : public OpRewritePattern<ConvertLayoutOp> {
131
131
// bitwidth is unable to realize that there is a mixed-precision dot
132
132
// (hence kWidth = 1) but wants to hoist through the type conversion.
133
133
if (isa<arith::ExtFOp>(src) && dotOpEnc.getKWidth () == 1 )
134
- return failure ();
134
+ return failure ();
135
135
136
- // Only consider custom conversions or arith ops.
136
+ // Only consider custom conversions, math or arith ops.
137
137
// TODO(jlebar): Is this too restrictive?
138
138
if (!isa<FpToFpOp, BitcastOp>(src) && !isPureUnaryInlineAsm (src) &&
139
- src->getDialect ()->getTypeID () != TypeID::get<arith::ArithDialect>())
139
+ src->getDialect ()->getTypeID () != TypeID::get<arith::ArithDialect>() &&
140
+ src->getDialect ()->getTypeID () != TypeID::get<math::MathDialect>())
140
141
return failure ();
141
142
142
143
// Currently, these instructions are not supported during lowering of
143
144
// shared -> dot_operand layout. Not all types and type conversions are
144
145
// supported.
145
- if (isa<arith::TruncIOp, arith::TruncFOp, arith:: SelectOp>(src))
146
+ if (isa<arith::SelectOp>(src)) {
146
147
return failure ();
148
+ }
147
149
148
150
// Don't hoist through u1 -> fp casts as they aren't supported in
149
151
// ElementwiseOpToLLVM::reorderValues().
You can’t perform that action at this time.
0 commit comments