renaissance-naive-bayes_0 perf tests fail on jdk15+ with NPE
Describe the bug renaissance-naive-bayes_0 perf tests fail on jdk15 with NPE
To Reproduce https://trss.adoptopenjdk.net/output/test?id=5f28a1350bec7975ae08ae21
Just one example. Seems consistent across the board, all VMs and platforms.
Only occurs on JDK15.
Expected behavior Expected no NPE here.
Screenshot
[2020-08-03T22:20:46.691Z] Error during tear-down: null
[2020-08-03T22:20:46.691Z] java.lang.NullPointerException
[2020-08-03T22:20:46.691Z] at java.base/java.lang.NullPointerException.fillInStackTrace(NullPointerException.java:91)
[2020-08-03T22:20:46.691Z] at java.base/java.lang.Throwable.<init>(Throwable.java:90)
[2020-08-03T22:20:46.691Z] at java.base/java.lang.Throwable.<init>(Throwable.java:101)
[2020-08-03T22:20:46.691Z] at java.base/java.lang.Exception.<init>(Exception.java:67)
[2020-08-03T22:20:46.691Z] at java.base/java.lang.RuntimeException.<init>(RuntimeException.java:63)
[2020-08-03T22:20:46.691Z] at java.base/java.lang.NullPointerException.<init>(NullPointerException.java:70)
[2020-08-03T22:20:46.691Z] at org.renaissance.apache.spark.NaiveBayes.tearDownAfterAll(NaiveBayes.scala:93)
[2020-08-03T22:20:46.691Z] at org.renaissance.RenaissanceBenchmark.runBenchmark(RenaissanceBenchmark.java:97)
[2020-08-03T22:20:46.691Z] at org.renaissance.RenaissanceSuite$.$anonfun$main$2(renaissance-suite.scala:308)
[2020-08-03T22:20:46.691Z] at org.renaissance.RenaissanceSuite$.$anonfun$main$2$adapted(renaissance-suite.scala:306)
[2020-08-03T22:20:46.691Z] at org.renaissance.RenaissanceSuite$$$Lambda$125/00000000321B4E20.apply(Unknown Source)
[2020-08-03T22:20:46.691Z] at scala.collection.mutable.ResizableArray.foreach(ResizableArray.scala:62)
[2020-08-03T22:20:46.691Z] at scala.collection.mutable.ResizableArray.foreach$(ResizableArray.scala:55)
[2020-08-03T22:20:46.691Z] at scala.collection.mutable.ArrayBuffer.foreach(ArrayBuffer.scala:49)
[2020-08-03T22:20:46.691Z] at org.renaissance.RenaissanceSuite$.main(renaissance-suite.scala:306)
[2020-08-03T22:20:46.691Z] at org.renaissance.RenaissanceSuite.main(renaissance-suite.scala)
[2020-08-03T22:20:46.691Z] at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[2020-08-03T22:20:46.691Z] at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:64)
[2020-08-03T22:20:46.691Z] at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
[2020-08-03T22:20:46.691Z] at java.base/java.lang.reflect.Method.invoke(Method.java:564)
[2020-08-03T22:20:46.691Z] at org.renaissance.Launcher.main(Launcher.java:18)
https://github.com/renaissance-benchmarks/renaissance/blob/v0.9.0/benchmarks/apache-spark/src/main/scala/org/renaissance/apache/spark/NaiveBayes.scala#L93
But since there is a v0.11.0 of the renaissance suite, I suggest we first upgrade to it, the latest stable version, and see how the suite behaves across jdk8/jdk11/jdk15, as it is likely been updated, definitely that NaiveBayes.scala file is changed.
Updated to v0.11.0 in my branch and still get NPE (for both hotspot and openj9 on jdk15, earlier JDK_VERSIONs are fine)
Hotspot output: GC before operation: completed in 33.588 ms, heap usage 104.344 MB -> 20.284 MB. Benchmark 'naive-bayes' failed with exception: java.lang.NullPointerException: Cannot invoke "org.apache.spark.mllib.classification.NaiveBayesModel.labels()" because the return value of "org.renaissance.apache.spark.NaiveBayes.bayesModel()" is null at org.renaissance.apache.spark.NaiveBayes.tearDownAfterAll(NaiveBayes.scala:93) at org.renaissance.harness.ExecutionDriver.executeBenchmark(ExecutionDriver.java:72)
OpenJ9 output: GC before operation: completed in 69.052 ms, heap usage 23.157 MB -> 19.402 MB. Benchmark 'naive-bayes' failed with exception: java.lang.NullPointerException at org.renaissance.apache.spark.NaiveBayes.tearDownAfterAll(NaiveBayes.scala:93) at org.renaissance.harness.ExecutionDriver.executeBenchmark(ExecutionDriver.java:72)
Occurs on both hotspot (Grinder_Perf/5) and openj9 (Grinder_Perf/8) builds from AdoptOpenJDK, but not on openj9 builds from the OpenJ9 project (Grinder_Perf/7).
auto exclude test renaissance-naive-bayes
Exclude while investigating so we can 'run green'
@norbline - we can try to rerun this disabled test target against a JDK_VERSION=17 build in a Grinder to see how it behaves
test passed https://ci.adoptopenjdk.net/job/Grinder/2817/
Rerun of the 2817 with TARGET=disabled.renaissance-naive-bayes (so that the disabled test target is not skipped): https://ci.adoptopenjdk.net/job/Grinder/2819/tapResults/
Hi @llxia ,
Please find the test result on below platforms
| Testname | Platform | JDK | Result |
|---|---|---|---|
| renaissance-naive-bayes | x86-64_windows /x86-64_linux /x86-64_mac /s390x_linux :https://hyc-runtimes-jenkins.swg-devops.com/job/Grinder/50610/console | JDK 21 | Pass |
| renaissance-naive-bayes | x86-64_windows : https://hyc-runtimes-jenkins.swg-devops.com/job/Grinder/51817/console | JDK 17 | Successful |
| renaissance-naive-bayes | All Platform: https://hyc-runtimes-jenkins.swg-devops.com/job/Grinder/51175/console | JDK 21 | Successfull in all platform except x86-64_linux |
| renaissance-naive-bayes | x86-64_linux : https://hyc-runtimes-jenkins.swg-devops.com/job/Grinder/51191/console | JDK 21 | Re-Build -successful |
| renaissance-naive-bayes | x86-32_windows https://hyc-runtimes-jenkins.swg-devops.com/job/Grinder/51697/console | JDK 8 | successful |