reference, declarationdefinition
definition → references, declarations, derived classes, virtual overrides
reference to multiple definitions → definitions
unreferenced

References

lib/Transforms/Scalar/Reassociate.cpp
 2202   Ops.reserve(Tree.size());
 2205     Ops.append(E.second.getZExtValue(),
 2209   LLVM_DEBUG(dbgs() << "RAIn:\t"; PrintOps(I, Ops); dbgs() << '\n');
 2217   llvm::stable_sort(Ops);
 2221   if (Value *V = OptimizeExpression(I, Ops)) {
 2244         isa<ConstantInt>(Ops.back().Op) &&
 2245         cast<ConstantInt>(Ops.back().Op)->isMinusOne()) {
 2246       ValueEntry Tmp = Ops.pop_back_val();
 2247       Ops.insert(Ops.begin(), Tmp);
 2247       Ops.insert(Ops.begin(), Tmp);
 2251                isa<ConstantFP>(Ops.back().Op) &&
 2252                cast<ConstantFP>(Ops.back().Op)->isExactlyValue(-1.0)) {
 2253       ValueEntry Tmp = Ops.pop_back_val();
 2254       Ops.insert(Ops.begin(), Tmp);
 2254       Ops.insert(Ops.begin(), Tmp);
 2258   LLVM_DEBUG(dbgs() << "RAOut:\t"; PrintOps(I, Ops); dbgs() << '\n');
 2260   if (Ops.size() == 1) {
 2261     if (Ops[0].Op == I)
 2267     I->replaceAllUsesWith(Ops[0].Op);
 2268     if (Instruction *OI = dyn_cast<Instruction>(Ops[0].Op))
 2274   if (Ops.size() > 2 && Ops.size() <= GlobalReassociateLimit) {
 2274   if (Ops.size() > 2 && Ops.size() <= GlobalReassociateLimit) {
 2285     for (unsigned i = 0; i < Ops.size() - 1; ++i)
 2286       for (unsigned j = i + 1; j < Ops.size(); ++j) {
 2288         Value *Op0 = Ops[i].Op;
 2289         Value *Op1 = Ops[j].Op;
 2303         unsigned MaxRank = std::max(Ops[i].Rank, Ops[j].Rank);
 2303         unsigned MaxRank = std::max(Ops[i].Rank, Ops[j].Rank);
 2311       auto Op0 = Ops[BestPair.first];
 2312       auto Op1 = Ops[BestPair.second];
 2313       Ops.erase(&Ops[BestPair.second]);
 2313       Ops.erase(&Ops[BestPair.second]);
 2314       Ops.erase(&Ops[BestPair.first]);
 2314       Ops.erase(&Ops[BestPair.first]);
 2315       Ops.push_back(Op0);
 2316       Ops.push_back(Op1);
 2321   RewriteExprTree(I, Ops);