[PATCH] D112036: [opt] Directly translate -O# to -passes='default<O#>'
Artem Belevich via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Oct 18 16:27:46 PDT 2021
tra added inline comments.
================
Comment at: llvm/tools/opt/opt.cpp:790
if (OptLevelO0)
- Passes.push_back("default<O0>");
+ Pipeline = "default<O0>";
if (OptLevelO1)
----------------
A drive-by usability nit, probably for a different/separate patch:
I may be revisiting an old bike-shed, but it would be nice to avoid using characters that require quoting. IMO `--passes=O3` would be as easy to understand as `--passes=default<O3>`, would require a bit less typing for a very common use case, and would not need to have everything quoted in many cases that would need it now (though quoting in general seems unavoidable as we have things like `function(....)`).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D112036/new/
https://reviews.llvm.org/D112036
More information about the llvm-commits
mailing list