< prev index next >

src/hotspot/share/memory/universe.hpp

Print this page




 131   static oop          _main_thread_group;             // Reference to the main thread group object
 132   static oop          _system_thread_group;           // Reference to the system thread group object
 133 
 134   static objArrayOop  _the_empty_class_klass_array;   // Canonicalized obj array of type java.lang.Class
 135   static oop          _the_null_sentinel;             // A unique object pointer unused except as a sentinel for null.
 136   static oop          _the_null_string;               // A cache of "null" as a Java string
 137   static oop          _the_min_jint_string;          // A cache of "-2147483648" as a Java string
 138   static LatestMethodCache* _finalizer_register_cache; // static method for registering finalizable objects
 139   static LatestMethodCache* _loader_addClass_cache;    // method for registering loaded classes in class loader vector
 140   static LatestMethodCache* _pd_implies_cache;         // method for checking protection domain attributes
 141   static LatestMethodCache* _throw_illegal_access_error_cache; // Unsafe.throwIllegalAccessError() method
 142   static LatestMethodCache* _do_stack_walk_cache;      // method for stack walker callback
 143 
 144   // preallocated error objects (no backtrace)
 145   static oop          _out_of_memory_error_java_heap;
 146   static oop          _out_of_memory_error_metaspace;
 147   static oop          _out_of_memory_error_class_metaspace;
 148   static oop          _out_of_memory_error_array_size;
 149   static oop          _out_of_memory_error_gc_overhead_limit;
 150   static oop          _out_of_memory_error_realloc_objects;

 151 
 152   // preallocated cause message for delayed StackOverflowError
 153   static oop          _delayed_stack_overflow_error_message;
 154 
 155   static Array<int>*            _the_empty_int_array;            // Canonicalized int array
 156   static Array<u2>*             _the_empty_short_array;          // Canonicalized short array
 157   static Array<Klass*>*         _the_empty_klass_array;          // Canonicalized klass array
 158   static Array<InstanceKlass*>* _the_empty_instance_klass_array; // Canonicalized instance klass array
 159   static Array<Method*>*        _the_empty_method_array;         // Canonicalized method array
 160 
 161   static Array<Klass*>*  _the_array_interfaces_array;
 162 
 163   // array of preallocated error objects with backtrace
 164   static objArrayOop   _preallocated_out_of_memory_error_array;
 165 
 166   // number of preallocated error objects available for use
 167   static volatile jint _preallocated_out_of_memory_error_avail_count;
 168 
 169   static oop          _null_ptr_exception_instance;   // preallocated exception object
 170   static oop          _arithmetic_exception_instance; // preallocated exception object


 346   static oop          reference_pending_list();
 347   static void         set_reference_pending_list(oop list);
 348   static bool         has_reference_pending_list();
 349   static oop          swap_reference_pending_list(oop list);
 350 
 351   static Array<int>*             the_empty_int_array()    { return _the_empty_int_array; }
 352   static Array<u2>*              the_empty_short_array()  { return _the_empty_short_array; }
 353   static Array<Method*>*         the_empty_method_array() { return _the_empty_method_array; }
 354   static Array<Klass*>*          the_empty_klass_array()  { return _the_empty_klass_array; }
 355   static Array<InstanceKlass*>*  the_empty_instance_klass_array() { return _the_empty_instance_klass_array; }
 356 
 357   // OutOfMemoryError support. Returns an error with the required message. The returned error
 358   // may or may not have a backtrace. If error has a backtrace then the stack trace is already
 359   // filled in.
 360   static oop out_of_memory_error_java_heap()          { return gen_out_of_memory_error(_out_of_memory_error_java_heap);  }
 361   static oop out_of_memory_error_metaspace()          { return gen_out_of_memory_error(_out_of_memory_error_metaspace);   }
 362   static oop out_of_memory_error_class_metaspace()    { return gen_out_of_memory_error(_out_of_memory_error_class_metaspace);   }
 363   static oop out_of_memory_error_array_size()         { return gen_out_of_memory_error(_out_of_memory_error_array_size); }
 364   static oop out_of_memory_error_gc_overhead_limit()  { return gen_out_of_memory_error(_out_of_memory_error_gc_overhead_limit);  }
 365   static oop out_of_memory_error_realloc_objects()    { return gen_out_of_memory_error(_out_of_memory_error_realloc_objects);  }


 366   static oop delayed_stack_overflow_error_message()   { return _delayed_stack_overflow_error_message; }
 367 
 368   // The particular choice of collected heap.
 369   static CollectedHeap* heap() { return _collectedHeap; }
 370 
 371   // For UseCompressedOops
 372   // Narrow Oop encoding mode:
 373   // 0 - Use 32-bits oops without encoding when
 374   //     NarrowOopHeapBaseMin + heap_size < 4Gb
 375   // 1 - Use zero based compressed oops with encoding when
 376   //     NarrowOopHeapBaseMin + heap_size < 32Gb
 377   // 2 - Use compressed oops with disjoint heap base if
 378   //     base is 32G-aligned and base > 0. This allows certain
 379   //     optimizations in encoding/decoding.
 380   //     Disjoint: Bits used in base are disjoint from bits used
 381   //     for oops ==> oop = (cOop << 3) | base.  One can disjoint
 382   //     the bits of an oop into base and compressed oop.
 383   // 3 - Use compressed oops with heap base + encoding.
 384   enum NARROW_OOP_MODE {
 385     UnscaledNarrowOop  = 0,




 131   static oop          _main_thread_group;             // Reference to the main thread group object
 132   static oop          _system_thread_group;           // Reference to the system thread group object
 133 
 134   static objArrayOop  _the_empty_class_klass_array;   // Canonicalized obj array of type java.lang.Class
 135   static oop          _the_null_sentinel;             // A unique object pointer unused except as a sentinel for null.
 136   static oop          _the_null_string;               // A cache of "null" as a Java string
 137   static oop          _the_min_jint_string;          // A cache of "-2147483648" as a Java string
 138   static LatestMethodCache* _finalizer_register_cache; // static method for registering finalizable objects
 139   static LatestMethodCache* _loader_addClass_cache;    // method for registering loaded classes in class loader vector
 140   static LatestMethodCache* _pd_implies_cache;         // method for checking protection domain attributes
 141   static LatestMethodCache* _throw_illegal_access_error_cache; // Unsafe.throwIllegalAccessError() method
 142   static LatestMethodCache* _do_stack_walk_cache;      // method for stack walker callback
 143 
 144   // preallocated error objects (no backtrace)
 145   static oop          _out_of_memory_error_java_heap;
 146   static oop          _out_of_memory_error_metaspace;
 147   static oop          _out_of_memory_error_class_metaspace;
 148   static oop          _out_of_memory_error_array_size;
 149   static oop          _out_of_memory_error_gc_overhead_limit;
 150   static oop          _out_of_memory_error_realloc_objects;
 151   static oop          _out_of_memory_error_retry;
 152 
 153   // preallocated cause message for delayed StackOverflowError
 154   static oop          _delayed_stack_overflow_error_message;
 155 
 156   static Array<int>*            _the_empty_int_array;            // Canonicalized int array
 157   static Array<u2>*             _the_empty_short_array;          // Canonicalized short array
 158   static Array<Klass*>*         _the_empty_klass_array;          // Canonicalized klass array
 159   static Array<InstanceKlass*>* _the_empty_instance_klass_array; // Canonicalized instance klass array
 160   static Array<Method*>*        _the_empty_method_array;         // Canonicalized method array
 161 
 162   static Array<Klass*>*  _the_array_interfaces_array;
 163 
 164   // array of preallocated error objects with backtrace
 165   static objArrayOop   _preallocated_out_of_memory_error_array;
 166 
 167   // number of preallocated error objects available for use
 168   static volatile jint _preallocated_out_of_memory_error_avail_count;
 169 
 170   static oop          _null_ptr_exception_instance;   // preallocated exception object
 171   static oop          _arithmetic_exception_instance; // preallocated exception object


 347   static oop          reference_pending_list();
 348   static void         set_reference_pending_list(oop list);
 349   static bool         has_reference_pending_list();
 350   static oop          swap_reference_pending_list(oop list);
 351 
 352   static Array<int>*             the_empty_int_array()    { return _the_empty_int_array; }
 353   static Array<u2>*              the_empty_short_array()  { return _the_empty_short_array; }
 354   static Array<Method*>*         the_empty_method_array() { return _the_empty_method_array; }
 355   static Array<Klass*>*          the_empty_klass_array()  { return _the_empty_klass_array; }
 356   static Array<InstanceKlass*>*  the_empty_instance_klass_array() { return _the_empty_instance_klass_array; }
 357 
 358   // OutOfMemoryError support. Returns an error with the required message. The returned error
 359   // may or may not have a backtrace. If error has a backtrace then the stack trace is already
 360   // filled in.
 361   static oop out_of_memory_error_java_heap()          { return gen_out_of_memory_error(_out_of_memory_error_java_heap);  }
 362   static oop out_of_memory_error_metaspace()          { return gen_out_of_memory_error(_out_of_memory_error_metaspace);   }
 363   static oop out_of_memory_error_class_metaspace()    { return gen_out_of_memory_error(_out_of_memory_error_class_metaspace);   }
 364   static oop out_of_memory_error_array_size()         { return gen_out_of_memory_error(_out_of_memory_error_array_size); }
 365   static oop out_of_memory_error_gc_overhead_limit()  { return gen_out_of_memory_error(_out_of_memory_error_gc_overhead_limit);  }
 366   static oop out_of_memory_error_realloc_objects()    { return gen_out_of_memory_error(_out_of_memory_error_realloc_objects);  }
 367   // Throw default _out_of_memory_error_retry object as it will never propagate out of the VM
 368   static oop out_of_memory_error_retry()              { return _out_of_memory_error_retry;  }
 369   static oop delayed_stack_overflow_error_message()   { return _delayed_stack_overflow_error_message; }
 370 
 371   // The particular choice of collected heap.
 372   static CollectedHeap* heap() { return _collectedHeap; }
 373 
 374   // For UseCompressedOops
 375   // Narrow Oop encoding mode:
 376   // 0 - Use 32-bits oops without encoding when
 377   //     NarrowOopHeapBaseMin + heap_size < 4Gb
 378   // 1 - Use zero based compressed oops with encoding when
 379   //     NarrowOopHeapBaseMin + heap_size < 32Gb
 380   // 2 - Use compressed oops with disjoint heap base if
 381   //     base is 32G-aligned and base > 0. This allows certain
 382   //     optimizations in encoding/decoding.
 383   //     Disjoint: Bits used in base are disjoint from bits used
 384   //     for oops ==> oop = (cOop << 3) | base.  One can disjoint
 385   //     the bits of an oop into base and compressed oop.
 386   // 3 - Use compressed oops with heap base + encoding.
 387   enum NARROW_OOP_MODE {
 388     UnscaledNarrowOop  = 0,


< prev index next >