Skip to content
This repository has been archived by the owner on Jul 17, 2024. It is now read-only.
/ jdk22u Public archive

Commit

Permalink
8329570: G1: Excessive is_obj_dead_cond calls in verification
Browse files Browse the repository at this point in the history
Backport-of: 29992e1fca4faef0fe0ac453c7e78db4628d5e70
  • Loading branch information
shipilev committed Apr 17, 2024
1 parent 5968567 commit 52915be
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/hotspot/share/gc/g1/heapRegion.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -588,7 +588,6 @@ class G1VerifyLiveAndRemSetClosure : public BasicOopIterateClosure {
template <class T>
void do_oop_work(T* p) {
assert(_containing_obj != nullptr, "must be");
assert(!G1CollectedHeap::heap()->is_obj_dead_cond(_containing_obj, _vo), "Precondition");

if (num_failures() >= G1MaxVerifyFailures) {
return;
Expand Down Expand Up @@ -620,6 +619,7 @@ class G1VerifyLiveAndRemSetClosure : public BasicOopIterateClosure {
_num_failures(0) { }

void set_containing_obj(oop const obj) {
assert(!G1CollectedHeap::heap()->is_obj_dead_cond(obj, _vo), "Precondition");
_containing_obj = obj;
}

Expand Down

1 comment on commit 52915be

@openjdk-notifier
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.