diff --git a/mlir/lib/Dialect/Quant/Utils/UniformSupport.cpp b/mlir/lib/Dialect/Quant/Utils/UniformSupport.cpp --- a/mlir/lib/Dialect/Quant/Utils/UniformSupport.cpp +++ b/mlir/lib/Dialect/Quant/Utils/UniformSupport.cpp @@ -46,8 +46,8 @@ switch (inputType.getKind()) { default: - if (isQuantizablePrimitiveType(elementalType)) { - // For primitives, just use the new elemental type. + if (elementalType.getExpressedType() == expressedType) { + // If the expressed types match, just use the new elemental type. return elementalType; } // Unsupported.