Lines Matching refs:Alias
1 //===- AliasSetTracker.cpp - Alias Sets Tracker implementation-------------===//
29 /// mergeSetIn - Merge the specified alias set into this alias set.
32 assert(!AS.Forward && "Alias set is already forwarding!");
35 // Update the alias and access types of this set...
37 Alias |= AS.Alias;
40 if (Alias == SetMustAlias) {
42 // used to be must-alias sets, we can just check any pointer from each set
48 // If the pointers are not a must-alias pair, this set becomes a may alias.
49 if (AA.alias(MemoryLocation(L->getValue(), L->getSize(), L->getAAInfo()),
52 Alias = SetMayAlias;
92 assert(RefCount == 0 && "Cannot remove non-dead alias set from tracker!");
101 // Check to see if we have to downgrade to _may_ alias.
106 AA.alias(MemoryLocation(P->getValue(), P->getSize(), P->getAAInfo()),
109 Alias = SetMayAlias;
110 else // First entry of must alias must have maximum size!
123 addRef(); // Entry points to alias set.
132 Alias = SetMayAlias;
138 Alias = SetMayAlias;
143 /// alias one of the members in the set.
148 if (Alias == SetMustAlias) {
149 assert(UnknownInsts.empty() && "Illegal must alias set!");
154 assert(SomePtr && "Empty must-alias set??");
155 return AA.alias(MemoryLocation(SomePtr->getValue(), SomePtr->getSize(),
160 // If this is a may-alias set, we have to check all of the pointers in the set
161 // to be sure it doesn't alias the set...
163 if (AA.alias(MemoryLocation(Ptr, Size, AAInfo),
206 // The alias sets should all be clear now.
211 /// findAliasSetForPointer - Given a pointer, find the one alias set to put the
212 /// instruction referring to the pointer into. If there are multiple alias sets
213 /// that may alias the pointer, merge them together and return the unified set.
223 if (!FoundSet) { // If this is the first alias set ptr can go into.
234 /// this alias set, false otherwise. This does not modify the AST object or
235 /// alias sets.
257 if (!FoundSet) // If this is the first alias set ptr can go into.
268 /// getAliasSetForPointer - Return the alias set that the specified pointer
283 // Add it to the alias set it aliases.
289 // Otherwise create a new alias set to hold the loaded pointer.
350 return true; // doesn't alias anything
381 "Merging AliasSetTracker objects with different Alias Analyses!");
383 // Loop over all of the alias sets in AST, adding the pointers contained
384 // therein into the current alias sets. This can cause alias sets to be
387 if (I->Forward) continue; // Ignore forwarding alias sets
391 // If there are any call sites in the alias set, add them to this AST.
395 // Loop over all of the pointers in this alias set.
406 /// remove - Remove the specified (potentially non-empty) alias set from the
414 // Clear the alias set.
431 // Stop using the alias set, removing it.
484 return false; // doesn't alias anything
514 // Scan all the alias sets to see if this call site is contained.
527 // If we found one, remove the pointer from the alias set it is in.
534 // Stop using the alias set.
555 // Add it to the alias set it aliases...
571 OS << (Alias == SetMustAlias ? "must" : "may") << " alias, ";
603 OS << "Alias Set Tracker: " << AliasSets.size() << " alias sets for "
669 INITIALIZE_PASS_BEGIN(AliasSetPrinter, "print-alias-sets",
670 "Alias Set Printer", false, true)
672 INITIALIZE_PASS_END(AliasSetPrinter, "print-alias-sets",
673 "Alias Set Printer", false, true)