RFR: 8205064: Fail immediately if an unsupported GC is selected

Per Liden per.liden at oracle.com
Fri Jun 15 06:34:44 UTC 2018


On 2018-06-15 00:15, Roman Kennke wrote:
> Am 14.06.2018 um 22:34 schrieb Per Liden:
>> If an unsupported GC (i.e. a GC that is not built into the VM) is
>> selected by the user, the VM issues a warning and then continues and
>> (silently) selects a different GC. Aleksey brought this up on the ZGC
>> list [1]. I agree that this behavior seems dubious. With this patch we
>> instead fail immediately to avoid unnecessary confusion.
>>
>> Bug: https://bugs.openjdk.java.net/browse/JDK-8205064
>> Webrev: http://cr.openjdk.java.net/~pliden/8205064/webrev.0
>>
>> Testing: manual + currently running in mach5 t{1,2,3}
>>
>> /Per
>>
>> [1] http://mail.openjdk.java.net/pipermail/zgc-dev/2018-June/000422.html
> 
> Hi Per,
> 
> I am not sure I'd ever set Epsilon as default, but it's the last in
> line, i.e. selected when built *only* with Epsilon, is that right?
> 
> Why not include CMS in that list? If I build with CMS and Epsilon, I get
> Epsilon selected?

Oops, I never intended to keep that part of the patch, but forgot to 
remove. Dropping this part.

+#elif INCLUDE_ZGC
+    FLAG_SET_ERGO_IF_DEFAULT(bool, UseZGC, true);
+#elif INCLUDE_EPSILONGC
+    FLAG_SET_ERGO_IF_DEFAULT(bool, UseEpsilonGC, true);

> 
> Other than that, I think the patch is good.

Thanks!

/Per

> 
> Thanks, Roman
> 



More information about the hotspot-gc-dev mailing list