Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Avoid hardcoded -XX:+UseZGC on BSD system? #2515

Open
catap opened this issue Nov 25, 2024 · 1 comment
Open

Avoid hardcoded -XX:+UseZGC on BSD system? #2515

catap opened this issue Nov 25, 2024 · 1 comment

Comments

@catap
Copy link

catap commented Nov 25, 2024

Unfortently, OpenJDK does'n support ZGC on BSD system, an attempt to enable it on cofigure fails as:

checking if platform is supported by ZGC... no, bsd-x86_64
checking if JVM feature 'zgc' is available... no

See: https://github.com/openjdk/jdk/blob/027607968b3d55b498e9f2d7a4023b8ae2d47b5b/make/autoconf/jvm-features.m4#L318-L327

This mean that attempt to use bloop on any bsd system fails as:

~ $ scala --power bloop output
Error occurred during initialization of VM
Option -XX:+UseZGC not supported
~ $ 

as temporarry workaround a user may do something like this:

env BLOOP_JAVA_OPTS="-XX:+UseParallelGC"  scala --power bloop output

but, I think, that default hardcoded option should be adjusted.

And yes, ShenandoahGC is available on BSD system if you think that low latency GC is requried here.

@tgodzik
Copy link
Contributor

tgodzik commented Nov 26, 2024

Thanks for reporting! It should be easy to check the current platform and change the defaults at

def hardCodedDefaultJavaOpts: Seq[String] =

I might not have time to fix it soon though.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants