Skip to content

Commit f544120

Browse files
committed
ci: test with intel gpus
1 parent b012b5e commit f544120

File tree

2 files changed

+78
-25
lines changed

2 files changed

+78
-25
lines changed

.buildkite/pipeline.yml

Lines changed: 50 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
steps:
2-
- group: ":test_tube: Tests"
2+
- group: ":test_tube: CUDA Tests"
33
steps:
4-
- label: ":julia: :linux: CUDA Julia v{{matrix.version}} -- {{matrix.group}} -- {{matrix.runtime}}"
4+
- label: ":julia: :linux: Julia v{{matrix.version}} -- {{matrix.group}} -- {{matrix.runtime}}"
55
matrix:
66
setup:
77
version:
@@ -48,6 +48,54 @@ steps:
4848
if: build.message !~ /\[skip tests\]/
4949
timeout_in_minutes: 120
5050

51+
- group: ":test_tube: Intel GPU (SYCL) Tests"
52+
steps:
53+
- label: ":julia: :linux: Julia v{{matrix.julia}} -- {{matrix.group}} -- {{matrix.runtime}}"
54+
matrix:
55+
setup:
56+
version:
57+
- "1.10"
58+
group:
59+
- core
60+
runtime:
61+
- "PJRT"
62+
- "IFRT"
63+
plugins:
64+
- JuliaCI/julia#v1:
65+
version: "{{matrix.version}}"
66+
- JuliaCI/julia-coverage#v1:
67+
codecov: true
68+
dirs:
69+
- src
70+
- ext
71+
- lib/ReactantCore/src
72+
commands: |
73+
touch LocalPreferences.toml
74+
75+
echo "[Reactant]" >> LocalPreferences.toml
76+
echo "xla_runtime = \"{{matrix.runtime}}\"" >> LocalPreferences.toml
77+
78+
cat LocalPreferences.toml
79+
80+
julia --project=. -e 'println("--- :julia: Instantiating project")
81+
using Pkg
82+
Pkg.develop([PackageSpec(path="lib/ReactantCore")])'
83+
84+
julia --project=. -e 'println("--- :julia: Run Tests")
85+
using Pkg
86+
Pkg.test(; coverage="user")'
87+
env:
88+
REACTANT_TEST_GROUP: "{{matrix.group}}"
89+
JULIA_DEBUG: "Reactant,Reactant_jll"
90+
REACTANT_BACKEND_GROUP: "GPU"
91+
REACTANT_TEST_ONLY_PLUGIN: "true"
92+
agents:
93+
queue: "juliagpu"
94+
intel: "*"
95+
if: build.message !~ /\[skip tests\]/
96+
timeout_in_minutes: 60
97+
98+
5199
# - group: ":racehorse: Benchmarks"
52100
# steps:
53101
# - label: "CPU: Run Benchmarks"

test/runtests.jl

Lines changed: 28 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,9 @@ if lowercase(get(ENV, "REACTANT_BACKEND_GROUP", "all")) == "gpu"
55
end
66

77
const REACTANT_TEST_GROUP = lowercase(get(ENV, "REACTANT_TEST_GROUP", "all"))
8+
const REACTANT_TEST_ONLY_PLUGIN = parse(
9+
Bool, get(ENV, "REACTANT_TEST_ONLY_PLUGIN", "false")
10+
)
811

912
@testset "Reactant.jl Tests" begin
1013
if REACTANT_TEST_GROUP == "all" || REACTANT_TEST_GROUP == "core"
@@ -16,30 +19,32 @@ const REACTANT_TEST_GROUP = lowercase(get(ENV, "REACTANT_TEST_GROUP", "all"))
1619
@safetestset "Intel XPU Plugin" include("plugins/sycl.jl")
1720
end
1821

19-
@safetestset "Layout" include("layout.jl")
20-
@safetestset "Tracing" include("tracing.jl")
21-
@safetestset "Basic" include("basic.jl")
22-
@safetestset "Autodiff" include("autodiff.jl")
23-
@safetestset "Complex" include("complex.jl")
24-
@safetestset "Broadcast" include("bcast.jl")
25-
@safetestset "Struct" include("struct.jl")
26-
@safetestset "Closure" include("closure.jl")
27-
@safetestset "Compile" include("compile.jl")
28-
@safetestset "IR" include("ir.jl")
29-
@safetestset "Buffer Donation" include("buffer_donation.jl")
30-
@safetestset "Shortcuts to MLIR ops" include("ops.jl")
31-
@safetestset "Wrapped Arrays" include("wrapped_arrays.jl")
32-
@safetestset "Control Flow" include("control_flow.jl")
33-
@safetestset "Sorting" include("sorting.jl")
34-
@safetestset "Indexing" include("indexing.jl")
35-
if !Sys.isapple()
36-
@safetestset "Custom Number Types" include("custom_number_types.jl")
22+
if !REACTANT_TEST_ONLY_PLUGIN
23+
@safetestset "Layout" include("layout.jl")
24+
@safetestset "Tracing" include("tracing.jl")
25+
@safetestset "Basic" include("basic.jl")
26+
@safetestset "Autodiff" include("autodiff.jl")
27+
@safetestset "Complex" include("complex.jl")
28+
@safetestset "Broadcast" include("bcast.jl")
29+
@safetestset "Struct" include("struct.jl")
30+
@safetestset "Closure" include("closure.jl")
31+
@safetestset "Compile" include("compile.jl")
32+
@safetestset "IR" include("ir.jl")
33+
@safetestset "Buffer Donation" include("buffer_donation.jl")
34+
@safetestset "Shortcuts to MLIR ops" include("ops.jl")
35+
@safetestset "Wrapped Arrays" include("wrapped_arrays.jl")
36+
@safetestset "Control Flow" include("control_flow.jl")
37+
@safetestset "Sorting" include("sorting.jl")
38+
@safetestset "Indexing" include("indexing.jl")
39+
if !Sys.isapple()
40+
@safetestset "Custom Number Types" include("custom_number_types.jl")
41+
end
42+
@safetestset "Sharding" include("sharding.jl")
43+
@safetestset "Comm Optimization" include("optimize_comm.jl")
44+
@safetestset "Cluster Detection" include("cluster_detector.jl")
45+
@safetestset "Config" include("config.jl")
46+
@safetestset "Batching" include("batching.jl")
3747
end
38-
@safetestset "Sharding" include("sharding.jl")
39-
@safetestset "Comm Optimization" include("optimize_comm.jl")
40-
@safetestset "Cluster Detection" include("cluster_detector.jl")
41-
@safetestset "Config" include("config.jl")
42-
@safetestset "Batching" include("batching.jl")
4348
end
4449

4550
if REACTANT_TEST_GROUP == "all" || REACTANT_TEST_GROUP == "integration"

0 commit comments

Comments
 (0)