[PATCH] D73912: [mlir] Turn flags in ConvertStandardToLLVM into pass flags
River Riddle via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Feb 3 12:27:23 PST 2020
rriddle added inline comments.
================
Comment at: mlir/include/mlir/Conversion/StandardToLLVM/ConvertStandardToLLVMPass.h:55
/// this may become an enum when we have concrete uses for other options.
-std::unique_ptr<OpPassBase<ModuleOp>>
-createLowerToLLVMPass(bool useAlloca = false);
+std::unique_ptr<OpPassBase<ModuleOp>> createLowerToLLVMPass();
----------------
flaub wrote:
> When building a pipeline at runtime (that is, not using the command line parsing), it'd be good to be able to specify options during pass creation. I've noticed that currently, even the `useAlloca` bool wasn't actually being used, only the `clUseAlloca` was used. So this is a step in the right direction (using instance specific options rather than global ones), but I think we still need the ability to pass options to the creation function.
+1
================
Comment at: mlir/lib/Conversion/StandardToLLVM/ConvertStandardToLLVM.cpp:2399
"Standard to the LLVM dialect",
- [] {
- return std::make_unique<LLVMLoweringPass>(
- clUseAlloca.getValue(), clUseBarePtrCallConv.getValue());
- });
+ [] { return std::make_unique<LLVMLoweringPass>(); });
----------------
You can remove this functor now.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D73912/new/
https://reviews.llvm.org/D73912
More information about the llvm-commits
mailing list