Skip to content

Commit 3bcddea

Browse files
committed
Add Buildkite GPU CI
1 parent 9c2b0b8 commit 3bcddea

3 files changed

Lines changed: 73 additions & 10 deletions

File tree

.buildkite/pipeline.yml

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
steps:
2+
- label: "[CUDA] Julia v1.10"
3+
plugins:
4+
- JuliaCI/julia#v1:
5+
version: "1.10"
6+
- JuliaCI/julia-test#v1: ~
7+
- JuliaCI/julia-coverage#v1:
8+
codecov: false # TODO
9+
agents:
10+
queue: "juliagpu"
11+
cuda: "*"
12+
if: build.message !~ /\[skip tests\]/
13+
timeout_in_minutes: 20
14+
env:
15+
CI_USE_CUDA: "1"
16+
17+
- label: "[ROCm] Julia v1.10"
18+
plugins:
19+
- JuliaCI/julia#v1:
20+
version: "1.10"
21+
- JuliaCI/julia-test#v1: ~
22+
- JuliaCI/julia-coverage#v1:
23+
codecov: false # TODO
24+
agents:
25+
queue: "juliagpu"
26+
rocm: "*"
27+
if: build.message !~ /\[skip tests\]/
28+
timeout_in_minutes: 20
29+
env:
30+
CI_USE_ROCM: "1"
31+
32+
- label: "[Metal] Julia v1.10"
33+
plugins:
34+
- JuliaCI/julia#v1:
35+
version: "1.10"
36+
- JuliaCI/julia-test#v1: ~
37+
- JuliaCI/julia-coverage#v1:
38+
codecov: false # TODO
39+
agents:
40+
queue: "juliaecosystem"
41+
os: "macos"
42+
arch: "aarch64"
43+
if: build.message !~ /\[skip tests\]/
44+
timeout_in_minutes: 20
45+
env:
46+
CI_USE_METAL: "1"

test/Project.toml

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,9 @@
11
[deps]
2-
AMDGPU = "21141c5a-9bdb-4563-92ae-f87d6854732e"
3-
CUDA = "052768ef-5323-5732-b1bb-66c8b64840ba"
42
Dagger = "d58978e5-989f-55fb-8d15-ea34adc7bf54"
53
Distributed = "8ba89e20-285c-5b6f-9357-94700520ee1b"
64
KernelAbstractions = "63c18a36-062a-441e-b654-da1e3ab1ce7c"
75
LinearAlgebra = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e"
8-
Metal = "dde4c033-4e86-420c-a63e-0dd931031962"
6+
Pkg = "44cfe95a-1eb2-52ea-b672-e2afdf69b78f"
97
Random = "9a3f8284-a2c9-5f02-9a11-845980a1fd5c"
108
TOML = "fa267f1f-6049-4f14-aa54-33bafae1ed76"
119
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"

test/runtests.jl

Lines changed: 26 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,17 +3,36 @@ using Distributed
33
using Random
44
using LinearAlgebra
55

6-
addprocs(2, exeflags="--project")
6+
if parse(Bool, get(ENV, "CI_USE_CUDA", "false"))
7+
using Pkg
8+
Pkg.add("CUDA")
9+
end
10+
if parse(Bool, get(ENV, "CI_USE_ROCM", "false"))
11+
using Pkg
12+
Pkg.add("AMDGPU")
13+
end
14+
if parse(Bool, get(ENV, "CI_USE_METAL", "false"))
15+
using Pkg
16+
Pkg.add("Metal")
17+
end
18+
19+
addprocs(2, exeflags="--project=$(Base.active_project())")
720

821
@everywhere begin
9-
try using CUDA
10-
catch end
22+
if !parse(Bool, get(ENV, "CI", "false")) || parse(Bool, get(ENV, "CI_USE_CUDA", "false"))
23+
try using CUDA
24+
catch end
25+
end
1126

12-
try using AMDGPU
13-
catch end
27+
if !parse(Bool, get(ENV, "CI", "false")) || parse(Bool, get(ENV, "CI_USE_ROCM", "false"))
28+
try using AMDGPU
29+
catch end
30+
end
1431

15-
try using Metal
16-
catch end
32+
if !parse(Bool, get(ENV, "CI", "false")) || parse(Bool, get(ENV, "CI_USE_METAL", "false"))
33+
try using Metal
34+
catch end
35+
end
1736

1837
using Distributed, Dagger, DaggerGPU
1938
import DaggerGPU: Kernel

0 commit comments

Comments
 (0)