[PATCH] D68852: [Attributor] Pointer privatization attribute (argument promotion)
Johannes Doerfert via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Sat Dec 14 00:30:56 PST 2019
jdoerfert added inline comments.
================
Comment at: llvm/include/llvm/Transforms/IPO/Attributor.h:2092
+/// A pointer is privatizable if it can be replaced by a new, private one.
+/// Privatizing pointer reduces the use count, interaction between unrelated
+/// code parts.
----------------
uenoku wrote:
> Could you add comments for the condition of whether the pointer can be replaced a private one?
Done.
================
Comment at: llvm/lib/Transforms/IPO/ArgumentPromotion.cpp:845
-static bool areFunctionArgsABICompatible(
+bool ArgumentPromotionPass::areFunctionArgsABICompatible(
const Function &F, const TargetTransformInfo &TTI,
----------------
uenoku wrote:
> I think you can put this function to `llvm` namespace and split commit.
I would like to get rid of this, the Attributor should directly use a more specialized form of areFunctionArgsABICompatible. I'll add a TODO.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D68852/new/
https://reviews.llvm.org/D68852
More information about the llvm-commits
mailing list