< prev index next >

src/hotspot/share/gc/shared/vmStructs_gc.hpp

Print this page




  20  * or visit www.oracle.com if you need additional information or have any
  21  * questions.
  22  *
  23  */
  24 
  25 #ifndef SHARE_GC_SHARED_VMSTRUCTS_GC_HPP
  26 #define SHARE_GC_SHARED_VMSTRUCTS_GC_HPP
  27 
  28 #include "gc/shared/ageTable.hpp"
  29 #include "gc/shared/cardGeneration.hpp"
  30 #include "gc/shared/cardTableRS.hpp"
  31 #include "gc/shared/collectedHeap.hpp"
  32 #include "gc/shared/genCollectedHeap.hpp"
  33 #include "gc/shared/generation.hpp"
  34 #include "gc/shared/generationSpec.hpp"
  35 #include "gc/shared/oopStorage.hpp"
  36 #include "gc/shared/space.hpp"
  37 #if INCLUDE_CMSGC
  38 #include "gc/cms/vmStructs_cms.hpp"
  39 #endif



  40 #if INCLUDE_G1GC
  41 #include "gc/g1/vmStructs_g1.hpp"
  42 #endif
  43 #if INCLUDE_PARALLELGC
  44 #include "gc/parallel/vmStructs_parallelgc.hpp"
  45 #endif
  46 #if INCLUDE_SERIALGC
  47 #include "gc/serial/defNewGeneration.hpp"
  48 #include "gc/serial/vmStructs_serial.hpp"
  49 #endif
  50 
  51 #define VM_STRUCTS_GC(nonstatic_field,                                                                                               \
  52                       volatile_nonstatic_field,                                                                                      \
  53                       static_field,                                                                                                  \
  54                       unchecked_nonstatic_field)                                                                                     \
  55   CMSGC_ONLY(VM_STRUCTS_CMSGC(nonstatic_field,                                                                                       \
  56                               volatile_nonstatic_field,                                                                              \
  57                               static_field))                                                                                         \



  58   G1GC_ONLY(VM_STRUCTS_G1GC(nonstatic_field,                                                                                         \
  59                             volatile_nonstatic_field,                                                                                \
  60                             static_field))                                                                                           \
  61   PARALLELGC_ONLY(VM_STRUCTS_PARALLELGC(nonstatic_field,                                                                             \
  62                                         volatile_nonstatic_field,                                                                    \
  63                                         static_field))                                                                               \
  64   SERIALGC_ONLY(VM_STRUCTS_SERIALGC(nonstatic_field,                                                                                 \
  65                                     volatile_nonstatic_field,                                                                        \
  66                                     static_field))                                                                                   \
  67   /**********************************************************************************/                                               \
  68   /* Generation and Space hierarchies                                               */                                               \
  69   /**********************************************************************************/                                               \
  70                                                                                                                                      \
  71   unchecked_nonstatic_field(AgeTable,          sizes,                                         sizeof(AgeTable::sizes))               \
  72                                                                                                                                      \
  73   nonstatic_field(BarrierSet,                  _fake_rtti,                                    BarrierSet::FakeRtti)                  \
  74                                                                                                                                      \
  75   nonstatic_field(BarrierSet::FakeRtti,        _concrete_tag,                                 BarrierSet::Name)                      \
  76                                                                                                                                      \
  77   nonstatic_field(BlockOffsetTable,            _bottom,                                       HeapWord*)                             \


 136   nonstatic_field(GenCollectedHeap,            _old_gen,                                      Generation*)                           \
 137   nonstatic_field(GenCollectedHeap,            _young_gen_spec,                               GenerationSpec*)                       \
 138   nonstatic_field(GenCollectedHeap,            _old_gen_spec,                                 GenerationSpec*)                       \
 139                                                                                                                                      \
 140   nonstatic_field(HeapWord,                    i,                                             char*)                                 \
 141                                                                                                                                      \
 142   nonstatic_field(MemRegion,                   _start,                                        HeapWord*)                             \
 143   nonstatic_field(MemRegion,                   _word_size,                                    size_t)                                \
 144                                                                                                                                      \
 145   nonstatic_field(OffsetTableContigSpace,      _offsets,                                      BlockOffsetArray)                      \
 146                                                                                                                                      \
 147   nonstatic_field(Space,                       _bottom,                                       HeapWord*)                             \
 148   nonstatic_field(Space,                       _end,                                          HeapWord*)
 149 
 150 #define VM_TYPES_GC(declare_type,                                         \
 151                     declare_toplevel_type,                                \
 152                     declare_integer_type)                                 \
 153   CMSGC_ONLY(VM_TYPES_CMSGC(declare_type,                                 \
 154                             declare_toplevel_type,                        \
 155                             declare_integer_type))                        \



 156   G1GC_ONLY(VM_TYPES_G1GC(declare_type,                                   \
 157                           declare_toplevel_type,                          \
 158                           declare_integer_type))                          \
 159   PARALLELGC_ONLY(VM_TYPES_PARALLELGC(declare_type,                       \
 160                                       declare_toplevel_type,              \
 161                                       declare_integer_type))              \
 162   SERIALGC_ONLY(VM_TYPES_SERIALGC(declare_type,                           \
 163                                   declare_toplevel_type,                  \
 164                                   declare_integer_type))                  \
 165   /******************************************/                            \
 166   /* Generation and space hierarchies       */                            \
 167   /* (needed for run-time type information) */                            \
 168   /******************************************/                            \
 169                                                                           \
 170   declare_toplevel_type(CollectedHeap)                                    \
 171            declare_type(GenCollectedHeap,             CollectedHeap)      \
 172   declare_toplevel_type(Generation)                                       \
 173            declare_type(CardGeneration,               Generation)         \
 174   declare_toplevel_type(Space)                                            \
 175            declare_type(CompactibleSpace,             Space)              \


 208   declare_toplevel_type(CardTableBarrierSet**)                            \
 209   declare_toplevel_type(CollectedHeap*)                                   \
 210   declare_toplevel_type(ContiguousSpace*)                                 \
 211   declare_toplevel_type(DefNewGeneration*)                                \
 212   declare_toplevel_type(GenCollectedHeap*)                                \
 213   declare_toplevel_type(Generation*)                                      \
 214   declare_toplevel_type(GenerationSpec**)                                 \
 215   declare_toplevel_type(HeapWord*)                                        \
 216   declare_toplevel_type(HeapWord* volatile)                               \
 217   declare_toplevel_type(MemRegion*)                                       \
 218   declare_toplevel_type(OffsetTableContigSpace*)                          \
 219   declare_toplevel_type(Space*)                                           \
 220   declare_toplevel_type(ThreadLocalAllocBuffer*)                          \
 221                                                                           \
 222   declare_toplevel_type(BarrierSet::FakeRtti)
 223 
 224 #define VM_INT_CONSTANTS_GC(declare_constant,                               \
 225                             declare_constant_with_value)                    \
 226   CMSGC_ONLY(VM_INT_CONSTANTS_CMSGC(declare_constant,                       \
 227                                     declare_constant_with_value))           \


 228   G1GC_ONLY(VM_INT_CONSTANTS_G1GC(declare_constant,                         \
 229                                   declare_constant_with_value))             \
 230   PARALLELGC_ONLY(VM_INT_CONSTANTS_PARALLELGC(declare_constant,             \
 231                                               declare_constant_with_value)) \
 232   SERIALGC_ONLY(VM_INT_CONSTANTS_SERIALGC(declare_constant,                 \
 233                                           declare_constant_with_value))     \
 234                                                                             \
 235   /********************************************/                            \
 236   /* Generation and Space Hierarchy Constants */                            \
 237   /********************************************/                            \
 238                                                                             \
 239   declare_constant(AgeTable::table_size)                                    \
 240                                                                             \
 241   declare_constant(BarrierSet::ModRef)                                      \
 242   declare_constant(BarrierSet::CardTableBarrierSet)                         \
 243                                                                             \
 244   declare_constant(BOTConstants::LogN)                                      \
 245   declare_constant(BOTConstants::LogN_words)                                \
 246   declare_constant(BOTConstants::N_bytes)                                   \
 247   declare_constant(BOTConstants::N_words)                                   \




  20  * or visit www.oracle.com if you need additional information or have any
  21  * questions.
  22  *
  23  */
  24 
  25 #ifndef SHARE_GC_SHARED_VMSTRUCTS_GC_HPP
  26 #define SHARE_GC_SHARED_VMSTRUCTS_GC_HPP
  27 
  28 #include "gc/shared/ageTable.hpp"
  29 #include "gc/shared/cardGeneration.hpp"
  30 #include "gc/shared/cardTableRS.hpp"
  31 #include "gc/shared/collectedHeap.hpp"
  32 #include "gc/shared/genCollectedHeap.hpp"
  33 #include "gc/shared/generation.hpp"
  34 #include "gc/shared/generationSpec.hpp"
  35 #include "gc/shared/oopStorage.hpp"
  36 #include "gc/shared/space.hpp"
  37 #if INCLUDE_CMSGC
  38 #include "gc/cms/vmStructs_cms.hpp"
  39 #endif
  40 #if INCLUDE_EPSILONGC
  41 #include "gc/epsilon/vmStructs_epsilon.hpp"
  42 #endif
  43 #if INCLUDE_G1GC
  44 #include "gc/g1/vmStructs_g1.hpp"
  45 #endif
  46 #if INCLUDE_PARALLELGC
  47 #include "gc/parallel/vmStructs_parallelgc.hpp"
  48 #endif
  49 #if INCLUDE_SERIALGC
  50 #include "gc/serial/defNewGeneration.hpp"
  51 #include "gc/serial/vmStructs_serial.hpp"
  52 #endif
  53 
  54 #define VM_STRUCTS_GC(nonstatic_field,                                                                                               \
  55                       volatile_nonstatic_field,                                                                                      \
  56                       static_field,                                                                                                  \
  57                       unchecked_nonstatic_field)                                                                                     \
  58   CMSGC_ONLY(VM_STRUCTS_CMSGC(nonstatic_field,                                                                                       \
  59                               volatile_nonstatic_field,                                                                              \
  60                               static_field))                                                                                         \
  61   EPSILONGC_ONLY(VM_STRUCTS_EPSILONGC(nonstatic_field,                                                                               \
  62                                       volatile_nonstatic_field,                                                                      \
  63                                       static_field))                                                                                 \
  64   G1GC_ONLY(VM_STRUCTS_G1GC(nonstatic_field,                                                                                         \
  65                             volatile_nonstatic_field,                                                                                \
  66                             static_field))                                                                                           \
  67   PARALLELGC_ONLY(VM_STRUCTS_PARALLELGC(nonstatic_field,                                                                             \
  68                                         volatile_nonstatic_field,                                                                    \
  69                                         static_field))                                                                               \
  70   SERIALGC_ONLY(VM_STRUCTS_SERIALGC(nonstatic_field,                                                                                 \
  71                                     volatile_nonstatic_field,                                                                        \
  72                                     static_field))                                                                                   \
  73   /**********************************************************************************/                                               \
  74   /* Generation and Space hierarchies                                               */                                               \
  75   /**********************************************************************************/                                               \
  76                                                                                                                                      \
  77   unchecked_nonstatic_field(AgeTable,          sizes,                                         sizeof(AgeTable::sizes))               \
  78                                                                                                                                      \
  79   nonstatic_field(BarrierSet,                  _fake_rtti,                                    BarrierSet::FakeRtti)                  \
  80                                                                                                                                      \
  81   nonstatic_field(BarrierSet::FakeRtti,        _concrete_tag,                                 BarrierSet::Name)                      \
  82                                                                                                                                      \
  83   nonstatic_field(BlockOffsetTable,            _bottom,                                       HeapWord*)                             \


 142   nonstatic_field(GenCollectedHeap,            _old_gen,                                      Generation*)                           \
 143   nonstatic_field(GenCollectedHeap,            _young_gen_spec,                               GenerationSpec*)                       \
 144   nonstatic_field(GenCollectedHeap,            _old_gen_spec,                                 GenerationSpec*)                       \
 145                                                                                                                                      \
 146   nonstatic_field(HeapWord,                    i,                                             char*)                                 \
 147                                                                                                                                      \
 148   nonstatic_field(MemRegion,                   _start,                                        HeapWord*)                             \
 149   nonstatic_field(MemRegion,                   _word_size,                                    size_t)                                \
 150                                                                                                                                      \
 151   nonstatic_field(OffsetTableContigSpace,      _offsets,                                      BlockOffsetArray)                      \
 152                                                                                                                                      \
 153   nonstatic_field(Space,                       _bottom,                                       HeapWord*)                             \
 154   nonstatic_field(Space,                       _end,                                          HeapWord*)
 155 
 156 #define VM_TYPES_GC(declare_type,                                         \
 157                     declare_toplevel_type,                                \
 158                     declare_integer_type)                                 \
 159   CMSGC_ONLY(VM_TYPES_CMSGC(declare_type,                                 \
 160                             declare_toplevel_type,                        \
 161                             declare_integer_type))                        \
 162   EPSILONGC_ONLY(VM_TYPES_EPSILONGC(declare_type,                         \
 163                                     declare_toplevel_type,                \
 164                                     declare_integer_type))                \
 165   G1GC_ONLY(VM_TYPES_G1GC(declare_type,                                   \
 166                           declare_toplevel_type,                          \
 167                           declare_integer_type))                          \
 168   PARALLELGC_ONLY(VM_TYPES_PARALLELGC(declare_type,                       \
 169                                       declare_toplevel_type,              \
 170                                       declare_integer_type))              \
 171   SERIALGC_ONLY(VM_TYPES_SERIALGC(declare_type,                           \
 172                                   declare_toplevel_type,                  \
 173                                   declare_integer_type))                  \
 174   /******************************************/                            \
 175   /* Generation and space hierarchies       */                            \
 176   /* (needed for run-time type information) */                            \
 177   /******************************************/                            \
 178                                                                           \
 179   declare_toplevel_type(CollectedHeap)                                    \
 180            declare_type(GenCollectedHeap,             CollectedHeap)      \
 181   declare_toplevel_type(Generation)                                       \
 182            declare_type(CardGeneration,               Generation)         \
 183   declare_toplevel_type(Space)                                            \
 184            declare_type(CompactibleSpace,             Space)              \


 217   declare_toplevel_type(CardTableBarrierSet**)                            \
 218   declare_toplevel_type(CollectedHeap*)                                   \
 219   declare_toplevel_type(ContiguousSpace*)                                 \
 220   declare_toplevel_type(DefNewGeneration*)                                \
 221   declare_toplevel_type(GenCollectedHeap*)                                \
 222   declare_toplevel_type(Generation*)                                      \
 223   declare_toplevel_type(GenerationSpec**)                                 \
 224   declare_toplevel_type(HeapWord*)                                        \
 225   declare_toplevel_type(HeapWord* volatile)                               \
 226   declare_toplevel_type(MemRegion*)                                       \
 227   declare_toplevel_type(OffsetTableContigSpace*)                          \
 228   declare_toplevel_type(Space*)                                           \
 229   declare_toplevel_type(ThreadLocalAllocBuffer*)                          \
 230                                                                           \
 231   declare_toplevel_type(BarrierSet::FakeRtti)
 232 
 233 #define VM_INT_CONSTANTS_GC(declare_constant,                               \
 234                             declare_constant_with_value)                    \
 235   CMSGC_ONLY(VM_INT_CONSTANTS_CMSGC(declare_constant,                       \
 236                                     declare_constant_with_value))           \
 237   EPSILONGC_ONLY(VM_INT_CONSTANTS_EPSILONGC(declare_constant,               \
 238                                             declare_constant_with_value))   \
 239   G1GC_ONLY(VM_INT_CONSTANTS_G1GC(declare_constant,                         \
 240                                   declare_constant_with_value))             \
 241   PARALLELGC_ONLY(VM_INT_CONSTANTS_PARALLELGC(declare_constant,             \
 242                                               declare_constant_with_value)) \
 243   SERIALGC_ONLY(VM_INT_CONSTANTS_SERIALGC(declare_constant,                 \
 244                                           declare_constant_with_value))     \
 245                                                                             \
 246   /********************************************/                            \
 247   /* Generation and Space Hierarchy Constants */                            \
 248   /********************************************/                            \
 249                                                                             \
 250   declare_constant(AgeTable::table_size)                                    \
 251                                                                             \
 252   declare_constant(BarrierSet::ModRef)                                      \
 253   declare_constant(BarrierSet::CardTableBarrierSet)                         \
 254                                                                             \
 255   declare_constant(BOTConstants::LogN)                                      \
 256   declare_constant(BOTConstants::LogN_words)                                \
 257   declare_constant(BOTConstants::N_bytes)                                   \
 258   declare_constant(BOTConstants::N_words)                                   \


< prev index next >