Skip to content
This repository has been archived by the owner on Feb 2, 2023. It is now read-only.
/ jdk13u-dev Public archive

Commit

Permalink
8264640: CMS ParScanClosure misses a barrier
Browse files Browse the repository at this point in the history
Reviewed-by: yan, johnc
  • Loading branch information
AntonKozlov committed Apr 9, 2021
1 parent f1e4e0b commit efc81a3
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/hotspot/share/gc/cms/parOopClosures.inline.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ template <class T> inline void ParScanWeakRefClosure::do_oop_work(T* p) {
// we need to ensure that it is copied (see comment in
// ParScanClosure::do_oop_work).
Klass* objK = obj->klass();
OrderAccess::loadload();
markOop m = obj->mark_raw();
oop new_obj;
if (m->is_marked()) { // Contains forwarding pointer.
Expand Down Expand Up @@ -108,6 +109,7 @@ inline void ParScanClosure::do_oop_work(T* p,
// overwritten with an overflow next pointer after the object is
// forwarded.
Klass* objK = obj->klass();
OrderAccess::loadload();
markOop m = obj->mark_raw();
oop new_obj;
if (m->is_marked()) { // Contains forwarding pointer.
Expand Down

1 comment on commit efc81a3

@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.