Print this page


Split Close
Expand all
Collapse all
          --- old/src/share/vm/oops/methodDataOop.hpp
          +++ new/src/share/vm/oops/methodDataOop.hpp
↓ open down ↓ 66 lines elided ↑ open up ↑
  67   67  // forward decl
  68   68  class ProfileData;
  69   69  
  70   70  // DataLayout
  71   71  //
  72   72  // Overlay for generic profiling data.
  73   73  class DataLayout VALUE_OBJ_CLASS_SPEC {
  74   74  private:
  75   75    // Every data layout begins with a header.  This header
  76   76    // contains a tag, which is used to indicate the size/layout
  77      -  // of the data, 4 bits of flags, which can be used in any way,
  78      -  // 4 bits of trap history (none/one reason/many reasons),
       77 +  // of the data, 3 bits of flags, which can be used in any way,
       78 +  // 5 bits of trap history (none/one reason/many reasons),
  79   79    // and a bci, which is used to tie this piece of data to a
  80   80    // specific bci in the bytecodes.
  81   81    union {
  82   82      intptr_t _bits;
  83   83      struct {
  84   84        u1 _tag;
  85   85        u1 _flags;
  86   86        u2 _bci;
  87   87      } _struct;
  88   88    } _header;
↓ open down ↓ 22 lines elided ↑ open up ↑
 111  111      jump_data_tag,
 112  112      receiver_type_data_tag,
 113  113      virtual_call_data_tag,
 114  114      ret_data_tag,
 115  115      branch_data_tag,
 116  116      multi_branch_data_tag,
 117  117      arg_info_data_tag
 118  118    };
 119  119  
 120  120    enum {
 121      -    // The _struct._flags word is formatted as [trap_state:4 | flags:4].
 122      -    // The trap state breaks down further as [recompile:1 | reason:3].
      121 +    // The _struct._flags word is formatted as [trap_state:5 | flags:3].
      122 +    // The trap state breaks down further as [recompile:1 | reason:4].
 123  123      // This further breakdown is defined in deoptimization.cpp.
 124  124      // See Deoptimization::trap_state_reason for an assert that
 125  125      // trap_bits is big enough to hold reasons < Reason_RECORDED_LIMIT.
 126  126      //
 127  127      // The trap_state is collected only if ProfileTraps is true.
 128      -    trap_bits = 1+3,  // 3: enough to distinguish [0..Reason_RECORDED_LIMIT].
      128 +    trap_bits = 1+4,  // 4: enough to distinguish [0..Reason_RECORDED_LIMIT].
 129  129      trap_shift = BitsPerByte - trap_bits,
 130  130      trap_mask = right_n_bits(trap_bits),
 131  131      trap_mask_in_place = (trap_mask << trap_shift),
 132  132      flag_limit = trap_shift,
 133  133      flag_mask = right_n_bits(flag_limit),
 134  134      first_flag = 0
 135  135    };
 136  136  
 137  137    // Size computation
 138  138    static int header_size_in_bytes() {
↓ open down ↓ 1388 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX