[PATCH] D120584: [NewPM][Inliner] Mark inlined calls to functions in same SCC as callee as noinline
David Li via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Mar 3 23:09:39 PST 2022
davidxl added inline comments.
================
Comment at: llvm/lib/Transforms/IPO/Inliner.cpp:952
+ if (CalleeSCC != C &&
+ CalleeSCC == CG.lookupSCC(CG.get(*NewCallee))) {
+ ICB->addFnAttr(Attribute::NoInline);
----------------
This feels like very strict. Is it possible to allow some level (under an option) of iterative inlining into the same SCC? This is because not all cases of inlining into a non-trivial SCC will result in compile time issue due to existing threshold based stopping mechanism (i.e. the new callee in SCC is too large).
================
Comment at: llvm/test/Transforms/Inline/mut-rec-scc.ll:40
+ call void @test1()
+ call void @dummy()
+ call void @dummy()
----------------
can you add a callsite to a function test3() which is outside the SCC, where the test3's inlining is deferred until test2 is inlined. This is to test that test3's inlining won't be suppressed.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D120584/new/
https://reviews.llvm.org/D120584
More information about the llvm-commits
mailing list