blob: 579afee96f6981bae4e809eed70eb02a90a801b7 [file] [log] [blame]
Eric Engestrom329f5cd2019-01-20 11:21:45 +00001# This is the tag of the docker image used for the build jobs. If the
Eric Engestroma0f8a072019-09-11 18:51:46 +01002# image doesn't exist yet, the containers stage generates it.
Eric Engestrom329f5cd2019-01-20 11:21:45 +00003#
4# In order to generate a new image, one should generally change the tag.
5# While removing the image from the registry would also work, that's not
6# recommended except for ephemeral images during development: Replacing
7# an image after a significant amount of time might pull in newer
8# versions of gcc/clang or other packages, which might break the build
9# with older commits using the same tag.
10#
11# After merging a change resulting in generating a new image to the
12# main repository, it's recommended to remove the image from the source
13# repository's container registry, so that the image from the main
14# repository's registry will be used there as well.
Eric Engestrom329f5cd2019-01-20 11:21:45 +000015variables:
Benjamin Tissoires7f8a9a12019-04-02 09:24:00 +020016 UPSTREAM_REPO: mesa/mesa
Adam Jackson3c553d9cf2019-09-06 09:29:32 +020017 DEBIAN_TAG: "2019-09-11"
Eric Anholt6f0dc082019-06-28 16:35:32 -070018 DEBIAN_ARM64_TAG: "arm64v8-2019-08-09"
Michel Dänzerd00b1c42019-04-02 16:56:54 +020019 DEBIAN_VERSION: stretch-slim
Eric Anholt6f0dc082019-06-28 16:35:32 -070020 DEBIAN_ARM64_VERSION: buster-slim
Michel Dänzerd00b1c42019-04-02 16:56:54 +020021 DEBIAN_IMAGE: "$CI_REGISTRY_IMAGE/debian/$DEBIAN_VERSION:$DEBIAN_TAG"
Eric Anholt6f0dc082019-06-28 16:35:32 -070022 DEBIAN_ARM64_IMAGE: "$CI_REGISTRY_IMAGE/debian/$DEBIAN_ARM64_VERSION:$DEBIAN_ARM64_TAG"
Benjamin Tissoires7f8a9a12019-04-02 09:24:00 +020023
24include:
25 - project: 'wayland/ci-templates'
Eric Anholt6f0dc082019-06-28 16:35:32 -070026 ref: 1f7f57c6
Michel Dänzerd00b1c42019-04-02 16:56:54 +020027 file: '/templates/debian.yml'
Eric Engestrom329f5cd2019-01-20 11:21:45 +000028
Eric Engestrom329f5cd2019-01-20 11:21:45 +000029stages:
Eric Engestroma0f8a072019-09-11 18:51:46 +010030 - containers
31 - build
Eric Anholt46daaca2019-06-28 16:35:32 -070032 - test
Eric Engestrom329f5cd2019-01-20 11:21:45 +000033
34
Eric Engestrom7f5d9c22019-02-22 15:52:08 +000035# When to automatically run the CI
Michel Dänzere426f402019-09-06 17:35:52 +020036.ci-run-policy:
Eric Engestrom7f5d9c22019-02-22 15:52:08 +000037 only:
Michel Dänzerb48e64f2019-04-10 10:33:13 +020038 - branches@mesa/mesa
Eric Engestrom7f5d9c22019-02-22 15:52:08 +000039 - merge_requests
40 - /^ci([-/].*)?$/
Michel Dänzer6140ed32019-03-26 18:39:41 +010041 retry:
42 max: 2
43 when:
44 - runner_system_failure
Eric Engestrom7f5d9c22019-02-22 15:52:08 +000045
Michel Dänzere426f402019-09-06 17:35:52 +020046.ci-deqp-artifacts:
Eric Anholt46daaca2019-06-28 16:35:32 -070047 artifacts:
48 when: always
49 untracked: false
50 paths:
51 # Watch out! Artifacts are relative to the build dir.
52 # https://gitlab.com/gitlab-org/gitlab-ce/commit/8788fb925706cad594adf6917a6c5f6587dd1521
53 - artifacts
Eric Engestrom7f5d9c22019-02-22 15:52:08 +000054
Eric Anholt6f0dc082019-06-28 16:35:32 -070055# Builds the normal CI native and cross-build docker image.
Michel Dänzerd00b1c42019-04-02 16:56:54 +020056debian:
Michel Dänzere426f402019-09-06 17:35:52 +020057 extends:
58 - .debian@container-ifnot-exists
59 - .ci-run-policy
Eric Engestroma0f8a072019-09-11 18:51:46 +010060 stage: containers
Eric Engestrom329f5cd2019-01-20 11:21:45 +000061 variables:
Benjamin Tissoires7f8a9a12019-04-02 09:24:00 +020062 GIT_STRATEGY: none # no need to pull the whole tree for rebuilding the image
Michel Dänzerd00b1c42019-04-02 16:56:54 +020063 DEBIAN_EXEC: 'bash .gitlab-ci/debian-install.sh'
Eric Engestrom46d23c02019-01-20 11:26:53 +000064
Eric Anholt6f0dc082019-06-28 16:35:32 -070065# Builds a Docker image with the native environment and VK-GL-CTS for testing.
66test-container:arm64:
Michel Dänzere426f402019-09-06 17:35:52 +020067 extends:
68 - .debian@container-ifnot-exists@arm64v8
69 - .ci-run-policy
Eric Engestroma0f8a072019-09-11 18:51:46 +010070 stage: containers
Eric Anholt6f0dc082019-06-28 16:35:32 -070071 variables:
72 DEBIAN_TAG: "$DEBIAN_ARM64_TAG"
73 DEBIAN_VERSION: "$DEBIAN_ARM64_VERSION"
74 GIT_STRATEGY: none # no need to pull the whole tree for rebuilding the image
75 DEBIAN_EXEC: 'bash .gitlab-ci/debian-test-install.sh'
Eric Engestrom46d23c02019-01-20 11:26:53 +000076
77# BUILD
78
79.build:
Michel Dänzere426f402019-09-06 17:35:52 +020080 extends: .ci-run-policy
Michel Dänzerd00b1c42019-04-02 16:56:54 +020081 image: $DEBIAN_IMAGE
Eric Engestroma0f8a072019-09-11 18:51:46 +010082 stage: build
Michel Dänzera3f34f92019-03-26 18:35:59 +010083 cache:
84 paths:
85 - ccache
Eric Engestrom46d23c02019-01-20 11:26:53 +000086 artifacts:
Eric Anholtdd3d0b22019-07-24 09:27:48 -070087 when: always
88 paths:
89 - _build/meson-logs/*.txt
90 # scons:
Michel Dänzer5229f272019-07-26 12:20:41 +020091 - build/*/config.log
Eric Anholtf60defa2019-04-10 15:59:12 -070092 - shader-db
Michel Dänzere9de19f2019-04-04 18:01:27 +020093 variables:
94 CCACHE_COMPILERCHECK: "content"
Eric Engestrom23b485c2019-02-12 16:59:27 +000095 # Use ccache transparently, and print stats before/after
96 before_script:
97 - export PATH="/usr/lib/ccache:$PATH"
98 - export CCACHE_BASEDIR="$PWD"
99 - export CCACHE_DIR="$PWD/ccache"
Eric Engestrom23b485c2019-02-12 16:59:27 +0000100 - ccache --zero-stats || true
101 - ccache --show-stats || true
102 after_script:
Eric Anholt46daaca2019-06-28 16:35:32 -0700103 # In case the install dir is being saved as artifacts, tar it up
104 # so that symlinks and hardlinks aren't each packed separately in
105 # the zip file.
106 - if [ -d install ]; then
107 tar -cf artifacts/install.tar install;
108 fi
Eric Engestrom23b485c2019-02-12 16:59:27 +0000109 - export CCACHE_DIR="$PWD/ccache"
110 - ccache --show-stats
Eric Engestrom46d23c02019-01-20 11:26:53 +0000111
112.meson-build:
113 extends: .build
Eric Engestrom23b485c2019-02-12 16:59:27 +0000114 script:
Michel Dänzercc2b3a92019-05-03 10:49:43 +0200115 - .gitlab-ci/meson-build.sh
Eric Engestrom46d23c02019-01-20 11:26:53 +0000116
Eric Engestrom06b245b2019-01-23 15:46:10 +0000117.scons-build:
118 extends: .build
119 variables:
120 SCONSFLAGS: "-j4"
121 script:
Eric Engestromd4c6d4d2019-01-28 16:30:36 +0000122 - if test -n "$LLVM_VERSION"; then
123 export LLVM_CONFIG="llvm-config-${LLVM_VERSION}";
124 fi
Eric Engestrom06b245b2019-01-23 15:46:10 +0000125 - scons $SCONS_TARGET
126 - eval $SCONS_CHECK_COMMAND
127
Michel Dänzer42f8d5a2019-08-28 12:01:02 +0200128meson-main:
Michel Dänzere426f402019-09-06 17:35:52 +0200129 extends:
130 - .meson-build
131 - .ci-deqp-artifacts
Michel Dänzer42f8d5a2019-08-28 12:01:02 +0200132 variables:
133 UNWIND: "true"
134 DRI_LOADERS: >
135 -D glx=dri
136 -D gbm=true
137 -D egl=true
138 -D platforms=x11,wayland,drm,surfaceless
139 DRI_DRIVERS: "i915,i965,r100,r200,nouveau"
140 GALLIUM_ST: >
141 -D dri3=true
142 -D gallium-extra-hud=true
143 -D gallium-vdpau=true
144 -D gallium-xvmc=true
145 -D gallium-omx=bellagio
146 -D gallium-va=true
147 -D gallium-xa=true
148 -D gallium-nine=true
149 -D gallium-opencl=disabled
150 GALLIUM_DRIVERS: "iris,nouveau,kmsro,r300,r600,freedreno,swrast,svga,v3d,vc4,virgl,etnaviv,panfrost,lima"
151 LLVM_VERSION: "7"
152 EXTRA_OPTION: >
153 -D osmesa=gallium
154 -D tools=all
155 MESON_SHADERDB: "true"
156 BUILDTYPE: "debugoptimized"
Michel Dänzer42f8d5a2019-08-28 12:01:02 +0200157
Michel Dänzere5364462019-09-13 11:59:43 +0200158.meson-cross:
159 extends:
160 - .meson-build
161 - .ci-deqp-artifacts
162 variables:
163 UNWIND: "false"
164 DRI_LOADERS: >
165 -D glx=disabled
166 -D gbm=false
167 -D egl=true
168 -D platforms=surfaceless
169 -D osmesa=none
170 GALLIUM_ST: >
171 -D dri3=false
172 -D gallium-vdpau=false
173 -D gallium-xvmc=false
174 -D gallium-omx=disabled
175 -D gallium-va=false
176 -D gallium-xa=false
177 -D gallium-nine=false
178 -D llvm=false
179 script:
180 - .gitlab-ci/meson-build.sh
181
182meson-armhf:
183 extends: .meson-cross
184 variables:
185 CROSS: armhf
186 VULKAN_DRIVERS: freedreno
187 GALLIUM_DRIVERS: "etnaviv,freedreno,kmsro,lima,nouveau,panfrost,tegra,v3d,vc4"
188 # Disable the tests since we're cross compiling.
189 EXTRA_OPTION: >
190 -D build-tests=false
191 -D I-love-half-baked-turnips=true
192 -D vulkan-overlay-layer=true
193
194meson-arm64:
195 extends: meson-armhf
196 variables:
197 CROSS: arm64
198 BUILDTYPE: "debugoptimized"
199
Michel Dänzera2cce702019-03-20 15:58:31 +0100200# NOTE: Building SWR is 2x (yes two) times slower than all the other
201# gallium drivers combined.
202# Start this early so that it doesn't limit the total run time.
Eric Engestrom41407c62019-03-08 16:33:07 +0000203#
Eric Anholt030aa6e2019-08-07 14:05:51 -0700204# We also stick the glvnd build here, since we want non-glvnd in
205# meson-main for actual driver CI.
Eric Engestrom1291c682019-04-16 18:06:53 +0200206meson-swr-glvnd:
Michel Dänzera2cce702019-03-20 15:58:31 +0100207 extends: .meson-build
208 variables:
209 UNWIND: "true"
210 DRI_LOADERS: >
Eric Engestrom1291c682019-04-16 18:06:53 +0200211 -D glvnd=true
212 -D egl=true
Michel Dänzera2cce702019-03-20 15:58:31 +0100213 GALLIUM_ST: >
Eric Engestrom41407c62019-03-08 16:33:07 +0000214 -D dri3=true
Michel Dänzera2cce702019-03-20 15:58:31 +0100215 -D gallium-vdpau=false
216 -D gallium-xvmc=false
217 -D gallium-omx=disabled
218 -D gallium-va=false
219 -D gallium-xa=false
Eric Anholt030aa6e2019-08-07 14:05:51 -0700220 -D gallium-nine=false
Michel Dänzera2cce702019-03-20 15:58:31 +0100221 -D gallium-opencl=disabled
Eric Anholt030aa6e2019-08-07 14:05:51 -0700222 GALLIUM_DRIVERS: "swr,iris"
Michel Dänzera2cce702019-03-20 15:58:31 +0100223 LLVM_VERSION: "6.0"
224
225meson-clang:
226 extends: .meson-build
227 variables:
228 UNWIND: "true"
229 DRI_DRIVERS: "auto"
230 GALLIUM_DRIVERS: "auto"
Eric Engestrom47f419d2019-05-01 12:09:26 +0100231 VULKAN_DRIVERS: intel,amd,freedreno
Michel Dänzer3fca2b72019-04-05 10:36:29 +0200232 CC: "ccache clang-8"
233 CXX: "ccache clang++-8"
Michel Dänzere9de19f2019-04-04 18:01:27 +0200234 before_script:
235 - export CCACHE_BASEDIR="$PWD" CCACHE_DIR="$PWD/ccache"
236 - ccache --zero-stats --show-stats || true
237 # clang++ breaks if it picks up the GCC 8 directory without libstdc++.so
238 - apt-get remove -y libgcc-8-dev
Michel Dänzera2cce702019-03-20 15:58:31 +0100239
Michel Dänzer82b30092019-05-03 18:19:25 +0200240scons-swr:
241 extends: .scons-build
Eric Engestrom46d23c02019-01-20 11:26:53 +0000242 variables:
Michel Dänzer82b30092019-05-03 18:19:25 +0200243 SCONS_TARGET: "swr=1"
244 SCONS_CHECK_COMMAND: "true"
245 LLVM_VERSION: "6.0"
246
247scons-win64:
248 extends: .scons-build
249 variables:
250 SCONS_TARGET: platform=windows machine=x86_64
251 SCONS_CHECK_COMMAND: "true"
Eric Engestrom89a74672019-01-21 09:42:37 +0000252
Michel Dänzer68977152019-05-03 10:58:48 +0200253meson-clover:
Eric Engestromb5a70af2019-01-28 18:05:22 +0000254 extends: .meson-build
255 variables:
256 UNWIND: "true"
257 DRI_LOADERS: >
258 -D glx=disabled
259 -D egl=false
260 -D gbm=false
261 GALLIUM_ST: >
262 -D dri3=false
263 -D gallium-vdpau=false
264 -D gallium-xvmc=false
265 -D gallium-omx=disabled
266 -D gallium-va=false
267 -D gallium-xa=false
268 -D gallium-nine=false
269 -D gallium-opencl=icd
Michel Dänzer68977152019-05-03 10:58:48 +0200270 script:
271 - export GALLIUM_DRIVERS="r600,radeonsi"
272 - .gitlab-ci/meson-build.sh
Samuel Pitoiset7d1c0912019-08-21 11:45:25 +0200273 - LLVM_VERSION=8 .gitlab-ci/meson-build.sh
Michel Dänzer68977152019-05-03 10:58:48 +0200274 - export GALLIUM_DRIVERS="i915,r600"
275 - LLVM_VERSION=3.9 .gitlab-ci/meson-build.sh
276 - LLVM_VERSION=4.0 .gitlab-ci/meson-build.sh
277 - LLVM_VERSION=5.0 .gitlab-ci/meson-build.sh
278 - LLVM_VERSION=6.0 .gitlab-ci/meson-build.sh
Samuel Pitoiset7d1c0912019-08-21 11:45:25 +0200279 - LLVM_VERSION=7 .gitlab-ci/meson-build.sh
Eric Engestrom8dab7072019-01-28 18:09:24 +0000280
Michel Dänzer82b30092019-05-03 18:19:25 +0200281meson-vulkan:
282 extends: .meson-build
283 variables:
284 UNWIND: "false"
285 DRI_LOADERS: >
286 -D glx=disabled
287 -D gbm=false
288 -D egl=false
289 -D platforms=x11,wayland,drm
290 -D osmesa=none
291 GALLIUM_ST: >
292 -D dri3=true
293 -D gallium-vdpau=false
294 -D gallium-xvmc=false
295 -D gallium-omx=disabled
296 -D gallium-va=false
297 -D gallium-xa=false
298 -D gallium-nine=false
299 -D gallium-opencl=disabled
300 VULKAN_DRIVERS: intel,amd,freedreno
Samuel Pitoiset7d1c0912019-08-21 11:45:25 +0200301 LLVM_VERSION: "8"
Eric Engestrom5f8d29a2019-05-08 18:17:23 +0200302 EXTRA_OPTION: >
303 -D vulkan-overlay-layer=true
Michel Dänzer82b30092019-05-03 18:19:25 +0200304
Eric Anholt030aa6e2019-08-07 14:05:51 -0700305# While the main point of this build is testing the i386 cross build,
306# we also use this one to test some other options that are exclusive
307# with meson-main's choices (classic swrast and osmesa)
Eric Anholt11aa32a2019-07-11 12:58:28 -0700308meson-i386:
309 extends: .meson-cross
310 variables:
Eric Engestrom1c82fa02019-08-09 23:46:50 +0100311 CROSS: i386
Eric Anholt11aa32a2019-07-11 12:58:28 -0700312 VULKAN_DRIVERS: intel
Eric Anholt030aa6e2019-08-07 14:05:51 -0700313 DRI_DRIVERS: "swrast"
314 GALLIUM_DRIVERS: "iris"
Eric Anholt11aa32a2019-07-11 12:58:28 -0700315 # Disable i386 tests, because u_format_tests gets precision
316 # failures in dxtn unpacking
317 EXTRA_OPTION: >
318 -D build-tests=false
319 -D vulkan-overlay-layer=true
Eric Anholt030aa6e2019-08-07 14:05:51 -0700320 -D llvm=false
321 -D osmesa=classic
Eric Anholt11aa32a2019-07-11 12:58:28 -0700322
Eric Engestromfaf9e402019-02-26 14:40:29 +0000323scons-nollvm:
Eric Engestrom06b245b2019-01-23 15:46:10 +0000324 extends: .scons-build
325 variables:
326 SCONS_TARGET: "llvm=0"
327 SCONS_CHECK_COMMAND: "scons llvm=0 check"
Eric Engestromd4c6d4d2019-01-28 16:30:36 +0000328
Eric Engestromfaf9e402019-02-26 14:40:29 +0000329scons-llvm:
Eric Engestromd4c6d4d2019-01-28 16:30:36 +0000330 extends: .scons-build
331 variables:
332 SCONS_TARGET: "llvm=1"
333 SCONS_CHECK_COMMAND: "scons llvm=1 check"
Adam Jackson3c553d9cf2019-09-06 09:29:32 +0200334 LLVM_VERSION: "3.9"
Eric Anholt46daaca2019-06-28 16:35:32 -0700335
336.deqp-test:
Michel Dänzere426f402019-09-06 17:35:52 +0200337 extends: .ci-run-policy
Eric Anholt46daaca2019-06-28 16:35:32 -0700338 stage: test
339 image: $DEBIAN_IMAGE
340 variables:
341 GIT_STRATEGY: none # testing doesn't build anything from source
342 DEQP_SKIPS: deqp-default-skips.txt
343 script:
344 # Note: Build dir (and thus install) may be dirty due to GIT_STRATEGY
345 - rm -rf install
346 - tar -xf artifacts/install.tar
347 - ./artifacts/deqp-runner.sh
348 artifacts:
349 when: on_failure
350 name: "$CI_JOB_NAME-$CI_COMMIT_REF_NAME"
351 paths:
352 - results/
Michel Dänzercccb68b2019-09-13 11:13:12 +0200353 dependencies:
354 - meson-main
355 needs: [meson-main]
Eric Anholt46daaca2019-06-28 16:35:32 -0700356
357test-llvmpipe-gles2:
358 parallel: 4
359 variables:
360 DEQP_VER: gles2
361 DEQP_EXPECTED_FAILS: deqp-llvmpipe-fails.txt
362 LIBGL_ALWAYS_SOFTWARE: "true"
363 DEQP_RENDERER_MATCH: "llvmpipe"
364 extends: .deqp-test
Eric Anholt553cd822019-08-09 10:32:40 -0700365
366test-softpipe-gles2:
Michel Dänzer128581d2019-09-11 18:55:43 +0200367 extends: test-llvmpipe-gles2
Eric Anholt553cd822019-08-09 10:32:40 -0700368 variables:
Eric Anholt553cd822019-08-09 10:32:40 -0700369 DEQP_EXPECTED_FAILS: deqp-softpipe-fails.txt
Eric Anholt553cd822019-08-09 10:32:40 -0700370 DEQP_RENDERER_MATCH: "softpipe"
371 GALLIUM_DRIVER: "softpipe"
Eric Anholt553cd822019-08-09 10:32:40 -0700372
373# The GLES2 CTS run takes about 8 minutes of CPU time, while GLES3 is
374# 25 minutes. Until we can get its runtime down, just do a partial
375# (every 10 tests) run.
376test-softpipe-gles3-limited:
377 variables:
378 DEQP_VER: gles3
379 DEQP_EXPECTED_FAILS: deqp-softpipe-fails.txt
380 LIBGL_ALWAYS_SOFTWARE: "true"
381 DEQP_RENDERER_MATCH: "softpipe"
382 GALLIUM_DRIVER: "softpipe"
383 CI_NODE_INDEX: 1
384 CI_NODE_TOTAL: 10
385 extends: .deqp-test
Eric Anholt6f0dc082019-06-28 16:35:32 -0700386
Michel Dänzer128581d2019-09-11 18:55:43 +0200387arm64_a630_gles2:
Eric Anholt6f0dc082019-06-28 16:35:32 -0700388 extends: .deqp-test
Eric Anholt6f0dc082019-06-28 16:35:32 -0700389 image: $DEBIAN_ARM64_IMAGE
390 variables:
391 DEQP_VER: gles2
Eric Anholt6f0dc082019-06-28 16:35:32 -0700392 DEQP_RENDERER_MATCH: "FD630"
393 DEQP_EXPECTED_FAILS: deqp-freedreno-a630-fails.txt
394 DEQP_SKIPS: deqp-freedreno-a630-skips.txt
395 NIR_VALIDATE: 0
396 tags:
397 - mesa-cheza
398 dependencies:
399 - meson-arm64
400 needs: [ meson-arm64 ]
401
Michel Dänzer128581d2019-09-11 18:55:43 +0200402arm64_a630_gles31:
403 extends: arm64_a630_gles2
404 parallel: 4
Eric Anholt6f0dc082019-06-28 16:35:32 -0700405 variables:
Michel Dänzer128581d2019-09-11 18:55:43 +0200406 DEQP_VER: gles31
Eric Anholt6f0dc082019-06-28 16:35:32 -0700407
408arm64_a630_gles3:
409 parallel: 6
Michel Dänzer128581d2019-09-11 18:55:43 +0200410 extends: arm64_a630_gles2
Eric Anholt6f0dc082019-06-28 16:35:32 -0700411 variables:
412 DEQP_VER: gles3
413
Michel Dänzer128581d2019-09-11 18:55:43 +0200414arm64_a306_gles2:
Eric Anholt6f0dc082019-06-28 16:35:32 -0700415 parallel: 4
Michel Dänzer128581d2019-09-11 18:55:43 +0200416 extends: arm64_a630_gles2
Eric Anholt6f0dc082019-06-28 16:35:32 -0700417 variables:
Michel Dänzer128581d2019-09-11 18:55:43 +0200418 DEQP_EXPECTED_FAILS: deqp-freedreno-a307-fails.txt
419 DEQP_SKIPS: deqp-default-skips.txt
420 DEQP_RENDERER_MATCH: "FD307"
421 tags:
422 - db410c