[PATCH] D110891: [inliner] Mandatory inlining decisions produce remarks
Mircea Trofin via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Oct 4 22:42:00 PDT 2021
mtrofin marked an inline comment as done.
mtrofin added inline comments.
================
Comment at: llvm/lib/Analysis/InlineAdvisor.cpp:72-89
+ void recordUnsuccessfulInliningImpl(const InlineResult &Result) override {
+ if (IsInliningRecommended)
+ ORE.emit([&]() {
+ return OptimizationRemarkMissed(DEBUG_TYPE, "NotInlined", DLoc, Block)
+ << "'" << NV("Callee", Callee) << "' is not AlwaysInline into '"
+ << NV("Caller", Caller)
+ << "': " << NV("Reason", Result.getFailureReason());
----------------
aeubanks wrote:
> mtrofin wrote:
> > aeubanks wrote:
> > > can we add a test for these?
> > I think that would be tricky, because they should not actually happen - the way we determine whether a site is alwaysinlinable checks (but not thoroughly) for legality. Let me see if I can find a regression test. It may be we can synthesize such a case in IR only, though, so not much of a help for the frontend tests?
> yeah some IR tests is what I was thinking
Done. The 'unattempted' case is really an assert, but got a test for the attempted but failed.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D110891/new/
https://reviews.llvm.org/D110891
More information about the llvm-commits
mailing list