The assert message was previously ignored. This change adds a new helper function printStr to the runtime library and calls it in case of a failed assertion.
Depends On D138576
Paths
| Differential D138647
[mlir][cf] Print message in cf.assert to LLVM lowering ClosedPublic Authored by springerm on Nov 24 2022, 3:09 AM.
Details Summary The assert message was previously ignored. This change adds a new helper function printStr to the runtime library and calls it in case of a failed assertion. Depends On D138576
Diff Detail
Event Timeline
Comment Actions I'm leaving a few high level comments first. I think this abortOnFailedAssert=false case should be handled by a separate test pass instead.
springerm marked 2 inline comments as done. Comment Actionsaddress comments
springerm added a child revision: D138671: [mlir][memref] Add runtime verification for memref::CastOp.Nov 24 2022, 7:12 AM
This revision is now accepted and ready to land.Dec 15 2022, 6:27 AM This revision was landed with ongoing or failed builds.Dec 15 2022, 8:45 AM Closed by commit rG325b58d59f00: [mlir][cf] Print message in cf.assert to LLVM lowering (authored by springerm). · Explain Why This revision was automatically updated to reflect the committed changes.
Revision Contents
Diff 480015 mlir/include/mlir/Conversion/ControlFlowToLLVM/ControlFlowToLLVM.h
mlir/include/mlir/Dialect/LLVMIR/FunctionCallUtils.h
mlir/lib/Conversion/ControlFlowToLLVM/ControlFlowToLLVM.cpp
mlir/lib/Dialect/LLVMIR/IR/FunctionCallUtils.cpp
mlir/test/Integration/Dialect/ControlFlow/assert.mlir
mlir/test/lib/Dialect/CMakeLists.txt
mlir/test/lib/Dialect/ControlFlow/CMakeLists.txt
mlir/test/lib/Dialect/ControlFlow/TestAssert.cpp
mlir/tools/mlir-opt/mlir-opt.cpp
utils/bazel/llvm-project-overlay/mlir/BUILD.bazel
utils/bazel/llvm-project-overlay/mlir/test/BUILD.bazel
|
set to false