[PATCH] D39732: [Analysis] Fix merging TBAA tags with different final access types
Hal Finkel via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Nov 7 09:21:38 PST 2017
hfinkel accepted this revision.
hfinkel added inline comments.
This revision is now accepted and ready to land.
================
Comment at: lib/Analysis/TypeBasedAliasAnalysis.cpp:545
TBAAStructTagNode TagA(A), TagB(B);
+ const MDNode *CommonType = getLeastCommonType(TagA.getAccessType(),
+ TagB.getAccessType());
----------------
kosarev wrote:
> hfinkel wrote:
> > Can you please *explain* the problem in the patch description.
> >
> > Also, we're now creating new metadata nodes speculatively (i.e., in cases where we we'll return false); can we avoid doing that? (maybe using a lambda function would help?)
> Sure, sorry.
>
> Re: creating nodes: we have to produce the generic tag regardless of whether the input tags may alias. We did it before and we do it now; the patch is not supposed to change anything in this regard.
Thanks. LGTM.
Repository:
rL LLVM
https://reviews.llvm.org/D39732
More information about the llvm-commits
mailing list