Skip to content

[GR-65161] Fix Sulong coverage jobs. #11364

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

Merged
merged 3 commits into from
Jun 10, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions sulong/ci/ci.jsonnet
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ local sc = (import "ci_common/sulong-common.jsonnet");

sulong:: {
suite:: "sulong",
extra_mx_args+:: [ "--dynamicimport", "/compiler" ],
extra_mx_args+:: if self._jdkIsGraalVM then [] else [ "--dynamicimport", "/compiler" ],
setup+: [
["cd", "./sulong"],
],
Expand Down Expand Up @@ -120,11 +120,11 @@ local sc = (import "ci_common/sulong-common.jsonnet");
coverage_builds::
sc.mapPrototypePlatformName([sc.weekly + $.sulong + sc.coverage($.regular_builds)],
[
[sc.linux_amd64, [sc.labsjdk21]],
[sc.darwin_amd64, [sc.labsjdk21]],
[sc.windows_amd64, [sc.labsjdk21]],
[sc.linux_aarch64, [sc.labsjdk21]],
[sc.darwin_aarch64, [sc.labsjdk21]],
[sc.linux_amd64, [sc.graalvmee21]],
[sc.darwin_amd64, [sc.graalvmee21]],
[sc.windows_amd64, [sc.graalvmee21]],
[sc.linux_aarch64, [sc.graalvmee21]],
[sc.darwin_aarch64, [sc.graalvmee21]],
],
[
{ name: "weekly-sulong-coverage-jdk21-linux-amd64", timelimit: "2:00:00" },
Expand Down
10 changes: 8 additions & 2 deletions sulong/ci/ci_common/sulong-common.jsonnet
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@ local sulong_deps = common.deps.sulong;
skipPlatform:: coverageTags == [],
gateTags:: ["build"] + coverageTags,
# The Jacoco annotations interfere with partial evaluation. Use the DefaultTruffleRuntime to disable compilation just for the coverage runs.
extra_mx_args+: ["--no-jacoco-exclude-truffle", "-J-Dtruffle.TruffleRuntime=com.oracle.truffle.api.impl.DefaultTruffleRuntime", "-J-Dpolyglot.engine.WarnInterpreterOnly=false"],
extra_mx_args+: ["-J-Dtruffle.TruffleRuntime=com.oracle.truffle.api.impl.DefaultTruffleRuntime", "-J-Dpolyglot.engine.WarnInterpreterOnly=false"],
extra_gate_args+: ["--jacoco-relativize-paths", "--jacoco-omit-src-gen", "--jacocout", "coverage", "--jacoco-format", "lcov"],
teardown+: [
["mx", "sversions", "--print-repositories", "--json", "|", "coverage-uploader.py", "--associated-repos", "-"],
Expand All @@ -193,8 +193,14 @@ local sulong_deps = common.deps.sulong;
},
} + {

[std.strReplace(name, "-", "_")]: common[name]
[std.strReplace(name, "-", "_")]: common[name] + { _jdkIsGraalVM:: false }
for name in std.objectFieldsAll(common)
if std.startsWith(name, "labsjdk")

} + {

[name]: common[name] + { _jdkIsGraalVM:: true }
for name in std.objectFieldsAll(common)
if std.startsWith(name, "graalvm")

}
13 changes: 7 additions & 6 deletions sulong/mx.sulong/mx_sulong_gate.py
Original file line number Diff line number Diff line change
Expand Up @@ -158,12 +158,13 @@ def _unittest(title, test_suite, tags=None, testClasses=None, unittestArgs=None,
else:
slowStandalone = standaloneMode == "jvm"

with Task('Build GraalJDK', tasks, tags=['standalone']) as t:
# building GraalJDK to work around a bug in the mx support code of the compiler suite
# `mx unittest` doesn't work if this is not built, and we want to avoid doing a full `mx build` in the standalone jobs
if t:
import mx_compiler
mx.command_function('build')(['--dependencies', mx_compiler._graaljdk_dist(edition='ce').name])
if mx.suite('compiler', fatalIfMissing=False):
with Task('Build GraalJDK', tasks, tags=['standalone']) as t:
# building GraalJDK to work around a bug in the mx support code of the compiler suite
# `mx unittest` doesn't work if compiler is imported and this is not built, and we want to avoid doing a full `mx build` in the standalone jobs
if t:
import mx_compiler
mx.command_function('build')(['--dependencies', mx_compiler._graaljdk_dist(edition='ce').name])

if standaloneMode == "native":
with Task('Build Native LLVM Standalone', tasks, tags=['standalone']) as t:
Expand Down