2 FDO_UPSTREAM_REPO: mesa/mesa
5 - project: 'freedesktop/ci-templates'
6 ref: 4b2997287317808830e9cb4eb0f99b691787da88
7 file: '/templates/debian.yml'
8 - local: '.gitlab-ci/lava-gitlab-ci.yml'
9 - local: '.gitlab-ci/test-source-dep.yml'
26 # When to automatically run the CI
29 # If any files affecting the pipeline are changed, build/test jobs run
30 # automatically once all dependency jobs have passed
49 # Otherwise, build/test jobs won't run
54 - runner_system_failure
55 # Cancel CI run if a newer commit is pushed to the same branch
60 image: debian:stable-slim
69 - echo "Dummy job to make sure every merge request pipeline runs at least one job"
74 name: "mesa_${CI_JOB_NAME}"
78 # Watch out! Artifacts are relative to the build dir.
79 # https://gitlab.com/gitlab-org/gitlab-ce/commit/8788fb925706cad594adf6917a6c5f6587dd1521
82 # Build the CI docker images.
84 # FDO_DISTRIBUTION_TAG is the tag of the docker image used by later stage jobs. If the
85 # image doesn't exist yet, the container stage job generates it.
87 # In order to generate a new image, one should generally change the tag.
88 # While removing the image from the registry would also work, that's not
89 # recommended except for ephemeral images during development: Replacing
90 # an image after a significant amount of time might pull in newer
91 # versions of gcc/clang or other packages, which might break the build
92 # with older commits using the same tag.
94 # After merging a change resulting in generating a new image to the
95 # main repository, it's recommended to remove the image from the source
96 # repository's container registry, so that the image from the main
97 # repository's registry will be used there as well.
104 # Run pipeline by default if it was triggered by Marge Bot, is for a
105 # merge request, and any files affecting it were changed
106 - if: '$GITLAB_USER_LOGIN == "marge-bot" && $CI_MERGE_REQUEST_SOURCE_BRANCH_NAME == $CI_COMMIT_REF_NAME'
110 # Run pipeline by default in the main project if any files affecting it were
112 - if: '$CI_PROJECT_PATH == "mesa/mesa"'
116 # Allow triggering jobs manually for MRs or branches of forked projects if
117 # any files affecting the pipeline were changed
121 # Otherwise, container jobs won't run
124 FDO_DISTRIBUTION_VERSION: buster-slim
125 FDO_REPO_SUFFIX: "debian/$CI_JOB_NAME"
126 FDO_DISTRIBUTION_EXEC: 'bash .gitlab-ci/container/${CI_JOB_NAME}.sh'
127 # no need to pull the whole repo to build the container image
130 # Debian 10 based x86 build image
133 - .fdo.container-build@debian
136 FDO_DISTRIBUTION_TAG: &x86_build "2020-04-22-winehq"
141 image: "$CI_REGISTRY_IMAGE/debian/x86_build:$TAG"
145 # Debian 10 based x86 test image for GL
149 FDO_DISTRIBUTION_TAG: &x86_test-gl "2020-04-21"
151 # Debian 10 based x86 test image for VK
155 FDO_DISTRIBUTION_TAG: &x86_test-vk "2020-04-09"
157 # Debian 9 based x86 build image (old LLVM)
161 FDO_DISTRIBUTION_TAG: &x86_build_old "2019-03-18-jflags"
162 FDO_DISTRIBUTION_VERSION: stretch-slim
167 image: "$CI_REGISTRY_IMAGE/debian/x86_build_old:$TAG"
171 # Debian 10 based ARM build image
174 - .fdo.container-build@debian@arm64v8
177 FDO_DISTRIBUTION_TAG: &arm_build "2020-04-01-jflags"
182 image: "$CI_REGISTRY_IMAGE/debian/arm_build:$TAG"
186 # Debian 10 based ARM test image
190 FDO_DISTRIBUTION_TAG: &arm_test "2020-03-18-jflags"
195 image: "$CI_REGISTRY_IMAGE/debian/arm_test:$TAG"
200 # Native Windows docker builds
202 # Unlike the above Linux-based builds - including MinGW/SCons builds which
203 # cross-compile for Windows - which use the freedesktop ci-templates, we
204 # cannot use the same scheme here. As Windows lacks support for
205 # Docker-in-Docker, and Podman does not run natively on Windows, we have
206 # to open-code much of the same ourselves.
208 # This is achieved by first running in a native Windows shell instance
209 # (host PowerShell) in the container stage to build and push the image,
210 # then in the build stage by executing inside Docker.
212 .windows-docker-vs2019:
214 WINDOWS_TAG: "2020-03-24"
215 WINDOWS_IMAGE: "$CI_REGISTRY_IMAGE/windows/x64_build:$WINDOWS_TAG"
216 WINDOWS_UPSTREAM_IMAGE: "$CI_REGISTRY/$FDO_UPSTREAM_REPO/windows/x64_build:$WINDOWS_TAG"
218 windows_build_vs2019:
221 - .windows-docker-vs2019
224 GIT_STRATEGY: fetch # we do actually need the full repository though
231 - .\.gitlab-ci\windows\mesa_container.ps1 $CI_REGISTRY $CI_REGISTRY_USER $CI_REGISTRY_PASSWORD $WINDOWS_IMAGE $WINDOWS_UPSTREAM_IMAGE
233 .use-windows_build_vs2019:
234 extends: .windows-docker-vs2019
235 image: "$WINDOWS_IMAGE"
237 - windows_build_vs2019
241 # Shared between windows and Linux
243 extends: .ci-run-policy
245 name: "mesa_${CI_JOB_NAME}"
248 - _build/meson-logs/*.txt
255 extends: .build-common
257 CCACHE_COMPILERCHECK: "content"
258 CCACHE_COMPRESS: "true"
259 CCACHE_DIR: /cache/mesa/ccache
260 # Use ccache transparently, and print stats before/after
262 - export PATH="/usr/lib/ccache:$PATH"
263 - export CCACHE_BASEDIR="$PWD"
264 - ccache --show-stats
266 - ccache --show-stats
269 extends: .build-common
278 - subprojects/packagecache
288 - .gitlab-ci/meson-build.sh
298 - .gitlab-ci/scons-build.sh
310 -D platforms=x11,drm,surfaceless
313 GALLIUM_DRIVERS: "swrast,virgl"
315 BUILDTYPE: "debugoptimized"
319 - .gitlab-ci/meson-build.sh
320 - .gitlab-ci/prepare-artifacts.sh
323 extends: .meson-build
330 -D platforms=x11,wayland,drm,surfaceless
333 -D gallium-extra-hud=true
334 -D gallium-vdpau=true
336 -D gallium-omx=bellagio
340 -D gallium-opencl=disabled
341 GALLIUM_DRIVERS: "iris,nouveau,kmsro,r300,r600,freedreno,swr,swrast,svga,v3d,vc4,virgl,etnaviv,panfrost,lima,zink"
346 - .gitlab-ci/meson-build.sh
347 - .gitlab-ci/run-shader-db.sh
350 extends: .meson-build
357 -D platforms=x11,wayland,drm,surfaceless
373 -D platforms=surfaceless
377 -D gallium-vdpau=false
378 -D gallium-xvmc=false
379 -D gallium-omx=disabled
382 -D gallium-nine=false
390 VULKAN_DRIVERS: freedreno
391 GALLIUM_DRIVERS: "etnaviv,freedreno,kmsro,lima,nouveau,panfrost,swrast,tegra,v3d,vc4"
392 BUILDTYPE: "debugoptimized"
406 - .gitlab-ci/meson-build.sh
407 - .gitlab-ci/prepare-artifacts.sh
414 VULKAN_DRIVERS: "freedreno"
418 - .gitlab-ci/meson-build.sh
419 - .gitlab-ci/prepare-artifacts.sh
421 meson-arm64-build-test:
426 VULKAN_DRIVERS: "amd"
428 - .gitlab-ci/meson-build.sh
431 extends: .meson-build
437 GALLIUM_DRIVERS: "auto"
438 VULKAN_DRIVERS: intel,amd,freedreno
440 CXX: "ccache clang++-9"
442 meson-windows-vs2019:
445 - .use-windows_build_vs2019
448 - . .\.gitlab-ci\windows\mesa_build.ps1
451 extends: .scons-build
453 SCONS_TARGET: platform=windows machine=x86_64 debug=1
454 SCONS_CHECK_COMMAND: "true"
458 extends: .meson-build
467 -D gallium-vdpau=false
468 -D gallium-xvmc=false
469 -D gallium-omx=disabled
472 -D gallium-nine=false
473 -D gallium-opencl=icd
475 - export GALLIUM_DRIVERS="r600,radeonsi"
476 - .gitlab-ci/meson-build.sh
477 - LLVM_VERSION=8 .gitlab-ci/meson-build.sh
478 - export GALLIUM_DRIVERS="i915,r600"
479 - LLVM_VERSION=6.0 .gitlab-ci/meson-build.sh
480 - LLVM_VERSION=7 .gitlab-ci/meson-build.sh
482 meson-clover-old-llvm:
492 -D platforms=drm,surfaceless
493 GALLIUM_DRIVERS: "i915,r600"
495 - LLVM_VERSION=3.9 .gitlab-ci/meson-build.sh
496 - LLVM_VERSION=4.0 .gitlab-ci/meson-build.sh
497 - LLVM_VERSION=5.0 .gitlab-ci/meson-build.sh
500 extends: .meson-build
507 -D platforms=x11,wayland,drm
511 -D gallium-vdpau=false
512 -D gallium-xvmc=false
513 -D gallium-omx=disabled
516 -D gallium-nine=false
517 -D gallium-opencl=disabled
518 -D b_sanitize=undefined
519 -D c_args=-fno-sanitize-recover=all
520 -D cpp_args=-fno-sanitize-recover=all
521 UBSAN_OPTIONS: "print_stacktrace=1"
522 VULKAN_DRIVERS: intel,amd,freedreno
524 -D vulkan-overlay-layer=true
528 extends: .meson-cross
531 VULKAN_DRIVERS: intel,amd
532 GALLIUM_DRIVERS: "iris,r300,radeonsi,swrast,virgl"
534 -D vulkan-overlay-layer=true
537 - dpkg -i /var/cache/apt/archives/$CROSS/*.deb
538 - .gitlab-ci/meson-build.sh
547 GALLIUM_DRIVERS: "swrast"
549 # For unknown reasons "too many" installed i386 libraries cause qemu to
550 # crash while executing llvm-config for s390x.
551 - apt-get purge -y winehq-stable
552 - apt-get autoremove -y --purge
553 - dpkg -i /var/cache/apt/archives/$CROSS/*.deb
554 - .gitlab-ci/meson-build.sh
561 GALLIUM_DRIVERS: "nouveau,radeonsi,swrast,virgl"
562 VULKAN_DRIVERS: "amd"
564 meson-mingw32-x86_64:
565 extends: .meson-build
570 GALLIUM_DRIVERS: "swrast"
574 --cross-file=.gitlab-ci/x86_64-w64-mingw32
580 GIT_STRATEGY: none # testing doesn't build anything from source
582 # Note: Build dir (and thus install) may be dirty due to GIT_STRATEGY
584 - tar -xf artifacts/install.tar
585 - LD_LIBRARY_PATH=install/lib find install/lib -name "*.so" -print -exec ldd {} \;
588 name: "mesa_${CI_JOB_NAME}"
599 image: "$CI_REGISTRY_IMAGE/debian/x86_test-gl:$TAG"
609 image: "$CI_REGISTRY_IMAGE/debian/x86_test-vk:$TAG"
620 name: "mesa_${CI_JOB_NAME}"
624 LIBGL_ALWAYS_SOFTWARE: 1
627 - install/piglit/run.sh
630 extends: .piglit-test
635 --process-isolation false
638 -x egl_ext_platform_device
639 -x ext_timer_query@time-elapsed
640 -x glx-multithread-clearbuffer
641 -x glx-multithread-shader-compile
644 PIGLIT_PROFILES: quick_gl
647 extends: .piglit-test
651 PIGLIT_PROFILES: glslparser
654 extends: .piglit-test
658 PIGLIT_PROFILES: quick_shader
662 DEQP_SKIPS: deqp-default-skips.txt
664 - ./install/deqp-runner.sh
681 - ./install/fossilize-runner.sh
688 # Don't use threads inside llvmpipe, we've already got all 4 cores
689 # busy with DEQP_PARALLEL.
691 DEQP_EXPECTED_FAILS: deqp-llvmpipe-fails.txt
692 LIBGL_ALWAYS_SOFTWARE: "true"
693 DEQP_EXPECTED_RENDERER: llvmpipe
703 DEQP_EXPECTED_FAILS: deqp-softpipe-fails.txt
704 DEQP_SKIPS: deqp-softpipe-skips.txt
705 GALLIUM_DRIVER: "softpipe"
706 DEQP_EXPECTED_RENDERER: softpipe
712 extends: softpipe-gles2
718 extends: softpipe-gles2
725 DEQP_NO_SAVE_RESULTS: 1
726 # Don't use threads inside llvmpipe, we've already got all 4 cores
727 # busy with DEQP_PARALLEL.
729 DEQP_EXPECTED_FAILS: deqp-virgl-fails.txt
730 LIBGL_ALWAYS_SOFTWARE: "true"
731 GALLIUM_DRIVER: "virpipe"
732 DEQP_EXPECTED_RENDERER: virgl
742 DEQP_RUNNER_OPTIONS: "--timeout 120"
750 DEQP_OPTIONS: "--deqp-log-images=disable"
751 DEQP_RUNNER_OPTIONS: "--timeout 120"
752 MESA_GLES_VERSION_OVERRIDE: "3.1"
753 MESA_GLSL_VERSION_OVERRIDE: "310"
756 # Rules for tests that should not be present in MRs or the main
757 # project's pipeline (don't block marge or report red on
758 # mesa/mesamaster) but should be present on pipelines in personal
759 # branches (so you can opt in to running the flaky test when you want
763 - if: '$CI_PROJECT_PATH != "mesa/mesa" && $CI_MERGE_REQUEST_SOURCE_BRANCH_NAME != $CI_COMMIT_REF_NAME'
776 DEQP_EXPECTED_FAILS: deqp-freedreno-a630-fails.txt
777 DEQP_SKIPS: deqp-freedreno-a630-skips.txt
780 FLAKES_CHANNEL: "#freedreno-ci"
781 DEQP_EXPECTED_RENDERER: FD630
788 extends: arm64_a630_gles2
793 extends: arm64_a630_gles2
797 arm64_a630_gles31_options:
798 extends: arm64_a630_gles2
804 # We almost always manage to lower UBOs back to constant uploads in
805 # the test suite, so get a little testing for it here.
806 - DEQP_RUN_SUFFIX=-nouboopt IR3_SHADER_DEBUG=nouboopt DEQP_EXPECTED_FAILS=deqp-freedreno-a630-noubo-fails.txt DEQP_CASELIST_FILTER="functional.\*ubo" ./install/deqp-runner.sh
807 # The driver does some guessing as to whether to render using gmem
808 # or bypass, and some GLES3.1 features interact with either one.
809 # Do a little testing with gmem and bypass forced.
810 - DEQP_RUN_SUFFIX=-bypass FD_MESA_DEBUG=nogmem DEQP_EXPECTED_FAILS=deqp-freedreno-a630-bypass-fails.txt ./install/deqp-runner.sh
811 - DEQP_RUN_SUFFIX=-gmem FD_MESA_DEBUG=nobypass ./install/deqp-runner.sh
824 BM_KERNEL: /lava-files/Image.gz
825 BM_DTB: /lava-files/apq8016-sbc.dtb
826 BM_ROOTFS: /lava-files/rootfs-arm64
827 BM_CMDLINE: "ip=dhcp console=ttyMSM0,115200n8"
828 DEQP_EXPECTED_FAILS: deqp-freedreno-a307-fails.txt
829 DEQP_SKIPS: deqp-freedreno-a307-skips.txt
832 DEQP_EXPECTED_RENDERER: FD307
834 - .gitlab-ci/bare-metal/fastboot.sh
838 - google-freedreno-db410c
840 # Disabled due to flaky results
854 BM_KERNEL: /lava-files/db820c-kernel
855 BM_DTB: /lava-files/db820c.dtb
856 BM_CMDLINE: "ip=dhcp console=ttyMSM0,115200n8"
857 DEQP_EXPECTED_FAILS: deqp-freedreno-a530-fails.txt
858 DEQP_SKIPS: deqp-freedreno-a530-skips.txt
859 DEQP_EXPECTED_RENDERER: FD530
861 - google-freedreno-db820c
886 .test-radv-fossilize:
891 - ./install/fossilize-runner.sh
892 - ACO_DEBUG=validateir,validatera RADV_PERFTEST=aco ./install/fossilize-runner.sh
894 # Can only be triggered manually on personal branches because RADV is the only
895 # driver that does Vulkan testing at the moment.
896 radv_polaris10_vkcts:
902 DEQP_SKIPS: deqp-radv-polaris10-skips.txt
912 - export RADV_FORCE_FAMILY="polaris10"
913 - ./install/fossilize-runner.sh
914 - ACO_DEBUG=validateir,validatera RADV_PERFTEST=aco ./install/fossilize-runner.sh
916 - export RADV_FORCE_FAMILY="gfx900"
917 - ./install/fossilize-runner.sh
918 - ACO_DEBUG=validateir,validatera RADV_PERFTEST=aco ./install/fossilize-runner.sh
920 - export RADV_FORCE_FAMILY="gfx1010"
921 - ./install/fossilize-runner.sh
922 - ACO_DEBUG=validateir,validatera RADV_PERFTEST=aco ./install/fossilize-runner.sh
936 - ./install/tracie-runner-gl.sh
943 - ./install/tracie-runner-vk.sh
950 LIBGL_ALWAYS_SOFTWARE: "true"
951 GALLIUM_DRIVER: "llvmpipe"
952 DEVICE_NAME: "gl-vmware-llvmpipe"
954 radv-polaris10-traces:
960 DEVICE_NAME: "vk-amd-polaris10"
969 LIBGL_ALWAYS_SOFTWARE: "true"
970 GALLIUM_DRIVER: "virpipe"
971 DEVICE_NAME: "gl-virgl"
972 MESA_GLES_VERSION_OVERRIDE: "3.1"
973 MESA_GLSL_VERSION_OVERRIDE: "310"