[PATCH] D73217: [InlineCost] Add flag to allow changing the default inline cost

Teresa Johnson via llvm-commits llvm-commits at lists.llvm.org
Wed Jan 22 12:29:07 PST 2020


On Wed, Jan 22, 2020 at 12:24 PM David Li via Phabricator <
reviews at reviews.llvm.org> wrote:

> davidxl added a comment.
>
> This change won't work. See
>
>   if (InlineThreshold.getNumOccurrences() == 0) {
>

I think this is the code the author is specifically wanting to avoid via
the new option. Which is why I suggested a different (bool) flag to control
this code.

    Params.OptMinSizeThreshold = InlineConstants::OptMinSizeThreshold;
>     Params.OptSizeThreshold = InlineConstants::OptSizeThreshold;
>     Params.ColdThreshold = ColdThreshold;
>   } else if (ColdThreshold.getNumOccurrences() > 0) {
>     Params.ColdThreshold = ColdThreshold;
>   }


>
> Repository:
>   rG LLVM Github Monorepo
>
> CHANGES SINCE LAST ACTION
>   https://reviews.llvm.org/D73217/new/
>
> https://reviews.llvm.org/D73217
>
>
>
>

-- 
Teresa Johnson |  Software Engineer |  tejohnson at google.com |
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200122/b63e198f/attachment.html>


More information about the llvm-commits mailing list