RFR: Fix Zero build
Aleksey Shipilev
shade at redhat.com
Tue Jun 12 16:20:33 UTC 2018
With Zero, or when C1 and C2 are disabled, current build fails with:
/pool/buildbot/slaves/sobornost/shenandoah-jdkX/build/src/hotspot/share/gc/shenandoah/shenandoahBarrierSet.cpp:
In constructor ‘ShenandoahBarrierSet::ShenandoahBarrierSet(ShenandoahHeap*)’:
/pool/buildbot/slaves/sobornost/shenandoah-jdkX/build/src/hotspot/share/gc/shenandoah/shenandoahBarrierSet.cpp:72:34:
error: ‘ShenandoahBarrierSetC1’ was not declared in this scope
make_barrier_set_c1<ShenandoahBarrierSetC1>(),
^~~~~~~~~~~~~~~~~~~~~~
/pool/buildbot/slaves/sobornost/shenandoah-jdkX/build/src/hotspot/share/gc/shenandoah/shenandoahBarrierSet.cpp:72:58:
error: no matching function for call to ‘ShenandoahBarrierSet::make_barrier_set_c1()’
make_barrier_set_c1<ShenandoahBarrierSetC1>(),
^
Other GCs get away with it by forward-declaring their compiler BarrierSets. We can do the same:
diff -r cd5a82e54311 src/hotspot/share/gc/shenandoah/shenandoahBarrierSet.cpp
--- a/src/hotspot/share/gc/shenandoah/shenandoahBarrierSet.cpp Tue Jun 12 17:37:20 2018 +0200
+++ b/src/hotspot/share/gc/shenandoah/shenandoahBarrierSet.cpp Tue Jun 12 18:17:43 2018 +0200
@@ -38,6 +38,9 @@
#include "gc/shenandoah/c2/shenandoahBarrierSetC2.hpp"
#endif
+class ShenandoahBarrierSetC1;
+class ShenandoahBarrierSetC2;
+
ShenandoahSATBMarkQueueSet ShenandoahBarrierSet::_satb_mark_queue_set;
template <bool UPDATE_MATRIX, bool STOREVAL_WRITE_BARRIER>
Testing: Zero x86_64 build
Thanks,
-Aleksey
More information about the shenandoah-dev
mailing list