RFR: JDK-8311788: ClassLoadUnloadTest fails on AIX after JDK-8193513
Thomas Stuefe
stuefe at openjdk.org
Tue Jul 11 13:46:14 UTC 2023
On Tue, 11 Jul 2023 13:15:11 GMT, Matthias Baesken <mbaesken at openjdk.org> wrote:
> The change [JDK-8193513](https://bugs.openjdk.org/browse/JDK-8193513) enhanced the test runtime/logging/ClassLoadUnloadTest.java . Unfortunately the test started to fail after this on AIX :
>
> ----------System.err:(16/744)----------
> stdout: [];
> stderr: []
> exitValue = 0
>
> java.lang.RuntimeException: '[class,load,cause]' missing from stdout/stderr
> at jdk.test.lib.process.OutputAnalyzer.shouldContain(OutputAnalyzer.java:221)
> at ClassLoadUnloadTest.checkFor(ClassLoadUnloadTest.java:64)
> at ClassLoadUnloadTest.main(ClassLoadUnloadTest.java:128)
> at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:103)
> at java.base/java.lang.reflect.Method.invoke(Method.java:580)
> at com.sun.javatest.regtest.agent.MainActionHelper$AgentVMRunnable.run(MainActionHelper.java:333)
> at java.base/java.lang.Thread.run(Thread.java:1570)
>
>
> Reason is that we check for class java.lang.StringCoding in the UL output; but on AIX this class is not loaded because we have a different encoding/charset (see ISO_8859_1.INSTANCE in the String class). This different encoding is not using StringCoding.
>
> I suppose the same might be true for JVMs without COMPACT_STRING supported (but did not check in detail) .
Hi Matthias,
instead of trying to find a class that gets loaded on all platforms, why not just check for `ClassUnloadTest`?
Cheers, Thomas
-------------
PR Comment: https://git.openjdk.org/jdk/pull/14829#issuecomment-1630861489
More information about the hotspot-runtime-dev
mailing list