comparison src/share/vm/classfile/javaClasses.cpp @ 1091:6aa7255741f3

6906727: UseCompressedOops: some card-marking fixes related to object arrays Summary: Introduced a new write_ref_array(HeapWords* start, size_t count) method that does the requisite MemRegion range calculation so (some of the) clients of the erstwhile write_ref_array(MemRegion mr) do not need to worry. This removed all external uses of array_size(), which was also simplified and made private. Asserts were added to catch other possible issues. Further, less essential, fixes stemming from this investigation are deferred to CR 6904516 (to follow shortly in hs17). Reviewed-by: kvn, coleenp, jmasa
author ysr
date Thu, 03 Dec 2009 15:01:57 -0800
parents 489a4f8dcd0f
children 84a2da7f454c
comparison
equal deleted inserted replaced
1090:fa357420e7d2 1091:6aa7255741f3
1122 1122
1123 void flush() { 1123 void flush() {
1124 if (_dirty && _methods != NULL) { 1124 if (_dirty && _methods != NULL) {
1125 BarrierSet* bs = Universe::heap()->barrier_set(); 1125 BarrierSet* bs = Universe::heap()->barrier_set();
1126 assert(bs->has_write_ref_array_opt(), "Barrier set must have ref array opt"); 1126 assert(bs->has_write_ref_array_opt(), "Barrier set must have ref array opt");
1127 bs->write_ref_array(MemRegion((HeapWord*)_methods->base(), 1127 bs->write_ref_array((HeapWord*)_methods->base(), _methods->length());
1128 _methods->array_size()));
1129 _dirty = false; 1128 _dirty = false;
1130 } 1129 }
1131 } 1130 }
1132 1131
1133 void expand(TRAPS) { 1132 void expand(TRAPS) {