[Mlir-commits] [mlir] [mlir] add MlirOptMain config callback for context configuration (PR #68228)
Ingo Müller
llvmlistbot at llvm.org
Thu Oct 5 05:49:21 PDT 2023
================
@@ -131,8 +131,12 @@ void mlir::registerPassManagerCLOptions() {
}
LogicalResult mlir::applyPassManagerCLOptions(PassManager &pm) {
- if (!options.isConstructed())
+ if (!options.isConstructed()) {
+ emitError(UnknownLoc::get(pm.getContext()))
+ << "could not apply pass manager command line options.\n"
+ "Missing 'registerPassManagerCLOptions' call?\n";
return failure();
----------------
ingomueller-net wrote:
Isn't the following the idiomatic way to write this?
```suggestion
return emitError(UnknownLoc::get(pm.getContext()))
<< "could not apply pass manager command line options.\n"
"Missing 'registerPassManagerCLOptions' call?\n";
```
https://github.com/llvm/llvm-project/pull/68228
More information about the Mlir-commits
mailing list