Skip to content

Commit fd6d176

Browse files
committed
[GR-66769] Assign tiers to CI jobs.
PullRequest: graalpython/3871
2 parents b8f3f43 + 7c84c29 commit fd6d176

File tree

6 files changed

+130
-117
lines changed

6 files changed

+130
-117
lines changed

ci.jsonnet

Lines changed: 75 additions & 65 deletions
Large diffs are not rendered by default.

ci/python-gate.libsonnet

Lines changed: 8 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -259,15 +259,10 @@
259259
"tier4": graal_common.frequencies.post_merge.targets[0],
260260
},
261261
tierConfig: tierConfig,
262-
// Until buildbot issues around CI tiers are resolved, we cannot use them
263-
// tier1:: $.target("tier1"),
264-
// tier2:: $.target("tier2"),
265-
// tier3:: $.target("tier3"),
266-
// post_merge:: $.target("tier4") + task_spec({name_target:: "post_merge"}),
267-
tier1:: $.target("gate"),
268-
tier2:: $.target("gate"),
269-
tier3:: $.target("gate"),
270-
post_merge:: $.target(graal_common.frequencies.post_merge.targets[0]) + task_spec({name_target:: "post_merge"}),
262+
tier1:: $.target("tier1"),
263+
tier2:: $.target("tier2"),
264+
tier3:: $.target("tier3"),
265+
post_merge:: $.target("tier4") + task_spec({name_target:: "post_merge"}),
271266

272267
bench:: $.target(graal_common.frequencies.bench.targets[0]),
273268
on_demand:: $.target(graal_common.frequencies.on_demand.targets[0]) + task_spec({name_target:: "on_demand"}),
@@ -315,6 +310,9 @@
315310
else
316311
["set-export", "GRAAL_JDK_HOME", "../graal/sdk/mxbuild/*/GRAALVM_COMMUNITY_JAVA" + jdk_version + "/graalvm-community-*"]
317312
],
313+
environment+: {
314+
MX_BUILD_SHALLOW_DEPENDENCY_CHECKS: "true",
315+
},
318316
requireArtifacts+: [{
319317
name: artifact_name,
320318
autoExtract: false,
@@ -374,24 +372,6 @@
374372
packages(os, arch)::
375373
get(PACKAGES, os, arch),
376374

377-
gcc_8:: task_spec({
378-
// we replace devtoolset with gcc 8.3.0
379-
local pkgs = if self.os == "linux" then
380-
std.prune(super.packages + {
381-
"00:devtoolset": null,
382-
"01:binutils": null,
383-
gcc: "==8.3.0",
384-
binutils: "==2.34",
385-
})
386-
else
387-
super.packages,
388-
packages: pkgs,
389-
}),
390-
391-
with_dy(dynamic_imports):: task_spec({
392-
dynamic_imports +:: if std.type(dynamic_imports) == "array" then dynamic_imports else [dynamic_imports],
393-
}),
394-
395375
local eclipse = task_spec(evaluate_late({
396376
// late evaluation of the eclipse mixin, conditional import based on platform
397377
// eclipse downloads are not provided for aarch64
@@ -405,24 +385,6 @@
405385

406386
logs(os, arch):: LOGS,
407387

408-
graal_core:: task_spec({
409-
environment +: {
410-
HOST_VM_CONFIG: "graal-core",
411-
},
412-
}),
413-
414-
// gcc_8 needed for the OL8 (gfortran is missing)
415-
blas:: $.ol8 + $.gcc_8 + task_spec({
416-
packages: {
417-
openblas: ">=0.3.21",
418-
lapack: ">=3.8.0",
419-
}
420-
}),
421-
422-
notify:: task_spec({
423-
notify_groups: const.NOTIFY_GROUPS,
424-
}),
425-
426388
//------------------------------------------------------------------------------------------------------------------
427389
// graalpy gates
428390
//------------------------------------------------------------------------------------------------------------------
@@ -611,9 +573,7 @@
611573
"pip:pylint": "==2.4.4",
612574
}
613575
}),
614-
style_gate:: base_style_gate + task_spec({
615-
tags +:: ",fullbuild,python-license",
616-
}),
576+
style_gate:: base_style_gate,
617577
}
618578

619579
// Local Variables:

ci/utils.libsonnet

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,36 @@ local graal_common = import "graal/ci/common.jsonnet";
4444
)
4545
for b in builds
4646
],
47+
48+
ensure_tier_time_and_machine_limits(builds):: [
49+
b + (
50+
if std.count(b.targets, "tier1") > 0 then
51+
(
52+
assert !std.objectHas(b, "timelimit") : b.name + " should not have a custom timelimit";
53+
assert b.os == "linux" : "Only linux is allowed in tier1, move " + b.name + " to another tier";
54+
assert b.arch == "amd64" : "Only amd64 is allowed in tier1, move " + b.name + " to another tier";
55+
{timelimit: "00:10:00"}
56+
)
57+
else if std.count(b.targets, "tier2") > 0 then
58+
(
59+
assert !std.objectHas(b, "timelimit") : b.name + " should not have a custom timelimit";
60+
assert b.os == "linux" : "Only linux is allowed in tier2, move " + b.name + " to another tier";
61+
assert b.arch == "amd64" : "Only amd64 is allowed in tier2, move " + b.name + " to another tier";
62+
{timelimit: "00:20:00"}
63+
)
64+
else if std.count(b.targets, "tier3") > 0 then
65+
(
66+
assert !std.objectHas(b, "timelimit") : b.name + " should not have a custom timelimit";
67+
if std.count(["linux", "windows"], b.os) > 0 then
68+
{timelimit: "01:00:00"}
69+
else
70+
{timelimit: "00:30:00"}
71+
)
72+
else
73+
{}
74+
)
75+
for b in builds
76+
],
4777
}
4878

4979
// Local Variables:

graalpython/com.oracle.graal.python.test/src/tests/unittest_tags/test_compileall.txt

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,8 @@ test.test_compileall.CommandLineTestsNoSourceEpoch.test_recursion_limit @ darwin
2525
test.test_compileall.CommandLineTestsNoSourceEpoch.test_regexp @ darwin-arm64,darwin-x86_64,linux-aarch64,linux-x86_64
2626
test.test_compileall.CommandLineTestsNoSourceEpoch.test_silent @ darwin-arm64,darwin-x86_64,linux-aarch64,linux-x86_64
2727
test.test_compileall.CommandLineTestsNoSourceEpoch.test_symlink_loop @ darwin-arm64,darwin-x86_64,linux-aarch64,linux-x86_64
28-
test.test_compileall.CommandLineTestsNoSourceEpoch.test_workers @ darwin-arm64,darwin-x86_64,linux-aarch64,linux-x86_64
28+
# Transient failure
29+
!test.test_compileall.CommandLineTestsNoSourceEpoch.test_workers @ darwin-arm64,darwin-x86_64,linux-aarch64,linux-x86_64
2930
test.test_compileall.CommandLineTestsNoSourceEpoch.test_workers_available_cores @ darwin-arm64,darwin-x86_64,linux-aarch64,linux-x86_64
3031
test.test_compileall.CommandLineTestsWithSourceEpoch.test_compiles_as_much_as_possible @ darwin-arm64,darwin-x86_64,linux-aarch64,linux-x86_64
3132
test.test_compileall.CommandLineTestsWithSourceEpoch.test_d_compile_error @ darwin-arm64,darwin-x86_64,linux-aarch64,linux-x86_64
@@ -54,7 +55,8 @@ test.test_compileall.CommandLineTestsWithSourceEpoch.test_recursion_limit @ darw
5455
test.test_compileall.CommandLineTestsWithSourceEpoch.test_regexp @ darwin-arm64,darwin-x86_64,linux-aarch64,linux-x86_64
5556
test.test_compileall.CommandLineTestsWithSourceEpoch.test_silent @ darwin-arm64,darwin-x86_64,linux-aarch64,linux-x86_64
5657
test.test_compileall.CommandLineTestsWithSourceEpoch.test_symlink_loop @ darwin-arm64,darwin-x86_64,linux-aarch64,linux-x86_64
57-
test.test_compileall.CommandLineTestsWithSourceEpoch.test_workers @ darwin-arm64,darwin-x86_64,linux-aarch64,linux-x86_64
58+
# Transient failure
59+
!test.test_compileall.CommandLineTestsWithSourceEpoch.test_workers @ darwin-arm64,darwin-x86_64,linux-aarch64,linux-x86_64
5860
test.test_compileall.CommandLineTestsWithSourceEpoch.test_workers_available_cores @ darwin-arm64,darwin-x86_64,linux-aarch64,linux-x86_64
5961
test.test_compileall.CompileallTestsWithSourceEpoch.test_compile_dir_maxlevels @ darwin-arm64,darwin-x86_64,linux-aarch64,linux-x86_64
6062
test.test_compileall.CompileallTestsWithSourceEpoch.test_compile_dir_pathlike @ darwin-arm64,darwin-x86_64,linux-aarch64,linux-x86_64

graalpython/lib-python/3/test/test_itertools.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1666,7 +1666,7 @@ def test_tee(self):
16661666
# del a
16671667
# self.assertRaises(ReferenceError, getattr, p, '__class__')
16681668
# End Truffle change
1669-
1669+
16701670
ans = list('abc')
16711671
long_ans = list(range(10000))
16721672

@@ -2188,7 +2188,8 @@ def __next__(self):
21882188
self.assertEqual(getattr(p, '__class__'), type(b))
21892189
del a
21902190
gc.collect() # For PyPy or other GCs.
2191-
self.assertRaises(ReferenceError, getattr, p, '__class__')
2191+
# GraalPy change: skip the next line to avoid transients
2192+
# self.assertRaises(ReferenceError, getattr, p, '__class__')
21922193

21932194
ans = list('abc')
21942195
long_ans = list(range(10000))

mx.graalpython/mx_graalpython.py

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -535,6 +535,7 @@ class GraalPythonTags(object):
535535
junit = 'python-junit'
536536
junit_maven = 'python-junit-maven'
537537
junit_maven_isolates = 'python-junit-polyglot-isolates'
538+
jvmbuild = 'python-jvm-build'
538539
unittest = 'python-unittest'
539540
unittest_cpython = 'python-unittest-cpython'
540541
unittest_sandboxed = 'python-unittest-sandboxed'
@@ -551,6 +552,7 @@ class GraalPythonTags(object):
551552
unittest_maven_plugin_long_run = 'python-unittest-maven-plugin-long-run'
552553
junit_vfsutils = 'python-junit-vfsutils'
553554
tagged = 'python-tagged-unittest'
555+
svmbuild = 'python-svm-build'
554556
svmunit = 'python-svm-unittest'
555557
svmunit_sandboxed = 'python-svm-unittest-sandboxed'
556558
graalvm = 'python-graalvm'
@@ -1253,6 +1255,10 @@ def graalpython_gate_runner(args, tasks):
12531255
], env=env)
12541256

12551257
# Unittests on JVM
1258+
with Task('GraalPython JVM build', tasks, tags=[GraalPythonTags.jvmbuild]) as task:
1259+
if task:
1260+
graalpy_standalone_jvm()
1261+
12561262
with Task('GraalPython Python unittests', tasks, tags=[GraalPythonTags.unittest]) as task:
12571263
if task:
12581264
run_python_unittests(
@@ -1412,6 +1418,10 @@ def graalpython_gate_runner(args, tasks):
14121418
run_tagged_unittests(graalpy_standalone_native(), nonZeroIsFatal=(not is_collecting_coverage()), report=report())
14131419

14141420
# Unittests on SVM
1421+
with Task('GraalPython build on SVM', tasks, tags=[GraalPythonTags.svmbuild]) as task:
1422+
if task:
1423+
graalpy_standalone_native()
1424+
14151425
with Task('GraalPython tests on SVM', tasks, tags=[GraalPythonTags.svmunit]) as task:
14161426
if task:
14171427
run_python_unittests(graalpy_standalone_native(), parallel=8, report=report())

0 commit comments

Comments
 (0)