src/share/vm/opto/idealGraphPrinter.cpp

changeset 5539
adb9a7d94cb5
parent 5509
d1034bd8cefc
child 5635
650868c062a9
     1.1 --- a/src/share/vm/opto/idealGraphPrinter.cpp	Thu Aug 15 11:59:19 2013 -0700
     1.2 +++ b/src/share/vm/opto/idealGraphPrinter.cpp	Fri Aug 16 10:23:55 2013 +0200
     1.3 @@ -416,7 +416,7 @@
     1.4      if (C->cfg() != NULL) {
     1.5        Block* block = C->cfg()->get_block_for_node(node);
     1.6        if (block == NULL) {
     1.7 -        print_prop("block", C->cfg()->_blocks[0]->_pre_order);
     1.8 +        print_prop("block", C->cfg()->get_block(0)->_pre_order);
     1.9        } else {
    1.10          print_prop("block", block->_pre_order);
    1.11        }
    1.12 @@ -637,10 +637,10 @@
    1.13    if (C->cfg() != NULL) {
    1.14      // once we have a CFG there are some nodes that aren't really
    1.15      // reachable but are in the CFG so add them here.
    1.16 -    for (uint i = 0; i < C->cfg()->_blocks.size(); i++) {
    1.17 -      Block *b = C->cfg()->_blocks[i];
    1.18 -      for (uint s = 0; s < b->_nodes.size(); s++) {
    1.19 -        nodeStack.push(b->_nodes[s]);
    1.20 +    for (uint i = 0; i < C->cfg()->number_of_blocks(); i++) {
    1.21 +      Block* block = C->cfg()->get_block(i);
    1.22 +      for (uint s = 0; s < block->_nodes.size(); s++) {
    1.23 +        nodeStack.push(block->_nodes[s]);
    1.24        }
    1.25      }
    1.26    }
    1.27 @@ -698,24 +698,24 @@
    1.28    tail(EDGES_ELEMENT);
    1.29    if (C->cfg() != NULL) {
    1.30      head(CONTROL_FLOW_ELEMENT);
    1.31 -    for (uint i = 0; i < C->cfg()->_blocks.size(); i++) {
    1.32 -      Block *b = C->cfg()->_blocks[i];
    1.33 +    for (uint i = 0; i < C->cfg()->number_of_blocks(); i++) {
    1.34 +      Block* block = C->cfg()->get_block(i);
    1.35        begin_head(BLOCK_ELEMENT);
    1.36 -      print_attr(BLOCK_NAME_PROPERTY, b->_pre_order);
    1.37 +      print_attr(BLOCK_NAME_PROPERTY, block->_pre_order);
    1.38        end_head();
    1.39  
    1.40        head(SUCCESSORS_ELEMENT);
    1.41 -      for (uint s = 0; s < b->_num_succs; s++) {
    1.42 +      for (uint s = 0; s < block->_num_succs; s++) {
    1.43          begin_elem(SUCCESSOR_ELEMENT);
    1.44 -        print_attr(BLOCK_NAME_PROPERTY, b->_succs[s]->_pre_order);
    1.45 +        print_attr(BLOCK_NAME_PROPERTY, block->_succs[s]->_pre_order);
    1.46          end_elem();
    1.47        }
    1.48        tail(SUCCESSORS_ELEMENT);
    1.49  
    1.50        head(NODES_ELEMENT);
    1.51 -      for (uint s = 0; s < b->_nodes.size(); s++) {
    1.52 +      for (uint s = 0; s < block->_nodes.size(); s++) {
    1.53          begin_elem(NODE_ELEMENT);
    1.54 -        print_attr(NODE_ID_PROPERTY, get_node_id(b->_nodes[s]));
    1.55 +        print_attr(NODE_ID_PROPERTY, get_node_id(block->_nodes[s]));
    1.56          end_elem();
    1.57        }
    1.58        tail(NODES_ELEMENT);

mercurial