src/share/vm/memory/space.cpp
Print this page
rev 7084 : [mq]: demacro
@@ -436,21 +436,12 @@
allowed_deadspace_words = 0;
return false;
}
}
-#define block_is_always_obj(q) true
-#define obj_size(q) oop(q)->size()
-#define adjust_obj_size(s) s
-
-void CompactibleSpace::prepare_for_compaction(CompactPoint* cp) {
- SCAN_AND_FORWARD(cp, end, block_is_obj, block_size);
-}
-
-// Faster object search.
void ContiguousSpace::prepare_for_compaction(CompactPoint* cp) {
- SCAN_AND_FORWARD(cp, top, block_is_always_obj, obj_size);
+ scan_and_forward(this, cp);
}
void Space::adjust_pointers() {
// adjust all the interior pointers to point at the new locations of objects
// Used by MarkSweep::mark_sweep_phase3()
@@ -490,15 +481,15 @@
// Check first is there is any work to do.
if (used() == 0) {
return; // Nothing to do.
}
- SCAN_AND_ADJUST_POINTERS(adjust_obj_size);
+ scan_and_adjust_pointers(this);
}
void CompactibleSpace::compact() {
- SCAN_AND_COMPACT(obj_size);
+ scan_and_compact(this);
}
void Space::print_short() const { print_short_on(tty); }
void Space::print_short_on(outputStream* st) const {