Lines Matching refs:OG
95 InstrGroup &OG, unsigned &TotalSize, unsigned MaxSize);
96 bool createWideStores(InstrGroup &OG, InstrGroup &NG, unsigned TotalSize);
97 bool replaceStores(InstrGroup &OG, InstrGroup &NG);
305 /// in OG ("old group" of instructions).
306 /// OG should be empty on entry, and should be left empty if the function
309 InstrGroup::iterator End, InstrGroup &OG, unsigned &TotalSize,
312 assert(OG.empty() && "Old group not empty on entry");
343 OG.push_back(FirstMI);
347 // Pow2Num will be the largest number of elements in OG such that the sum
368 OG.push_back(S2);
371 Pow2Num = OG.size();
383 OG.clear();
388 OG.resize(Pow2Num);
394 /// Given an "old group" OG of stores, create a "new group" NG of instructions
397 bool HexagonStoreWidening::createWideStores(InstrGroup &OG, InstrGroup &NG,
400 // - only expect stores of immediate values in OG,
409 for (InstrGroup::iterator I = OG.begin(), E = OG.end(); I != E; ++I) {
423 MachineInstr *FirstSt = OG.front();
424 DebugLoc DL = OG.back()->getDebugLoc();
475 OG with instructions from the
476 // new group NG. Conceptually, remove all instructions in OG, and then
478 // from OG was (in the order in which they appeared in the basic block).
479 // (The ordering in OG does not have to match the order in the basic block.)
480 bool HexagonStoreWidening::replaceStores(InstrGroup &OG, InstrGroup &NG) {
483 for (auto I : OG)
490 MachineBasicBlock *MBB = OG.back()->getParent();
494 // the first store in the OG, but in the order in which the stores occur
495 // in the program list. Since the ordering in OG does not correspond
499 // Create a set of all instructions in OG (for quick lookup).
501 for (auto I : OG)
504 // Traverse the block, until we hit an instruction from OG.
525 for (auto I : OG)
546 InstrGroup OG, NG; // Old and new groups.
550 OG.clear();
553 bool Succ = selectStores(I++, E, OG, CollectedSize, MaxWideSize) &&
554 createWideStores(OG, NG, CollectedSize) &&
555 replaceStores(OG, NG);
559 assert(OG.size() > 1 && "Created invalid group");
560 assert(distance(I, E)+1 >= int(OG.size()) && "Too many elements");
561 I += OG.size()-1;