================
@@ -5963,24 +5963,40 @@ bool InstCombinerImpl::run() {
 class AliasScopeTracker {
   SmallPtrSet<const MDNode *, 8> UsedAliasScopesAndLists;
   SmallPtrSet<const MDNode *, 8> UsedNoAliasScopesAndLists;
+  // The domains with disjoint scopes of which more than one scope is used by
+  // !alias.scope, along with the first such scope seen for each domain.
+  SmallDenseMap<const MDNode *, const MDNode *, 4> FirstScopeInDisjointDomain;
+  SmallPtrSet<const MDNode *, 4> UsedDisjointDomains;
----------------
brunodf-gf wrote:

Maybe the following is more precise:
Instead of tracking the used disjoint-scope domains, I think you can track 
those _scopes_ that belong to a disjoint-scope domain, and that always appear 
in the !alias.scope list whenever a scope from that disjoint-scope domain is 
used. It seems to me such scopes are dead (since they are never implicitly on 
the !noalias list).

https://github.com/llvm/llvm-project/pull/218768
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to