RFR: 8254239: G1ConcurrentMark.hpp unnecessarily disables MSVC++ warning 4522

Андрей Вершинин aver.shining at gmail.com
Thu Feb 18 01:42:28 UTC 2021


 Hello everybody,

My name is Andrey Vershinin, I've chosen to fix JDK-8254239 as my first
contribution to the project. I'm a Java developer, with some C++ knowledge
(in the process of improving it).
My goal is to gain a deeper understanding of the inner workings of the
platform I'm interested in, its concepts and the code itself, and
contribute to the best of my ability.
The bug I've selected is a 'starter' one, to get involved in the process.
The patch is attached below.

Thanks,
Andrey

===================================================================
diff --git a/src/hotspot/share/gc/g1/g1ConcurrentMark.hpp
b/src/hotspot/share/gc/g1/g1ConcurrentMark.hpp
--- a/src/hotspot/share/gc/g1/g1ConcurrentMark.hpp (revision
06348dfcae0b6b82970e8c56391396affd311f90)
+++ b/src/hotspot/share/gc/g1/g1ConcurrentMark.hpp (revision
e635cee530e414503d6e84261ce636123d282ee9)
@@ -50,10 +50,6 @@
 class G1SurvivorRegions;
 class ThreadClosure;

-PRAGMA_DIAG_PUSH
-// warning C4522: multiple assignment operators specified
-PRAGMA_DISABLE_MSVC_WARNING(4522)
-
 // This is a container class for either an oop or a continuation address
for
 // mark stack entries. Both are pushed onto the mark stack.
 class G1TaskQueueEntry {
@@ -89,8 +85,6 @@
   bool is_null() const { return _holder == NULL; }
 };

-PRAGMA_DIAG_POP
-
 typedef GenericTaskQueue<G1TaskQueueEntry, mtGC> G1CMTaskQueue;
 typedef GenericTaskQueueSet<G1CMTaskQueue, mtGC> G1CMTaskQueueSet;



More information about the hotspot-gc-dev mailing list