8049420: Backout 8048248 to correct attribution

Reviewed-by: ehelin, brutisso
This commit is contained in:
Stefan Karlsson 2014-07-07 12:37:11 +02:00
parent 8c3aced316
commit ef1e9b3c80
75 changed files with 911 additions and 2206 deletions

View file

@ -42,7 +42,6 @@
#include "utilities/stack.hpp"
#include "utilities/macros.hpp"
#if INCLUDE_ALL_GCS
#include "gc_implementation/g1/g1SATBCardTableModRefBS.hpp"
#include "gc_implementation/parallelScavenge/psParallelCompact.hpp"
#include "gc_implementation/parallelScavenge/psPromotionManager.hpp"
#include "gc_implementation/parallelScavenge/psScavenge.hpp"
@ -160,12 +159,7 @@ Klass::Klass() {
_primary_supers[0] = k;
set_super_check_offset(in_bytes(primary_supers_offset()));
// The constructor is used from init_self_patching_vtbl_list,
// which doesn't zero out the memory before calling the constructor.
// Need to set the field explicitly to not hit an assert that the field
// should be NULL before setting it.
_java_mirror = NULL;
set_java_mirror(NULL);
set_modifier_flags(0);
set_layout_helper(Klass::_lh_neutral_value);
set_name(NULL);
@ -389,7 +383,7 @@ bool Klass::is_loader_alive(BoolObjectClosure* is_alive) {
return mirror_alive;
}
void Klass::clean_weak_klass_links(BoolObjectClosure* is_alive, bool clean_alive_klasses) {
void Klass::clean_weak_klass_links(BoolObjectClosure* is_alive) {
if (!ClassUnloading) {
return;
}
@ -434,7 +428,7 @@ void Klass::clean_weak_klass_links(BoolObjectClosure* is_alive, bool clean_alive
}
// Clean the implementors list and method data.
if (clean_alive_klasses && current->oop_is_instance()) {
if (current->oop_is_instance()) {
InstanceKlass* ik = InstanceKlass::cast(current);
ik->clean_implementors_list(is_alive);
ik->clean_method_data(is_alive);
@ -446,18 +440,12 @@ void Klass::klass_update_barrier_set(oop v) {
record_modified_oops();
}
// This barrier is used by G1 to remember the old oop values, so
// that we don't forget any objects that were live at the snapshot at
// the beginning. This function is only used when we write oops into Klasses.
void Klass::klass_update_barrier_set_pre(oop* p, oop v) {
#if INCLUDE_ALL_GCS
if (UseG1GC) {
oop obj = *p;
if (obj != NULL) {
G1SATBCardTableModRefBS::enqueue(obj);
}
}
#endif
void Klass::klass_update_barrier_set_pre(void* p, oop v) {
// This barrier used by G1, where it's used remember the old oop values,
// so that we don't forget any objects that were live at the snapshot at
// the beginning. This function is only used when we write oops into
// Klasses. Since the Klasses are used as roots in G1, we don't have to
// do anything here.
}
void Klass::klass_oop_store(oop* p, oop v) {
@ -468,7 +456,7 @@ void Klass::klass_oop_store(oop* p, oop v) {
if (always_do_update_barrier) {
klass_oop_store((volatile oop*)p, v);
} else {
klass_update_barrier_set_pre(p, v);
klass_update_barrier_set_pre((void*)p, v);
*p = v;
klass_update_barrier_set(v);
}
@ -478,7 +466,7 @@ void Klass::klass_oop_store(volatile oop* p, oop v) {
assert(!Universe::heap()->is_in_reserved((void*)p), "Should store pointer into metadata");
assert(v == NULL || Universe::heap()->is_in_reserved((void*)v), "Should store pointer to an object");
klass_update_barrier_set_pre((oop*)p, v); // Cast away volatile.
klass_update_barrier_set_pre((void*)p, v);
OrderAccess::release_store_ptr(p, v);
klass_update_barrier_set(v);
}