adoptium / adoptium/aqa-tests

functional/JLM_Tests fail to compile with JDK_impl=hotspot

Open
#5,152 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
HTML
Stars
155
Forks
346
Avg merge
2d 9h
Merged PRs (30d)
36

Description

Spotted when running https://github.com/adoptium/aqa-tests/blob/master/.github/workflows/directoriesFilesChangePR.yml (which itself should be improved/removed based on https://github.com/adoptium/aqa-tests/issues/2299).

Example:
https://github.com/adoptium/aqa-tests/actions/runs/8335749724/job/22811786784?pr=5150

```
/Users/runner/work/aqa-tests/aqa-tests/aqa-tests/functional/JLM_Tests/src/org/openj9/test/java/lang/management/TestThreadMXBean.java:374: error: incompatible types: long[] cannot be converted to long
[javac] tb.getThreadCpuTime(badIds);
[javac] ^
[javac] /Users/runner/work/aqa-tests/aqa-tests/aqa-tests/functional/JLM_Tests/src/org/openj9/test/java/lang/management/TestThreadMXBean.java:400: error: incompatible types: long[] cannot be converted to long
[javac] long[] times = tb.getThreadCpuTime(ids);
[javac] ^
[javac] /Users/runner/work/aqa-tests/aqa-tests/aqa-tests/functional/JLM_Tests/src/org/openj9/test/java/lang/management/TestThreadMXBean.java:415: error: incompatible types: long[] cannot be converted to long
[javac] AssertJUnit.assertTrue(tb.getThreadCpuTime(new long[] {Thread.currentThread().getId()})[0] == -1);
[javac] ^
[javac] /Users/runner/work/aqa-tests/aqa-tests/aqa-tests/functional/JLM_Tests/src/org/openj9/test/java/lang/management/TestThreadMXBean.java:425: error: incompatible types: long[] cannot be converted to long
[javac] long[] tmp = tb.getThreadCpuTime(new long[] {100});
[javac] ^
[javac] /Users/runner/work/aqa-tests/aqa-tests/aqa-tests/functional/JLM_Tests/src/org/openj9/test/java/lang/management/TestThreadMXBean.java:595: error: incompatible types: cannot be converted to long
[javac] tb.getThreadUserTime(null);
[javac] ^
[javac] /Users/runner/work/aqa-tests/aqa-tests/aqa-tests/functional/JLM_Tests/src/org/openj9/test/java/lang/management/TestThreadMXBean.java:602: error: incompatible types: long[] cannot be converted to long
[javac] tb.getThreadUserTime(badIds);
[javac] ^
[javac] /Users/runner/work/aqa-tests/aqa-tests/aqa-tests/functional/JLM_Tests/src/org/openj9/test/java/lang/management/TestThreadMXBean.java:628: error: incompatible types: long[] cannot be converted to long
[javac] long[] times = tb.getThreadUserTime(ids);
[javac] ^
[javac] /Users/runner/work/aqa-tests/aqa-tests/aqa-tests/functional/JLM_Tests/src/org/openj9/test/java/lang/management/TestThreadMXBean.java:643: error: incompatible types: long[] cannot be converted to long
[javac] AssertJUnit.assertTrue(tb.getThreadUserTime(new long[] {Thread.currentThread().getId()})[0] == -1);
[javac] ^
[javac] /Users/runner/work/aqa-tests/aqa-tests/aqa-tests/functional/JLM_Tests/src/org/openj9/test/java/lang/management/TestThreadMXBean.java:653: error: incompatible types: long[] cannot be converted to long
[javac] long[] tmp = tb.getThreadUserTime(new long[] {100});
[javac] ^
[javac] Note: /Users/runner/work/aqa-tests/aqa-tests/aqa-tests/functional/JLM_Tests/src/j9vm/test/softmx/SoftmxRemoteTest.java uses or overrides a deprecated API.
[javac] Note: Recompile with -Xlint:deprecation for details.
[javac] Note: Some input files use unchecked or unsafe operations.
[javac] Note: Recompile with -Xlint:unchecked for details.
[javac] Note: Some messages have been simplified; recompile with -Xdiags:verbose to get full output
[javac] 10 errors

BUILD FAILED
/Users/runner/work/aqa-tests/aqa-tests/aqa-tests/TKG/scripts/build_test.xml:95: The following error occurred while executing this line:
/Users/runner/work/aqa-tests/aqa-tests/aqa-tests/functional/build.xml:52: The following error occurred while executing this line:
/Users/runner/work/aqa-tests/aqa-tests/aqa-tests/functional/JLM_Tests/build.xml:144: The following error occurred while executing this line:
/Users/runner/work/aqa-tests/aqa-tests/aqa-tests/functional/JLM_Tests/build.xml:61: Compile failed; see the compiler error output for details.

Total time: 38 seconds
1
make[1]: *** [compile] Error 1
make: *** [compile] Error 2
Error: The process '/usr/bin/make' failed with exit code 2
```

Likely has to be mitigated by an update in the openj9 repository, or TKG to skip compilation in certain case.

Contributor guide

Open the contributing guide

Research direction

Start with functional/JLM_Tests/src/org/openj9/test/java/lang/management/TestThreadMXBean.java and reproduce the failure through the referenced workflow or JLM_Tests build.xml. Check the JDK_impl=hotspot compilation errors and the suggested OpenJ9 or TKG path. Done means JLM_Tests compiles successfully in that configuration.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
testing
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.