[PATCH] D130461: [CodeMetrics] use hasOneLiveUse instead of hasOneUse while analyzing inlinable callsites
Chuanqi Xu via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Jul 25 22:47:44 PDT 2022
This revision was landed with ongoing or failed builds.
This revision was automatically updated to reflect the committed changes.
Closed by commit rG7a2f5dca09f0: [CodeMetrics] use hasOneLiveUse instead of hasOneUse while analyzing inlinableā¦ (authored by sinan, committed by ChuanqiXu).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D130461/new/
https://reviews.llvm.org/D130461
Files:
llvm/lib/Analysis/CodeMetrics.cpp
Index: llvm/lib/Analysis/CodeMetrics.cpp
===================================================================
--- llvm/lib/Analysis/CodeMetrics.cpp
+++ llvm/lib/Analysis/CodeMetrics.cpp
@@ -133,7 +133,8 @@
// When preparing for LTO, liberally consider calls as inline
// candidates.
if (!Call->isNoInline() && IsLoweredToCall &&
- ((F->hasInternalLinkage() && F->hasOneUse()) || PrepareForLTO)) {
+ ((F->hasInternalLinkage() && F->hasOneLiveUse()) ||
+ PrepareForLTO)) {
++NumInlineCandidates;
}
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D130461.447570.patch
Type: text/x-patch
Size: 578 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20220726/0e0c65d5/attachment.bin>
More information about the llvm-commits
mailing list