< prev index next >

src/share/vm/opto/superword.hpp

Print this page




 212   OrderedPair() : _p1(NULL), _p2(NULL) {}
 213   OrderedPair(Node* p1, Node* p2) {
 214     if (p1->_idx < p2->_idx) {
 215       _p1 = p1; _p2 = p2;
 216     } else {
 217       _p1 = p2; _p2 = p1;
 218     }
 219   }
 220 
 221   bool operator==(const OrderedPair &rhs) {
 222     return _p1 == rhs._p1 && _p2 == rhs._p2;
 223   }
 224   void print() { tty->print("  (%d, %d)", _p1->_idx, _p2->_idx); }
 225 
 226   static const OrderedPair initial;
 227 };
 228 
 229 // -----------------------------SuperWord---------------------------------
 230 // Transforms scalar operations into packed (superword) operations.
 231 class SuperWord : public ResourceObj {

 232  private:
 233   PhaseIdealLoop* _phase;
 234   Arena*          _arena;
 235   PhaseIterGVN   &_igvn;
 236 
 237   enum consts { top_align = -1, bottom_align = -666 };
 238 
 239   GrowableArray<Node_List*> _packset;    // Packs for the current block
 240 
 241   GrowableArray<int> _bb_idx;            // Map from Node _idx to index within block
 242 
 243   GrowableArray<Node*> _block;           // Nodes in current block
 244   GrowableArray<Node*> _data_entry;      // Nodes with all inputs from outside
 245   GrowableArray<Node*> _mem_slice_head;  // Memory slice head nodes
 246   GrowableArray<Node*> _mem_slice_tail;  // Memory slice tail nodes
 247 
 248   GrowableArray<SWNodeInfo> _node_info;  // Info needed per node
 249 
 250   MemNode* _align_to_ref;                // Memory reference that pre-loop will align to
 251 




 212   OrderedPair() : _p1(NULL), _p2(NULL) {}
 213   OrderedPair(Node* p1, Node* p2) {
 214     if (p1->_idx < p2->_idx) {
 215       _p1 = p1; _p2 = p2;
 216     } else {
 217       _p1 = p2; _p2 = p1;
 218     }
 219   }
 220 
 221   bool operator==(const OrderedPair &rhs) {
 222     return _p1 == rhs._p1 && _p2 == rhs._p2;
 223   }
 224   void print() { tty->print("  (%d, %d)", _p1->_idx, _p2->_idx); }
 225 
 226   static const OrderedPair initial;
 227 };
 228 
 229 // -----------------------------SuperWord---------------------------------
 230 // Transforms scalar operations into packed (superword) operations.
 231 class SuperWord : public ResourceObj {
 232  friend class SWPointer;
 233  private:
 234   PhaseIdealLoop* _phase;
 235   Arena*          _arena;
 236   PhaseIterGVN   &_igvn;
 237 
 238   enum consts { top_align = -1, bottom_align = -666 };
 239 
 240   GrowableArray<Node_List*> _packset;    // Packs for the current block
 241 
 242   GrowableArray<int> _bb_idx;            // Map from Node _idx to index within block
 243 
 244   GrowableArray<Node*> _block;           // Nodes in current block
 245   GrowableArray<Node*> _data_entry;      // Nodes with all inputs from outside
 246   GrowableArray<Node*> _mem_slice_head;  // Memory slice head nodes
 247   GrowableArray<Node*> _mem_slice_tail;  // Memory slice tail nodes
 248 
 249   GrowableArray<SWNodeInfo> _node_info;  // Info needed per node
 250 
 251   MemNode* _align_to_ref;                // Memory reference that pre-loop will align to
 252 


< prev index next >