[PATCH] D20603: [Inline] Add ability to restrict inlining pass to hinted functions only

Rudy Pons via llvm-commits llvm-commits at lists.llvm.org
Thu Jun 16 15:31:22 PDT 2016

Ilod updated this revision to Diff 61040.
Ilod added a comment.

It's an equivalent of /Ob1 on MSVC. We usually use this option on build where we want only optimizations that do not hinder debugging. I want to use this to add support for /Ob1 in clang-cl mode.
It seems I could push -mllvm -inline-threshold=-1000 args or something like this when I get the /Ob1 argument instead of adding an API control in LLVM. It feels a little hackish to me (mainly because of the "arbitrary negative enough threshold" I would need to hardcode in clang), the inlining pass would need to compute the size even if it could be avoided, but it would work just fine. I would rather have an API access than pushing -mllvm command line parameters from clang, but I can live with it if you think it's better to keep it this way.

Fixed the typo, moved the test checks.



-------------- next part --------------
A non-text attachment was scrubbed...
Name: D20603.61040.patch
Type: text/x-patch
Size: 4918 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20160616/1764bc11/attachment.bin>

More information about the llvm-commits mailing list