8075401: Remove DiscoveredListIterator::update_discovered()
Summary: Remove unnecessary function
Reviewed-by: brutisso, jwilhelm, ecaspole
--- a/hotspot/src/share/vm/memory/referenceProcessor.cpp Tue Mar 31 11:34:35 2015 +0200
+++ b/hotspot/src/share/vm/memory/referenceProcessor.cpp Mon Mar 30 10:24:00 2015 -0400
@@ -676,7 +676,6 @@
ResourceMark rm;
DiscoveredListIterator iter(refs_list, keep_alive, is_alive);
while (iter.has_next()) {
- iter.update_discovered();
iter.load_ptrs(DEBUG_ONLY(false /* allow_null_referent */));
if (clear_referent) {
// NULL out referent pointer
@@ -693,8 +692,6 @@
assert(iter.obj()->is_oop(UseConcMarkSweepGC), "Adding a bad reference");
iter.next();
}
- // Remember to update the next pointer of the last ref.
- iter.update_discovered();
// Close the reachable set
complete_gc->do_void();
}
--- a/hotspot/src/share/vm/memory/referenceProcessor.hpp Tue Mar 31 11:34:35 2015 +0200
+++ b/hotspot/src/share/vm/memory/referenceProcessor.hpp Mon Mar 30 10:24:00 2015 -0400
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2001, 2013, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2001, 2015, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -173,20 +173,6 @@
}
}
- // Update the discovered field.
- inline void update_discovered() {
- // First _prev_next ref actually points into DiscoveredList (gross).
- if (UseCompressedOops) {
- if (!oopDesc::is_null(*(narrowOop*)_prev_next)) {
- _keep_alive->do_oop((narrowOop*)_prev_next);
- }
- } else {
- if (!oopDesc::is_null(*(oop*)_prev_next)) {
- _keep_alive->do_oop((oop*)_prev_next);
- }
- }
- }
-
// NULL out referent pointer.
void clear_referent();