Nastel/cybench-java-benchmarks

Can't run benchmarks with Java 16.0

spencerspitz opened this issue · 3 comments

JDK:
java version "16.0.1" 2021-04-20
Java(TM) SE Runtime Environment (build 16.0.1+9-24)
Java HotSpot(TM) 64-Bit Server VM (build 16.0.1+9-24, mixed mode, sharing)

Logs:
Exception in thread "main" org.openjdk.jmh.runner.ProfilersFailedException: Profilers failed to initialize, exiting.
at org.openjdk.jmh.runner.Runner.internalRun(Runner.java:242)
at org.openjdk.jmh.runner.Runner.run(Runner.java:210)
at com.gocypher.cybench.launcher.BenchmarkRunner.main(BenchmarkRunner.java:200)
Suppressed: org.openjdk.jmh.profile.ProfilerException: Problem initializing profiler (class org.openjdk.jmh.profile.AbstractHotspotProfiler cannot access class sun.management.ManagementFactoryHelper (in module java.management) because module java.management does not export sun.management to unnamed module @3f49dace), are you running HotSpot VM?
at org.openjdk.jmh.profile.AbstractHotspotProfiler.(AbstractHotspotProfiler.java:50)
at org.openjdk.jmh.profile.HotspotRuntimeProfiler.(HotspotRuntimeProfiler.java:39)
at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:78)
at java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.base/java.lang.reflect.Constructor.newInstanceWithCaller(Constructor.java:499)
at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:480)
at org.openjdk.jmh.profile.ProfilerFactory.instantiate(ProfilerFactory.java:88)
at org.openjdk.jmh.profile.ProfilerFactory.getProfiler(ProfilerFactory.java:77)
at org.openjdk.jmh.profile.ProfilerFactory.getProfilerOrException(ProfilerFactory.java:37)
at org.openjdk.jmh.runner.Runner.internalRun(Runner.java:239)
... 2 more
Caused by: org.openjdk.jmh.profile.ProfilerException: Problem initializing profiler (class org.openjdk.jmh.profile.AbstractHotspotProfiler cannot access class sun.management.ManagementFactoryHelper (in module java.management) because module java.management does not export sun.management to unnamed module @3f49dace), are you running HotSpot VM?
at org.openjdk.jmh.profile.AbstractHotspotProfiler.(AbstractHotspotProfiler.java:50)
at org.openjdk.jmh.profile.HotspotThreadProfiler.(HotspotThreadProfiler.java:38)
at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:78)
at java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.base/java.lang.reflect.Constructor.newInstanceWithCaller(Constructor.java:499)
at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:480)
at org.openjdk.jmh.profile.ProfilerFactory.instantiate(ProfilerFactory.java:88)
at org.openjdk.jmh.profile.ProfilerFactory.getProfiler(ProfilerFactory.java:77)
at org.openjdk.jmh.profile.ProfilerFactory.getProfilerOrException(ProfilerFactory.java:37)
at org.openjdk.jmh.runner.Runner.internalRun(Runner.java:239)
... 2 more

@spencerspitz, what set of benchmarks you've been trying to run? ("strings", "json", "io", etc..)

@kausandr I was trying json and matrices

Fixed in 19318d4 commit.