[PATCH] D81929: [WIP][Attributor] Introduce CallBaseContext to the IRPosition
Johannes Doerfert via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Jul 17 20:37:24 PDT 2020
jdoerfert added inline comments.
================
Comment at: llvm/include/llvm/Transforms/IPO/Attributor.h:938
+ const IRPosition RealIRP =
+ shouldPropagateCallBaseContext(IRP) ? IRP : IRP.stripCallBaseContext();
+
----------------
kuter wrote:
> jdoerfert wrote:
> > `& RealIRP` or maybe:
> > ```
> > if (!should...)
> > IRP = IRP.strip...
> > ```
> I think that was the first way that I tried.
> Reassigning a const reference does not work.
>
>
You are right. We can remove the const and reference from IRP actually. Either way is fine with me. If we do it as you have it now, maybe make it a reference. I'm not sold on `Real` as a name, maybe `Effective`, but that is not perfect either.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D81929/new/
https://reviews.llvm.org/D81929
More information about the llvm-commits
mailing list