Dramatic speed difference of Native Calls via JNA between various JDK, why? #7830
Unanswered
manticore-projects
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Greetings!
First of all, thank you for providing GraalVM (although I did not take the suspension of FastR lightly). I managed to wrap different optimized native PNG encoders into a Java Library and ran it successfully on GraalVM 11 and 21. Please see https://github.com/manticore-projects/fpng-java for details.
However, benchmarks revealed surprising results when using GraalVM vs. OpenJDK or JetBrains JDK:
Details of the Benchmark Results are here: https://github.com/manticore-projects/fpng-java#benchmarks
The code and the machine is the same. Everything was cleaned and freshly compiled. I repeated the tests many time and I do believe I know how to benchmark properly.
I also tried on a self-compiled, optimized "-O3 -march=native" JetBrains JDK version with all possible optimizations. It did not improve the results and only confirmed the "slow" observations on JetBrains JDK or OpenJDK.
So it does not seem to be about compile optimization of the JDK alone.
Please can you provide any idea or hint, why there is this massive performance difference, but only for the native encoders? I am completely lost and don't trust those results or my skills.
Further, please don't feel offended when I will ask the same question at JetBrains and JNA forums.
Thanks for your advise in advance and cheers!
Beta Was this translation helpful? Give feedback.
All reactions