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

JDK23 jdk_lang_1_FAILED java/lang/String/CompactString/MaxSizeUTF16String.java OutOfMemoryError: Required length exceeds implementation limit #20035

Closed
JasonFengJ9 opened this issue Aug 21, 2024 · 5 comments

Comments

@JasonFengJ9
Copy link
Member

JasonFengJ9 commented Aug 21, 2024

Failure link

From an internal build(macaarch64rt1):

openjdk version "23-beta" 2024-09-17
IBM Semeru Runtime Open Edition 23+36-202408210002 (build 23-beta+36-202408210002)
Eclipse OpenJ9 VM 23+36-202408210002 (build master-a308eaf9e0, JRE 23 Mac OS X aarch64-64-Bit 20240821_18 (JIT enabled, AOT enabled)
OpenJ9   - a308eaf9e0
OMR      - e0dde2287
JCL      - f97359bdc based on jdk-23+36)

Rerun in Grinder - Change TARGET to run only the failed test targets.

Optional info

Failure output (captured from console output)

[2024-08-21T02:51:37.678Z] variation: -Xdump:system:none -Xdump:heap:none -Xdump:system:events=gpf+abort+traceassert+corruptcache -XX:-JITServerTechPreviewMessage Mode650
[2024-08-21T02:51:37.678Z] JVM_OPTIONS:  -Xdump:system:none -Xdump:heap:none -Xdump:system:events=gpf+abort+traceassert+corruptcache -XX:-JITServerTechPreviewMessage -XX:-UseCompressedOops -Xverbosegclog 

[2024-08-21T02:55:17.213Z] TEST: java/lang/String/CompactString/MaxSizeUTF16String.java

[2024-08-21T02:55:17.213Z] STARTED    MaxSizeUTF16String::testMaxUTF8_UTF16Encode 'testMaxUTF8_UTF16Encode()'
[2024-08-21T02:55:17.213Z] java.lang.OutOfMemoryError: Required length exceeds implementation limit
[2024-08-21T02:55:17.213Z] 	at java.base/java.lang.String.encodeUTF8_UTF16(String.java:1542)
[2024-08-21T02:55:17.213Z] 	at java.base/java.lang.String.encodeUTF8(String.java:1511)
[2024-08-21T02:55:17.213Z] 	at java.base/java.lang.String.encode(String.java:1079)
[2024-08-21T02:55:17.213Z] 	at java.base/java.lang.String.getBytes(String.java:2555)
[2024-08-21T02:55:17.213Z] 	at MaxSizeUTF16String.lambda$testMaxUTF8_UTF16Encode$0(MaxSizeUTF16String.java:153)
[2024-08-21T02:55:17.213Z] 	at org.junit.jupiter.api.AssertThrows.assertThrows(AssertThrows.java:53)
[2024-08-21T02:55:17.213Z] 	at org.junit.jupiter.api.AssertThrows.assertThrows(AssertThrows.java:35)
[2024-08-21T02:55:17.213Z] 	at org.junit.jupiter.api.Assertions.assertThrows(Assertions.java:3083)
[2024-08-21T02:55:17.213Z] 	at MaxSizeUTF16String.testMaxUTF8_UTF16Encode(MaxSizeUTF16String.java:153)

[2024-08-21T02:55:17.217Z] TEST RESULT: Failed. Execution failed: `main' threw exception: java.lang.Exception: JUnit test failure
[2024-08-21T02:55:17.217Z] --------------------------------------------------
[2024-08-21T03:00:07.938Z] Test results: passed: 930; failed: 1
[2024-08-21T03:00:09.218Z] Report written to /Users/jenkins/workspace/Test_openjdk23_j9_sanity.openjdk_aarch64_mac/aqa-tests/TKG/output_17242086962796/jdk_lang_1/report/html/report.html
[2024-08-21T03:00:09.218Z] Results written to /Users/jenkins/workspace/Test_openjdk23_j9_sanity.openjdk_aarch64_mac/aqa-tests/TKG/output_17242086962796/jdk_lang_1/work
[2024-08-21T03:00:09.218Z] Error: Some tests failed or other problems occurred.
[2024-08-21T03:00:09.218Z] -----------------------------------
[2024-08-21T03:00:09.218Z] jdk_lang_1_FAILED

50x internal grinder - all failed

@knn-k
Copy link
Contributor

knn-k commented Aug 23, 2024

The same testcase (MaxSizeUTF16String) with different JVM option (-XX:-CompactStrings), different error: #20021

@hzongaro
Copy link
Member

Does the above capture the right failure output? I think the actual failure in the console log for that internal build is for test case MaxSizeUTF16String::testMaxCharArray:

22:55:17  STARTED    MaxSizeUTF16String::testMaxCharArray 'testMaxCharArray()'
22:55:17  Checking max UTF16 string len: 1073741824
22:55:17  Checking max UTF16 string len: 1073741823
22:55:17  org.opentest4j.AssertionFailedError: Expected OutOfMemoryError with message prefix: UTF16 String size is
22:55:17  	at org.junit.jupiter.api.AssertionUtils.fail(AssertionUtils.java:38)
22:55:17  	at org.junit.jupiter.api.Assertions.fail(Assertions.java:135)
22:55:17  	at MaxSizeUTF16String.testMaxCharArray(MaxSizeUTF16String.java:112)
22:55:17  	at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:103)
22:55:17  	at java.base/java.lang.reflect.Method.invoke(Method.java:586)
22:55:17  	at org.junit.platform.commons.util.ReflectionUtils.invokeMethod(ReflectionUtils.java:727)
...
22:55:17  	at com.sun.javatest.regtest.agent.MainWrapper$MainTask.run(MainWrapper.java:138)
22:55:17  	at java.base/java.lang.Thread.run(Thread.java:1587)
22:55:17  FAILED     MaxSizeUTF16String::testMaxCharArray 'testMaxCharArray()'
22:55:17  STARTED    MaxSizeUTF16String::testMaxUTF8_UTF16Encode 'testMaxUTF8_UTF16Encode()'

This might be a duplicate of #20021

@hzongaro
Copy link
Member

I ran a 50x internal grinder using the fix for #20021 from pull request #20058. It passed 100%, so I'm going to mark this as a duplicate.

@hzongaro
Copy link
Member

Duplicate of #20021

@hzongaro hzongaro marked this as a duplicate of #20021 Aug 26, 2024
@hzongaro
Copy link
Member

If the problem can still be reproduced after #20058 is merged, please reopen this.

@hzongaro hzongaro closed this as not planned Won't fix, can't repro, duplicate, stale Aug 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants
@tajila @JasonFengJ9 @hzongaro @knn-k and others