+ if (AliasTy == MustAlias) {
+ // Check that these two merged sets really are must aliases. Since both
+ // used to be must-alias sets, we can just check any pointer from each set
+ // for aliasing.
+ AliasAnalysis &AA = AST.getAliasAnalysis();
+ HashNodePair *L = getSomePointer();
+ HashNodePair *R = AS.getSomePointer();
+
+ // If the pointers are not a must-alias pair, this set becomes a may alias.
+ if (AA.alias(L->first, L->second.getSize(), R->first, R->second.getSize())
+ != AliasAnalysis::MustAlias)
+ AliasTy = MayAlias;
+ }
+