@@ -591,6 +591,7 @@ struct TritonIntelGPUInferLayoutInterface
591591 }
592592
593593 LogicalResult inferTransOpEncoding (Attribute operandEncoding,
594+ ArrayRef<int64_t > shape,
594595 ArrayRef<int32_t > order, // trans order
595596 Attribute &resultEncoding) const override {
596597 // Not support TransOp on DPAS layout.
@@ -663,18 +664,19 @@ struct TritonIntelGPUInferLayoutInterface
663664 return success ();
664665 }
665666
666- LogicalResult verifyLayoutsAreEqual (ArrayRef<int64_t > shape,
667- Attribute expected, Attribute got,
668- Location loc) const override {
667+ LogicalResult
668+ verifyLayoutsAreEqual (ArrayRef<int64_t > shape, Attribute expected,
669+ Attribute got,
670+ std::optional<Location> loc) const override {
669671 if (expected == got) {
670672 return success ();
671673 }
672674 // Check whether the encodings are structurally the same.
673675 auto expectedLL = triton::gpu::toLinearLayout (shape, expected);
674676 auto gotLL = triton::gpu::toLinearLayout (shape, got);
675677 if (expectedLL != gotLL) {
676- return emitError (loc, " Expected result encoding " )
677- << expected << " but was " << got;
678+ return emitOptionalError (loc, " Expected result encoding " , expected,
679+ " but was " , got) ;
678680 }
679681 return success ();
680682 }
0 commit comments