From df34c288c428eb4b867c8075def48b3d1727d60b Mon Sep 17 00:00:00 2001 From: Mehdi Amini Date: Thu, 25 May 2023 20:38:32 -0700 Subject: [PATCH] Fix MLIR Bytecode backward deployment The condition for guarding the properties section was reversed. --- mlir/lib/Bytecode/Writer/BytecodeWriter.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mlir/lib/Bytecode/Writer/BytecodeWriter.cpp b/mlir/lib/Bytecode/Writer/BytecodeWriter.cpp index 0f1395c..252fa92 100644 --- a/mlir/lib/Bytecode/Writer/BytecodeWriter.cpp +++ b/mlir/lib/Bytecode/Writer/BytecodeWriter.cpp @@ -652,7 +652,7 @@ LogicalResult BytecodeWriter::write(Operation *rootOp, raw_ostream &os) { writeStringSection(emitter); // Emit the properties section. - if (config.bytecodeVersion <= 5) + if (config.bytecodeVersion >= 5) writePropertiesSection(emitter); else if (!propertiesSection.empty()) return rootOp->emitError( -- 2.7.4