Print this page
rev 1839 : 6961690: load oops from constant table on SPARC
Summary: oops should be loaded from the constant table of an nmethod instead of materializing them with a long code sequence.
Reviewed-by:

Split Close
Expand all
Collapse all
          --- old/src/share/vm/opto/gcm.cpp
          +++ new/src/share/vm/opto/gcm.cpp
   1    1  /*
   2      - * Copyright (c) 1997, 2009, Oracle and/or its affiliates. All rights reserved.
        2 + * Copyright (c) 1997, 2010, Oracle and/or its affiliates. All rights reserved.
   3    3   * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
   4    4   *
   5    5   * This code is free software; you can redistribute it and/or modify it
   6    6   * under the terms of the GNU General Public License version 2 only, as
   7    7   * published by the Free Software Foundation.
   8    8   *
   9    9   * This code is distributed in the hope that it will be useful, but WITHOUT
  10   10   * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  11   11   * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
  12   12   * version 2 for more details (a copy is included in the LICENSE file that
↓ open down ↓ 46 lines elided ↑ open up ↑
  59   59  
  60   60  //----------------------------replace_block_proj_ctrl-------------------------
  61   61  // Nodes that have is_block_proj() nodes as their control need to use
  62   62  // the appropriate Region for their actual block as their control since
  63   63  // the projection will be in a predecessor block.
  64   64  void PhaseCFG::replace_block_proj_ctrl( Node *n ) {
  65   65    const Node *in0 = n->in(0);
  66   66    assert(in0 != NULL, "Only control-dependent");
  67   67    const Node *p = in0->is_block_proj();
  68   68    if (p != NULL && p != n) {    // Control from a block projection?
  69      -    assert(!n->pinned() || n->is_SafePointScalarObject(), "only SafePointScalarObject pinned node is expected here");
       69 +    assert(!n->pinned() || n->is_MachConstantBase() || n->is_SafePointScalarObject(), "only pinned MachConstantBase or SafePointScalarObject node is expected here");
  70   70      // Find trailing Region
  71   71      Block *pb = _bbs[in0->_idx]; // Block-projection already has basic block
  72   72      uint j = 0;
  73   73      if (pb->_num_succs != 1) {  // More then 1 successor?
  74   74        // Search for successor
  75   75        uint max = pb->_nodes.size();
  76   76        assert( max > 1, "" );
  77   77        uint start = max - pb->_num_succs;
  78   78        // Find which output path belongs to projection
  79   79        for (j = start; j < max; j++) {
↓ open down ↓ 1908 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX