src/share/vm/gc_implementation/g1/g1BlockOffsetTable.hpp

changeset 9697
cfe3264deba4
parent 7257
e7d0505c8a30
child 9703
2fdf635bcf28
equal deleted inserted replaced
9695:17778f8991c8 9697:cfe3264deba4
143 // End of the current committed region. 143 // End of the current committed region.
144 HeapWord* _end; 144 HeapWord* _end;
145 145
146 // Array for keeping offsets for retrieving object start fast given an 146 // Array for keeping offsets for retrieving object start fast given an
147 // address. 147 // address.
148 u_char* _offset_array; // byte array keeping backwards offsets 148 volatile u_char* _offset_array; // byte array keeping backwards offsets
149 149
150 void check_offset(size_t offset, const char* msg) const { 150 void check_offset(size_t offset, const char* msg) const {
151 assert(offset <= N_words, 151 assert(offset <= N_words,
152 err_msg("%s - " 152 err_msg("%s - "
153 "offset: " SIZE_FORMAT ", N_words: " UINT32_FORMAT, 153 "offset: " SIZE_FORMAT ", N_words: " UINT32_FORMAT,
156 156
157 // Bounds checking accessors: 157 // Bounds checking accessors:
158 // For performance these have to devolve to array accesses in product builds. 158 // For performance these have to devolve to array accesses in product builds.
159 inline u_char offset_array(size_t index) const; 159 inline u_char offset_array(size_t index) const;
160 160
161 void set_offset_array_raw(size_t index, u_char offset) { 161 inline void set_offset_array_raw(size_t index, u_char offset);
162 _offset_array[index] = offset;
163 }
164 162
165 inline void set_offset_array(size_t index, u_char offset); 163 inline void set_offset_array(size_t index, u_char offset);
166 164
167 inline void set_offset_array(size_t index, HeapWord* high, HeapWord* low); 165 inline void set_offset_array(size_t index, HeapWord* high, HeapWord* low);
168 166

mercurial