Skip to content

Use JuliaGPU's GitLab CI setup #111

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 1 commit into from
Jun 10, 2020
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
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
.DS_Store
/Manifest.toml
Manifest.toml
/dev/
76 changes: 16 additions & 60 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
@@ -1,60 +1,16 @@
image: "julia:1"

variables:
JULIA_DEPOT_PATH: "$CI_PROJECT_DIR/.julia/"
JULIA_NUM_THREADS: '4'

cache:
paths:
- .julia/

stages:
- build
- test

build:
stage: build
tags:
- 'p6000'
script:
- curl https://julialang-s3.julialang.org/bin/linux/x64/1.3/julia-1.3.0-linux-x86_64.tar.gz -o julia.tar.gz
- unp julia.tar.gz
- export PATH="$(pwd)/julia-1.3.0/bin:$PATH"
- julia -e "using InteractiveUtils;
versioninfo()"
- julia --project -e "using Pkg; Pkg.build(); using SparseDiffTools"
only:
- master
- tags
- external
- pushes
artifacts:
untracked: true
paths:
- .julia/**/*
- julia-1.3.0/**/*

test-GPU:
stage: test
tags:
- 'p6000'
dependencies:
- build
variables:
GROUP: "GPU"
script:
- export PATH="$(pwd)/julia-1.3.0/bin:$PATH"
- julia -e "using InteractiveUtils;
versioninfo()"
- julia --project -e "using Pkg; Pkg.add(\"CuArrays\");
Pkg.test(\"SparseDiffTools\"; coverage=true);"
only:
- master
- tags
- external
- pushes
artifacts:
untracked: true
paths:
- .julia/**/*
- julia-1.3.0/**/*
include: https://raw.githubusercontent.com/JuliaGPU/gitlab-ci/master/templates/v6.yml

variables:
JULIA_NUM_THREADS: 4

.base:
extends:
- .julia:1.4
- .test
tags:
- nvidia

test-GPU:
extends: .base
variables:
GROUP: GPU
3 changes: 2 additions & 1 deletion Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ julia = "1.2"
BandedMatrices = "aae01518-5342-5314-be14-df237901396f"
BlockBandedMatrices = "ffab5731-97b5-5995-9138-79e8c1846df0"
IterativeSolvers = "42fd0dbc-a981-5370-80f2-aaf504508153"
Pkg = "44cfe95a-1eb2-52ea-b672-e2afdf69b78f"
Random = "9a3f8284-a2c9-5f02-9a11-845980a1fd5c"
SafeTestsets = "1bc83da4-3b8d-516f-aca4-4fe02f6d838f"
SparsityDetection = "684fba80-ace3-11e9-3d08-3bc7ed6f96df"
Expand All @@ -40,4 +41,4 @@ Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"
Zygote = "e88e6eb3-aa80-5325-afca-941959d7151f"

[targets]
test = ["Test", "BandedMatrices", "BlockBandedMatrices", "IterativeSolvers", "Random", "SafeTestsets", "Zygote", "SparsityDetection", "StaticArrays"]
test = ["Test", "BandedMatrices", "BlockBandedMatrices", "IterativeSolvers", "Pkg", "Random", "SafeTestsets", "Zygote", "SparsityDetection", "StaticArrays"]
2 changes: 2 additions & 0 deletions test/gpu/Project.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
[deps]
CuArrays = "3a865a2d-5b23-5a0f-bc46-62713ec82fae"
8 changes: 8 additions & 0 deletions test/runtests.jl
Original file line number Diff line number Diff line change
@@ -1,9 +1,16 @@
using Pkg
using SafeTestsets

const GROUP = get(ENV, "GROUP", "All")
const is_APPVEYOR = ( Sys.iswindows() && haskey(ENV,"APPVEYOR") )
const is_TRAVIS = haskey(ENV,"TRAVIS")

function activate_gpu_env()
Pkg.activate("gpu")
Pkg.develop(PackageSpec(path=dirname(@__DIR__)))
Pkg.instantiate()
end

if GROUP == "All"
@time @safetestset "Exact coloring via contraction" begin include("test_contraction.jl") end
@time @safetestset "Greedy distance-1 coloring" begin include("test_greedy_d1.jl") end
Expand All @@ -17,5 +24,6 @@ if GROUP == "All"
end

if GROUP == "GPU"
activate_gpu_env()
@time @safetestset "GPU AD" begin include("test_gpu_ad.jl") end
end