Skip to content

Commit 8acc72c

Browse files
committed
Add comments for the case that zp's are constant
1 parent f74c662 commit 8acc72c

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

mlir/lib/Conversion/TosaToLinalg/TosaToLinalg.cpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1650,9 +1650,11 @@ class RescaleConverter : public OpRewritePattern<tosa::RescaleOp> {
16501650
FailureOr<int64_t> maybeOZp = op.getOutputZeroPoint();
16511651
// The inputZp and outputZp may be either constant or non-constant,
16521652
// depending on whether dynamic extension is enabled.
1653-
// - If the zp is non-constant, add it as an input to linalg::GenericOp by:
1653+
// - If the zp's are non-constant, add them as an inputs to
1654+
// linalg::GenericOp by:
16541655
// 1. Pushing it into 'genericInputs'.
16551656
// 2. Appending a corresponding affine map to 'indexingMaps'.
1657+
// - If the zp's are constant, they would be generated as arith.constant.
16561658
int64_t iZpArg = 0;
16571659
if (failed(maybeIZp)) {
16581660
genericInputs.push_back(

0 commit comments

Comments
 (0)