Page MenuHomePhabricator

[llvm][NFC] Factor out cost-model independent inling decision
ClosedPublic

Authored by mtrofin on Jan 31 2020, 8:28 PM.

Details

Summary

llvm::getInlineCost starts off by determining whether inlining should
happen or not because of user directives or easily determinable
unviability. This CL refactors this functionality as a reusable API.

Event Timeline

mtrofin created this revision.Jan 31 2020, 8:28 PM
Herald added a project: Restricted Project. · View Herald TranscriptJan 31 2020, 8:28 PM
davidxl added inline comments.Feb 1 2020, 4:40 PM
llvm/lib/Analysis/InlineCost.cpp
2116

Fast --> AttributeBased

davidxl accepted this revision.Feb 3 2020, 9:38 AM

lgtm

This revision is now accepted and ready to land.Feb 3 2020, 9:38 AM
eraman accepted this revision.Feb 3 2020, 10:06 AM
mtrofin marked an inline comment as done.Apr 23 2020, 9:29 AM

PTAL - this slipped my attention. Since some time passed since I got the LGTM, I wanted to doublecheck there's no pushback to landing it.

mtrofin updated this revision to Diff 259632.Apr 23 2020, 10:58 AM

another rebase / fix build

had to add the GetTLI parameter.

This revision was automatically updated to reflect the committed changes.