src/hotspot/share/opto/idealGraphPrinter.cpp
changeset 55307 ed12027517c0
parent 49026 844bf1deff1a
child 58962 2dcfc28a314d
equal deleted inserted replaced
55306:ea43db53de91 55307:ed12027517c0
   348   tail(GROUP_ELEMENT);
   348   tail(GROUP_ELEMENT);
   349   _current_method = NULL;
   349   _current_method = NULL;
   350   _xml->flush();
   350   _xml->flush();
   351 }
   351 }
   352 
   352 
   353 // Print indent
       
   354 void IdealGraphPrinter::print_indent() {
       
   355   tty->print_cr("printing indent %d", _depth);
       
   356   for (int i = 0; i < _depth; i++) {
       
   357     _xml->print("%s", INDENT);
       
   358   }
       
   359 }
       
   360 
       
   361 bool IdealGraphPrinter::traverse_outs() {
   353 bool IdealGraphPrinter::traverse_outs() {
   362   return _traverse_outs;
   354   return _traverse_outs;
   363 }
   355 }
   364 
   356 
   365 void IdealGraphPrinter::set_traverse_outs(bool b) {
   357 void IdealGraphPrinter::set_traverse_outs(bool b) {
   661       }
   653       }
   662     }
   654     }
   663   }
   655   }
   664 }
   656 }
   665 
   657 
   666 void IdealGraphPrinter::print_method(const char *name, int level, bool clear_nodes) {
   658 void IdealGraphPrinter::print_method(const char *name, int level) {
   667   print(name, (Node *)C->root(), level, clear_nodes);
   659   if (should_print(level)) {
       
   660     print(name, (Node *) C->root());
       
   661   }
   668 }
   662 }
   669 
   663 
   670 // Print current ideal graph
   664 // Print current ideal graph
   671 void IdealGraphPrinter::print(const char *name, Node *node, int level, bool clear_nodes) {
   665 void IdealGraphPrinter::print(const char *name, Node *node) {
   672 
   666 
   673   if (!_current_method || !_should_send_method || !should_print(level)) return;
   667   if (!_current_method || !_should_send_method) return;
   674 
   668 
   675   // Warning, unsafe cast?
   669   // Warning, unsafe cast?
   676   _chaitin = (PhaseChaitin *)C->regalloc();
   670   _chaitin = (PhaseChaitin *)C->regalloc();
   677 
   671 
   678   begin_head(GRAPH_ELEMENT);
   672   begin_head(GRAPH_ELEMENT);