< prev index next >
src/hotspot/share/gc/parallel/psScavenge.cpp
Print this page
*** 45,54 ****
--- 45,56 ----
#include "gc/shared/referenceProcessor.hpp"
#include "gc/shared/spaceDecorator.hpp"
#include "gc/shared/weakProcessor.hpp"
#include "memory/resourceArea.hpp"
#include "logging/log.hpp"
+ #include "oops/access.inline.hpp"
+ #include "oops/compressedOops.inline.hpp"
#include "oops/oop.inline.hpp"
#include "runtime/biasedLocking.hpp"
#include "runtime/handles.inline.hpp"
#include "runtime/threadCritical.hpp"
#include "runtime/vmThread.hpp"
*** 91,102 ****
assert(_promotion_manager != NULL, "Sanity");
}
template <class T> void do_oop_work(T* p) {
! assert (!oopDesc::is_null(*p), "expected non-null ref");
! assert (oopDesc::is_oop(oopDesc::load_decode_heap_oop_not_null(p)),
"expected an oop while scanning weak refs");
// Weak refs may be visited more than once.
if (PSScavenge::should_scavenge(p, _to_space)) {
_promotion_manager->copy_and_push_safe_barrier<T, /*promote_immediately=*/false>(p);
--- 93,103 ----
assert(_promotion_manager != NULL, "Sanity");
}
template <class T> void do_oop_work(T* p) {
! assert (oopDesc::is_oop(RawAccess<OOP_NOT_NULL>::oop_load(p)),
"expected an oop while scanning weak refs");
// Weak refs may be visited more than once.
if (PSScavenge::should_scavenge(p, _to_space)) {
_promotion_manager->copy_and_push_safe_barrier<T, /*promote_immediately=*/false>(p);
*** 736,746 ****
// Adaptive size policy support. When the young generation/old generation
// boundary moves, _young_generation_boundary must be reset
void PSScavenge::set_young_generation_boundary(HeapWord* v) {
_young_generation_boundary = v;
if (UseCompressedOops) {
! _young_generation_boundary_compressed = (uintptr_t)oopDesc::encode_heap_oop((oop)v);
}
}
void PSScavenge::initialize() {
// Arguments must have been parsed
--- 737,747 ----
// Adaptive size policy support. When the young generation/old generation
// boundary moves, _young_generation_boundary must be reset
void PSScavenge::set_young_generation_boundary(HeapWord* v) {
_young_generation_boundary = v;
if (UseCompressedOops) {
! _young_generation_boundary_compressed = (uintptr_t)CompressedOops::encode((oop)v);
}
}
void PSScavenge::initialize() {
// Arguments must have been parsed
< prev index next >