Home | History | Annotate | Download | only in Scalar

Lines Matching defs:Uses

30 // it's useful to think about these as the same register, with some uses using
32 // example, the icmp is a post-increment user, since it uses %i.next, which is
412 /// formula. This does not include register uses implied by non-constant
440 /// hasRegsUsedByUsesOtherThan - Test whether this formula uses registers
441 /// which are used by uses other than the use with the given index.
1126 /// isUseFullyOutsideLoop - Test whether this fixup always uses its
1202 /// IVUsers, as well as uses invented by LSR itself. It includes information
1242 /// this LSRUse. FindUseWithSimilarFormula can't consider uses with different
1591 /// Relate an IV user to an expression that computes the IV it uses from the IV
1646 /// ChainUsers - Helper for CollectChains to track multiple IV increment uses.
1680 /// Uses - The list of interesting uses.
1681 SmallVector<LSRUse, 16> Uses;
1683 /// RegUses - Track which uses use which register candidates.
1688 // back to normal LSR behavior for those uses.
1934 // NOTE: we could handle setcc instructions with multiple uses here, but
1935 // InstCombine does it as well for simple uses, it's not clear that it
1943 /// OptimizeMax - Rewrite the loop's terminating condition if it uses
2142 // the post-inc value if it won't be shared with other uses.
2253 // the uses will have all its uses outside the loop, for example.
2294 // Basic uses can't accept any offset, for example.
2306 LSRUse &LU = Uses[LUIdx];
2313 size_t LUIdx = Uses.size();
2315 Uses.push_back(LSRUse(Kind, AccessTy));
2316 LSRUse &LU = Uses[LUIdx];
2328 /// DeleteUse - Delete the given use from the Uses list.
2330 if (&LU != &Uses.back())
2331 std::swap(LU, Uses.back());
2332 Uses.pop_back();
2335 RegUses.SwapAndDropUse(LUIdx, Uses.size());
2343 // Search all uses for the formula. This could be more clever.
2344 for (size_t LUIdx = 0, NumUses = Uses.size(); LUIdx != NumUses; ++LUIdx) {
2345 LSRUse &LU = Uses[LUIdx];
2348 // Ignore ICmpZero uses because they may contain formulae generated by
2437 // If all uses use the same type, don't bother looking for truncation-based
2613 // uses. However, a chain with multiple increments requires keeping the IV's
2639 // to a wider type with some uses remaining narrow under a (free) trunc.
2714 // All other uses of IVOperand become near uses of the chain.
2723 // Uses in the chain will no longer be uses if the chain is formed.
2991 // Record the uses.
3047 Uses[LF.LUIdx];
3069 // Mark uses whose expressions cannot be expanded.
3114 /// CollectLoopInvariantFixupsAndFormulae - Check for other uses of
3115 /// loop-invariant values which we're tracking. These other uses will pin these
3143 for (const Use &U : V->uses()) {
3159 // Ignore uses which are part of other SCEV expressions, to avoid
3163 // If the user is a no-op, look through to its uses.
3186 LSRUse &LU = Uses[LF.LUIdx];
3193 CountRegisters(LU.Formulae.back(), Uses.size() - 1);
3666 // TODO: This assumes we've done basic processing on all uses and
3793 LSRUse &LU = Uses[LUIdx];
3883 for (size_t LUIdx = 0, NumUses = Uses.size(); LUIdx != NumUses; ++LUIdx) {
3884 LSRUse &LU = Uses[LUIdx];
3890 for (size_t LUIdx = 0, NumUses = Uses.size(); LUIdx != NumUses; ++LUIdx) {
3891 LSRUse &LU = Uses[LUIdx];
3901 for (size_t LUIdx = 0, NumUses = Uses.size(); LUIdx != NumUses; ++LUIdx) {
3902 LSRUse &LU = Uses[LUIdx];
3915 /// by other uses, pick the best one and delete the others.
3930 for (size_t LUIdx = 0, NumUses = Uses.size(); LUIdx != NumUses; ++LUIdx) {
3931 LSRUse &LU = Uses[LUIdx];
3952 // by uses within other loops that have some non-trivial address mode or
3954 // as the basis of rediscovering the desired formula that uses an AddRec
4026 for (SmallVectorImpl<LSRUse>::const_iterator I = Uses.begin(),
4027 E = Uses.end(); I != E; ++I) {
4040 /// NarrowSearchSpaceByDetectingSupersets - When one formula uses a superset
4052 for (size_t LUIdx = 0, NumUses = Uses.size(); LUIdx != NumUses; ++LUIdx) {
4053 LSRUse &LU = Uses[LUIdx];
4059 // delete the one that uses a register.
4112 "Narrowing the search space by assuming that uses separated "
4117 for (size_t LUIdx = 0, NumUses = Uses.size(); LUIdx != NumUses; ++LUIdx) {
4118 LSRUse &LU = Uses[LUIdx];
4142 Fixup.LUIdx = LUThatHas - &Uses.front();
4174 LUThatHas->RecomputeRegs(LUThatHas - &Uses.front(), RegUses);
4243 for (size_t LUIdx = 0, NumUses = Uses.size(); LUIdx != NumUses; ++LUIdx) {
4244 LSRUse &LU = Uses[LUIdx];
4292 // - sort the uses too
4298 const LSRUse &LU = Uses[Workspace.size()];
4345 if (Workspace.size() != Uses.size()) {
4375 Workspace.reserve(Uses.size());
4389 for (size_t i = 0, e = Uses.size(); i != e; ++i) {
4391 Uses[i].print(dbgs());
4398 assert(Solution.size() == Uses.size() && "Malformed solution!");
4528 const LSRUse &LU = Uses[LF.LUIdx];
4592 "The only scale supported by ICmpZero uses is -1!");
4627 // unfolded offsets. LSR assumes they both live next to their uses.
4790 // find the nearest block which dominates all the relevant uses.
4810 if (Uses[LF.LUIdx].Kind == LSRUse::ICmpZero)
4929 assert(!Uses.empty() && "IVUsers reported at least one use");
4930 DEBUG(dbgs() << "LSR found " << Uses.size() << " uses:\n";
4934 // to formulate the values needed for the uses.
4953 for (SmallVectorImpl<LSRUse>::const_iterator I = Uses.begin(), E = Uses.end();
5001 OS << "LSR is examining the following uses:\n";
5002 for (SmallVectorImpl<LSRUse>::const_iterator I = Uses.begin(),
5003 E = Uses.end(); I != E; ++I) {