Unrecognized VM option 'ShenandoahGCHeuristics=compact'

2.3k Views Asked by At

On mac I am trying to use Shenandoah on java with the flags:

-XX:ShenandoahGCHeuristics=compact and -XX:+UseShenandoahGC

and I get the same error on java 13 and 12:

Unrecognized VM option 'ShenandoahGCHeuristics=compact' Error: Could not create the Java Virtual Machine. Error: A fatal exception has occurred. Program will exit.

and the error:

Error occurred during initialization of VM Option -XX:+UseShenandoahGC not supported

Does anyone know the reason for this or how to fix it?

1

There are 1 best solutions below

0
On

My guess would be that you are using the OpenJDK binary that does not include Shenandoah. Today, the only vendor who does not ship Shenandoah in their binaries is Oracle (those builds you get at jdk.java.net). Try to pick up any other OpenJDK distribution: your OS package manager, AdoptOpenJDK, SAPMachine, Amazon Corretto, etc.