mesa/.gitlab-ci/container/lava_build.sh

262 lines
8.4 KiB
Bash
Raw Permalink Normal View History

#!/bin/bash
set -e
set -o xtrace
export DEBIAN_FRONTEND=noninteractive
check_minio()
{
MINIO_PATH="${MINIO_HOST}/mesa-lava/$1/${DISTRIBUTION_TAG}/${DEBIAN_ARCH}"
if wget -q --method=HEAD "https://${MINIO_PATH}/done"; then
exit
fi
}
# If remote files are up-to-date, skip rebuilding them
check_minio "${FDO_UPSTREAM_REPO}"
check_minio "${CI_PROJECT_PATH}"
. .gitlab-ci/container/container_pre_build.sh
ci/deqp: Switch to a new dEQP runner written in Rust. I found the C++ runner hard to develop on, and we had stability issues and outstanding feature needs that made me want something I felt good about hacking on. Thus, Rewrite It In Rust of the deqp runner. The new runner includes: - Skip lists don't reshuffle the test list. - Known-flake handling without resorting to skip lists (fixing our main CI reliability issue on a3xx right now). - Per-thread Vulkan shader caches should speed up VK CI runtime. - Tracking of crashes separate from fails (so we can see progress on that front). - Logging of deqp stderr spam (particularly assertion failures!) in the CI log. - Integrated QPA filtering so we don't have bash perf issues for it. - Logging of what caselist to go look at for a given error report (in red, so it's easier to find in your CI log). - The code is 1/3 unit tests, and easy to extend for more coverage. - Non-LAVA CI runs create a failures.csv in artifacts that you can check in as your deqp-*-fails.txt file. - Test runtime is included in results.csv so you can debug how to speed up your CI job. - Pretty summary at the end of the run of slow/flaky/failed tests. Since this is a new runner with a different RNG, the test groups are shuffled one more time. This seems to result in some panfrost T720 stability issues (See its new deqp-panfrost-t720-flakes.txt), and one new flake in freedreno a630. Reviewed-by: Tomeu Vizoso <tomeu.vizoso@collabora.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7434>
2020-10-29 17:29:28 +00:00
# Install rust, which we'll be using for deqp-runner. It will be cleaned up at the end.
. .gitlab-ci/container/build-rust.sh
ci/deqp: Switch to a new dEQP runner written in Rust. I found the C++ runner hard to develop on, and we had stability issues and outstanding feature needs that made me want something I felt good about hacking on. Thus, Rewrite It In Rust of the deqp runner. The new runner includes: - Skip lists don't reshuffle the test list. - Known-flake handling without resorting to skip lists (fixing our main CI reliability issue on a3xx right now). - Per-thread Vulkan shader caches should speed up VK CI runtime. - Tracking of crashes separate from fails (so we can see progress on that front). - Logging of deqp stderr spam (particularly assertion failures!) in the CI log. - Integrated QPA filtering so we don't have bash perf issues for it. - Logging of what caselist to go look at for a given error report (in red, so it's easier to find in your CI log). - The code is 1/3 unit tests, and easy to extend for more coverage. - Non-LAVA CI runs create a failures.csv in artifacts that you can check in as your deqp-*-fails.txt file. - Test runtime is included in results.csv so you can debug how to speed up your CI job. - Pretty summary at the end of the run of slow/flaky/failed tests. Since this is a new runner with a different RNG, the test groups are shuffled one more time. This seems to result in some panfrost T720 stability issues (See its new deqp-panfrost-t720-flakes.txt), and one new flake in freedreno a630. Reviewed-by: Tomeu Vizoso <tomeu.vizoso@collabora.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7434>
2020-10-29 17:29:28 +00:00
if [[ "$DEBIAN_ARCH" = "arm64" ]]; then
GCC_ARCH="aarch64-linux-gnu"
KERNEL_ARCH="arm64"
SKQP_ARCH="arm64"
DEFCONFIG="arch/arm64/configs/defconfig"
DEVICE_TREES="arch/arm64/boot/dts/rockchip/rk3399-gru-kevin.dtb"
DEVICE_TREES+=" arch/arm64/boot/dts/amlogic/meson-gxl-s805x-libretech-ac.dtb"
DEVICE_TREES+=" arch/arm64/boot/dts/allwinner/sun50i-h6-pine-h64.dtb"
DEVICE_TREES+=" arch/arm64/boot/dts/amlogic/meson-gxm-khadas-vim2.dtb"
DEVICE_TREES+=" arch/arm64/boot/dts/qcom/apq8016-sbc.dtb"
DEVICE_TREES+=" arch/arm64/boot/dts/qcom/apq8096-db820c.dtb"
DEVICE_TREES+=" arch/arm64/boot/dts/amlogic/meson-g12b-a311d-khadas-vim3.dtb"
DEVICE_TREES+=" arch/arm64/boot/dts/mediatek/mt8183-kukui-jacuzzi-juniper-sku16.dtb"
DEVICE_TREES+=" arch/arm64/boot/dts/nvidia/tegra210-p3450-0000.dtb"
DEVICE_TREES+=" arch/arm64/boot/dts/qcom/sc7180-trogdor-lazor-limozeen-nots-r5.dtb"
KERNEL_IMAGE_NAME="Image"
elif [[ "$DEBIAN_ARCH" = "armhf" ]]; then
GCC_ARCH="arm-linux-gnueabihf"
KERNEL_ARCH="arm"
SKQP_ARCH="arm"
DEFCONFIG="arch/arm/configs/multi_v7_defconfig"
DEVICE_TREES="arch/arm/boot/dts/rk3288-veyron-jaq.dtb"
DEVICE_TREES+=" arch/arm/boot/dts/sun8i-h3-libretech-all-h3-cc.dtb"
DEVICE_TREES+=" arch/arm/boot/dts/imx6q-cubox-i.dtb"
KERNEL_IMAGE_NAME="zImage"
. .gitlab-ci/container/create-cross-file.sh armhf
else
GCC_ARCH="x86_64-linux-gnu"
KERNEL_ARCH="x86_64"
SKQP_ARCH="x64"
DEFCONFIG="arch/x86/configs/x86_64_defconfig"
DEVICE_TREES=""
KERNEL_IMAGE_NAME="bzImage"
ARCH_PACKAGES="libasound2-dev libcap-dev libfdt-dev libva-dev wayland-protocols"
fi
# Determine if we're in a cross build.
if [[ -e /cross_file-$DEBIAN_ARCH.txt ]]; then
EXTRA_MESON_ARGS="--cross-file /cross_file-$DEBIAN_ARCH.txt"
EXTRA_CMAKE_ARGS="-DCMAKE_TOOLCHAIN_FILE=/toolchain-$DEBIAN_ARCH.cmake"
ci/deqp: Switch to a new dEQP runner written in Rust. I found the C++ runner hard to develop on, and we had stability issues and outstanding feature needs that made me want something I felt good about hacking on. Thus, Rewrite It In Rust of the deqp runner. The new runner includes: - Skip lists don't reshuffle the test list. - Known-flake handling without resorting to skip lists (fixing our main CI reliability issue on a3xx right now). - Per-thread Vulkan shader caches should speed up VK CI runtime. - Tracking of crashes separate from fails (so we can see progress on that front). - Logging of deqp stderr spam (particularly assertion failures!) in the CI log. - Integrated QPA filtering so we don't have bash perf issues for it. - Logging of what caselist to go look at for a given error report (in red, so it's easier to find in your CI log). - The code is 1/3 unit tests, and easy to extend for more coverage. - Non-LAVA CI runs create a failures.csv in artifacts that you can check in as your deqp-*-fails.txt file. - Test runtime is included in results.csv so you can debug how to speed up your CI job. - Pretty summary at the end of the run of slow/flaky/failed tests. Since this is a new runner with a different RNG, the test groups are shuffled one more time. This seems to result in some panfrost T720 stability issues (See its new deqp-panfrost-t720-flakes.txt), and one new flake in freedreno a630. Reviewed-by: Tomeu Vizoso <tomeu.vizoso@collabora.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7434>
2020-10-29 17:29:28 +00:00
if [ $DEBIAN_ARCH = arm64 ]; then
RUST_TARGET="aarch64-unknown-linux-gnu"
elif [ $DEBIAN_ARCH = armhf ]; then
RUST_TARGET="armv7-unknown-linux-gnueabihf"
fi
rustup target add $RUST_TARGET
export EXTRA_CARGO_ARGS="--target $RUST_TARGET"
export ARCH=${KERNEL_ARCH}
export CROSS_COMPILE="${GCC_ARCH}-"
fi
apt-get update
apt-get install -y --no-remove \
${ARCH_PACKAGES} \
automake \
bc \
ci: skqp: Build skqp from android-cts-10.0_r11 tag with Clang The Android CTS 10 version is relative old when compared with skia main branch, which was being used before. Some modifications in the skqp build/runner scripts were needed to make it run on CI. - skqp versions from android-cts have already all assets inside platform_tools folder. - along with the assets, are the render and unit files which are expected to pass in the Android CTS execution. - removed custom test files from the a630 folder, to make it comply with the CTS expectations. - include new patches to remove Python2 dependencies and avoid the installation of it in rootfs. - strip binariesthe built binaries `skqp` and `list_gpu_unit_tests`, as `is_debug = false` gn argument did not work, maybe it is not well tested in development builds with skia tools - use Clang instead of GCC. The GCC support is not so graceful as it is in the skia main branch, some NEON instructions needs to be turned off in the GCC compilation, causing different tests result. This change does not imply a bigger rootfs, since the built skqp binary uses GCC libc++ and other library runtimes. So clang is just a build dependency. = Changes in skqp results = Some errors were found for GL backend and unit tests. GLES and VK tests are green. All the failed tests were classified as expected to fail in the render and unit tests list. ``` gl_blur2rectsnonninepatch gl_bug339297_as_clip gl_bug6083 gl_dashtextcaps ``` ``` SRGBReadWritePixels (../../tests/SRGBReadWritePixelsTest.cpp:214 Could not create sRGB surface context. [OpenGL]) ``` Signed-off-by: Guilherme Gallo <guilherme.gallo@collabora.com> Reviewed-by: Emma Anholt <emma@anholt.net> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14686>
2022-01-27 04:28:51 +00:00
clang \
cmake \
debootstrap \
git \
glslang-tools \
libdrm-dev \
libegl1-mesa-dev \
ci: skqp: Build skqp from android-cts-10.0_r11 tag with Clang The Android CTS 10 version is relative old when compared with skia main branch, which was being used before. Some modifications in the skqp build/runner scripts were needed to make it run on CI. - skqp versions from android-cts have already all assets inside platform_tools folder. - along with the assets, are the render and unit files which are expected to pass in the Android CTS execution. - removed custom test files from the a630 folder, to make it comply with the CTS expectations. - include new patches to remove Python2 dependencies and avoid the installation of it in rootfs. - strip binariesthe built binaries `skqp` and `list_gpu_unit_tests`, as `is_debug = false` gn argument did not work, maybe it is not well tested in development builds with skia tools - use Clang instead of GCC. The GCC support is not so graceful as it is in the skia main branch, some NEON instructions needs to be turned off in the GCC compilation, causing different tests result. This change does not imply a bigger rootfs, since the built skqp binary uses GCC libc++ and other library runtimes. So clang is just a build dependency. = Changes in skqp results = Some errors were found for GL backend and unit tests. GLES and VK tests are green. All the failed tests were classified as expected to fail in the render and unit tests list. ``` gl_blur2rectsnonninepatch gl_bug339297_as_clip gl_bug6083 gl_dashtextcaps ``` ``` SRGBReadWritePixels (../../tests/SRGBReadWritePixelsTest.cpp:214 Could not create sRGB surface context. [OpenGL]) ``` Signed-off-by: Guilherme Gallo <guilherme.gallo@collabora.com> Reviewed-by: Emma Anholt <emma@anholt.net> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14686>
2022-01-27 04:28:51 +00:00
libxext-dev \
ci: Build skqp on ARM64 images This commit makes `kernel+rootfs_arm64` job build and install skqp on ARM64 devices rootfs. Skia repository has a tool to prepare skqp models located at `tools/skqp/cut-release`, which get files from [Skia Gold](https://skia.org/docs/dev/testing/skiagold/), generate files.checksum, rendertests.txt and unittests.txt. One gives a range of commits to let `cut-release` find the right resources to prepare skqp for the user. However, it is failing, since it fails when trying to get image packages from a range of commits via HTTPS from the host https://public-gold.skia.org but it responds with error 404 every time. I tried a range a thousand of commits, yet it still does not give results. The workaround employed was to recover the most recent `files.checksum` and `rendertests.txt` files from the git history and generate `unittests.txt` from `list_gpu_unit_tests` binary. `skqp` runs two lists of tests, `rendertests.txt` and `unittests.txt`. Both must be located inside the `skqp` assets folder. The first list uses GL and GLES to test rendering scenarios. The second runs some unit tests that do not render an image per se. In order to make the first `a630_skqp` to be green, the crashing tests were removed from the test lists and the expectations of the failing ones were updated. It is worth noting that `rendertests.txt` can bring some detail about each test expectation, so each test can have a max pixel error count, to tell `skqp` that it is OK to have at most that number of errors for that test. See also: https://github.com/google/skia/blob/main/tools/skqp/README_ALGORITHM.md As each render backend has a different error count, two different `rendertests.txt` files were created, `src/freedreno/ci/freedreno-a630-skqp-gl_rendertests.txt`, `src/freedreno/ci/freedreno-a630-skqp-gles_rendertests.txt` and , which one refers to GL and GLES tests respectfully. The unit tests file for a630 is located at `src/freedreno/ci/freedreno-a630-skqp_unittests.txt` ``` aaclip domain formats highcontrastfilter rectangle_texture yuv_make_color_space ``` ``` ProcessorOptimizationValidationTest VkProtectedContext_CreateNonprotectedContext VkYCbcrSampler_DrawImageWithYcbcrSampler VkYCbcrSampler_NoYcbcrSurface ``` Each test was updated with the max_error count equal to the first run result. ``` analytic_antialias_inverse async_rescale_and_read_dog_down async_rescale_and_read_dog_up async_rescale_and_read_rose async_rescale_and_read_text_down async_rescale_and_read_text_up async_rescale_and_read_text_up_large async_rescale_and_read_yuv420_rose complexclip2_path_bw encode-platform imageblur_large lcdtextsize onebadarc onefailarc scale-pixels surfaceprops textfilter_color textfilter_image ``` Considering all the following tests results as wrong. ``` async_rescale_and_read_no_bleed backdrop_imagefilter_croprect_persp complexclip2 imageblurrepeatmode mixerCF overdrawcolorfilter patch_alpha patch_primitive rrect_clip_bw scaledemoji_rendering yuv_splitter ``` v2: a) add link to HTML report on job log b) remove extraneous spaces diff c) remove unnecessary conditions from build-skqp.sh d) use fixed skqp source commit SHA v3: a) Use only main skia repository to fetch models and build skqp b) Use list_gpu_unit_tests binary to create a base unittests.txt file c) Remove crashing tests d) Set failing tests expectations for the first skqp run v4: a) Remove clang dependency b) Separate each skqp backend result into its folder c) Regroup a630_skqp in one job v5: a) Separate tests files per driver Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/5580 Signed-off-by: Guilherme Gallo <guilherme.gallo@collabora.com> Reviewed-by: Emma Anholt <emma@anholt.net> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14146>
2021-12-07 14:13:00 +00:00
libfontconfig-dev \
libgbm-dev \
ci: Build skqp on ARM64 images This commit makes `kernel+rootfs_arm64` job build and install skqp on ARM64 devices rootfs. Skia repository has a tool to prepare skqp models located at `tools/skqp/cut-release`, which get files from [Skia Gold](https://skia.org/docs/dev/testing/skiagold/), generate files.checksum, rendertests.txt and unittests.txt. One gives a range of commits to let `cut-release` find the right resources to prepare skqp for the user. However, it is failing, since it fails when trying to get image packages from a range of commits via HTTPS from the host https://public-gold.skia.org but it responds with error 404 every time. I tried a range a thousand of commits, yet it still does not give results. The workaround employed was to recover the most recent `files.checksum` and `rendertests.txt` files from the git history and generate `unittests.txt` from `list_gpu_unit_tests` binary. `skqp` runs two lists of tests, `rendertests.txt` and `unittests.txt`. Both must be located inside the `skqp` assets folder. The first list uses GL and GLES to test rendering scenarios. The second runs some unit tests that do not render an image per se. In order to make the first `a630_skqp` to be green, the crashing tests were removed from the test lists and the expectations of the failing ones were updated. It is worth noting that `rendertests.txt` can bring some detail about each test expectation, so each test can have a max pixel error count, to tell `skqp` that it is OK to have at most that number of errors for that test. See also: https://github.com/google/skia/blob/main/tools/skqp/README_ALGORITHM.md As each render backend has a different error count, two different `rendertests.txt` files were created, `src/freedreno/ci/freedreno-a630-skqp-gl_rendertests.txt`, `src/freedreno/ci/freedreno-a630-skqp-gles_rendertests.txt` and , which one refers to GL and GLES tests respectfully. The unit tests file for a630 is located at `src/freedreno/ci/freedreno-a630-skqp_unittests.txt` ``` aaclip domain formats highcontrastfilter rectangle_texture yuv_make_color_space ``` ``` ProcessorOptimizationValidationTest VkProtectedContext_CreateNonprotectedContext VkYCbcrSampler_DrawImageWithYcbcrSampler VkYCbcrSampler_NoYcbcrSurface ``` Each test was updated with the max_error count equal to the first run result. ``` analytic_antialias_inverse async_rescale_and_read_dog_down async_rescale_and_read_dog_up async_rescale_and_read_rose async_rescale_and_read_text_down async_rescale_and_read_text_up async_rescale_and_read_text_up_large async_rescale_and_read_yuv420_rose complexclip2_path_bw encode-platform imageblur_large lcdtextsize onebadarc onefailarc scale-pixels surfaceprops textfilter_color textfilter_image ``` Considering all the following tests results as wrong. ``` async_rescale_and_read_no_bleed backdrop_imagefilter_croprect_persp complexclip2 imageblurrepeatmode mixerCF overdrawcolorfilter patch_alpha patch_primitive rrect_clip_bw scaledemoji_rendering yuv_splitter ``` v2: a) add link to HTML report on job log b) remove extraneous spaces diff c) remove unnecessary conditions from build-skqp.sh d) use fixed skqp source commit SHA v3: a) Use only main skia repository to fetch models and build skqp b) Use list_gpu_unit_tests binary to create a base unittests.txt file c) Remove crashing tests d) Set failing tests expectations for the first skqp run v4: a) Remove clang dependency b) Separate each skqp backend result into its folder c) Regroup a630_skqp in one job v5: a) Separate tests files per driver Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/5580 Signed-off-by: Guilherme Gallo <guilherme.gallo@collabora.com> Reviewed-by: Emma Anholt <emma@anholt.net> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14146>
2021-12-07 14:13:00 +00:00
libgl-dev \
libgles2-mesa-dev \
ci: Build skqp on ARM64 images This commit makes `kernel+rootfs_arm64` job build and install skqp on ARM64 devices rootfs. Skia repository has a tool to prepare skqp models located at `tools/skqp/cut-release`, which get files from [Skia Gold](https://skia.org/docs/dev/testing/skiagold/), generate files.checksum, rendertests.txt and unittests.txt. One gives a range of commits to let `cut-release` find the right resources to prepare skqp for the user. However, it is failing, since it fails when trying to get image packages from a range of commits via HTTPS from the host https://public-gold.skia.org but it responds with error 404 every time. I tried a range a thousand of commits, yet it still does not give results. The workaround employed was to recover the most recent `files.checksum` and `rendertests.txt` files from the git history and generate `unittests.txt` from `list_gpu_unit_tests` binary. `skqp` runs two lists of tests, `rendertests.txt` and `unittests.txt`. Both must be located inside the `skqp` assets folder. The first list uses GL and GLES to test rendering scenarios. The second runs some unit tests that do not render an image per se. In order to make the first `a630_skqp` to be green, the crashing tests were removed from the test lists and the expectations of the failing ones were updated. It is worth noting that `rendertests.txt` can bring some detail about each test expectation, so each test can have a max pixel error count, to tell `skqp` that it is OK to have at most that number of errors for that test. See also: https://github.com/google/skia/blob/main/tools/skqp/README_ALGORITHM.md As each render backend has a different error count, two different `rendertests.txt` files were created, `src/freedreno/ci/freedreno-a630-skqp-gl_rendertests.txt`, `src/freedreno/ci/freedreno-a630-skqp-gles_rendertests.txt` and , which one refers to GL and GLES tests respectfully. The unit tests file for a630 is located at `src/freedreno/ci/freedreno-a630-skqp_unittests.txt` ``` aaclip domain formats highcontrastfilter rectangle_texture yuv_make_color_space ``` ``` ProcessorOptimizationValidationTest VkProtectedContext_CreateNonprotectedContext VkYCbcrSampler_DrawImageWithYcbcrSampler VkYCbcrSampler_NoYcbcrSurface ``` Each test was updated with the max_error count equal to the first run result. ``` analytic_antialias_inverse async_rescale_and_read_dog_down async_rescale_and_read_dog_up async_rescale_and_read_rose async_rescale_and_read_text_down async_rescale_and_read_text_up async_rescale_and_read_text_up_large async_rescale_and_read_yuv420_rose complexclip2_path_bw encode-platform imageblur_large lcdtextsize onebadarc onefailarc scale-pixels surfaceprops textfilter_color textfilter_image ``` Considering all the following tests results as wrong. ``` async_rescale_and_read_no_bleed backdrop_imagefilter_croprect_persp complexclip2 imageblurrepeatmode mixerCF overdrawcolorfilter patch_alpha patch_primitive rrect_clip_bw scaledemoji_rendering yuv_splitter ``` v2: a) add link to HTML report on job log b) remove extraneous spaces diff c) remove unnecessary conditions from build-skqp.sh d) use fixed skqp source commit SHA v3: a) Use only main skia repository to fetch models and build skqp b) Use list_gpu_unit_tests binary to create a base unittests.txt file c) Remove crashing tests d) Set failing tests expectations for the first skqp run v4: a) Remove clang dependency b) Separate each skqp backend result into its folder c) Regroup a630_skqp in one job v5: a) Separate tests files per driver Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/5580 Signed-off-by: Guilherme Gallo <guilherme.gallo@collabora.com> Reviewed-by: Emma Anholt <emma@anholt.net> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14146>
2021-12-07 14:13:00 +00:00
libglu1-mesa-dev \
libglx-dev \
libpng-dev \
libssl-dev \
libudev-dev \
libvulkan-dev \
libwaffle-dev \
libwayland-dev \
libx11-xcb-dev \
libxcb-dri2-0-dev \
libxkbcommon-dev \
ci: Build skqp on ARM64 images This commit makes `kernel+rootfs_arm64` job build and install skqp on ARM64 devices rootfs. Skia repository has a tool to prepare skqp models located at `tools/skqp/cut-release`, which get files from [Skia Gold](https://skia.org/docs/dev/testing/skiagold/), generate files.checksum, rendertests.txt and unittests.txt. One gives a range of commits to let `cut-release` find the right resources to prepare skqp for the user. However, it is failing, since it fails when trying to get image packages from a range of commits via HTTPS from the host https://public-gold.skia.org but it responds with error 404 every time. I tried a range a thousand of commits, yet it still does not give results. The workaround employed was to recover the most recent `files.checksum` and `rendertests.txt` files from the git history and generate `unittests.txt` from `list_gpu_unit_tests` binary. `skqp` runs two lists of tests, `rendertests.txt` and `unittests.txt`. Both must be located inside the `skqp` assets folder. The first list uses GL and GLES to test rendering scenarios. The second runs some unit tests that do not render an image per se. In order to make the first `a630_skqp` to be green, the crashing tests were removed from the test lists and the expectations of the failing ones were updated. It is worth noting that `rendertests.txt` can bring some detail about each test expectation, so each test can have a max pixel error count, to tell `skqp` that it is OK to have at most that number of errors for that test. See also: https://github.com/google/skia/blob/main/tools/skqp/README_ALGORITHM.md As each render backend has a different error count, two different `rendertests.txt` files were created, `src/freedreno/ci/freedreno-a630-skqp-gl_rendertests.txt`, `src/freedreno/ci/freedreno-a630-skqp-gles_rendertests.txt` and , which one refers to GL and GLES tests respectfully. The unit tests file for a630 is located at `src/freedreno/ci/freedreno-a630-skqp_unittests.txt` ``` aaclip domain formats highcontrastfilter rectangle_texture yuv_make_color_space ``` ``` ProcessorOptimizationValidationTest VkProtectedContext_CreateNonprotectedContext VkYCbcrSampler_DrawImageWithYcbcrSampler VkYCbcrSampler_NoYcbcrSurface ``` Each test was updated with the max_error count equal to the first run result. ``` analytic_antialias_inverse async_rescale_and_read_dog_down async_rescale_and_read_dog_up async_rescale_and_read_rose async_rescale_and_read_text_down async_rescale_and_read_text_up async_rescale_and_read_text_up_large async_rescale_and_read_yuv420_rose complexclip2_path_bw encode-platform imageblur_large lcdtextsize onebadarc onefailarc scale-pixels surfaceprops textfilter_color textfilter_image ``` Considering all the following tests results as wrong. ``` async_rescale_and_read_no_bleed backdrop_imagefilter_croprect_persp complexclip2 imageblurrepeatmode mixerCF overdrawcolorfilter patch_alpha patch_primitive rrect_clip_bw scaledemoji_rendering yuv_splitter ``` v2: a) add link to HTML report on job log b) remove extraneous spaces diff c) remove unnecessary conditions from build-skqp.sh d) use fixed skqp source commit SHA v3: a) Use only main skia repository to fetch models and build skqp b) Use list_gpu_unit_tests binary to create a base unittests.txt file c) Remove crashing tests d) Set failing tests expectations for the first skqp run v4: a) Remove clang dependency b) Separate each skqp backend result into its folder c) Regroup a630_skqp in one job v5: a) Separate tests files per driver Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/5580 Signed-off-by: Guilherme Gallo <guilherme.gallo@collabora.com> Reviewed-by: Emma Anholt <emma@anholt.net> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14146>
2021-12-07 14:13:00 +00:00
ninja-build \
patch \
ci: Build skqp on ARM64 images This commit makes `kernel+rootfs_arm64` job build and install skqp on ARM64 devices rootfs. Skia repository has a tool to prepare skqp models located at `tools/skqp/cut-release`, which get files from [Skia Gold](https://skia.org/docs/dev/testing/skiagold/), generate files.checksum, rendertests.txt and unittests.txt. One gives a range of commits to let `cut-release` find the right resources to prepare skqp for the user. However, it is failing, since it fails when trying to get image packages from a range of commits via HTTPS from the host https://public-gold.skia.org but it responds with error 404 every time. I tried a range a thousand of commits, yet it still does not give results. The workaround employed was to recover the most recent `files.checksum` and `rendertests.txt` files from the git history and generate `unittests.txt` from `list_gpu_unit_tests` binary. `skqp` runs two lists of tests, `rendertests.txt` and `unittests.txt`. Both must be located inside the `skqp` assets folder. The first list uses GL and GLES to test rendering scenarios. The second runs some unit tests that do not render an image per se. In order to make the first `a630_skqp` to be green, the crashing tests were removed from the test lists and the expectations of the failing ones were updated. It is worth noting that `rendertests.txt` can bring some detail about each test expectation, so each test can have a max pixel error count, to tell `skqp` that it is OK to have at most that number of errors for that test. See also: https://github.com/google/skia/blob/main/tools/skqp/README_ALGORITHM.md As each render backend has a different error count, two different `rendertests.txt` files were created, `src/freedreno/ci/freedreno-a630-skqp-gl_rendertests.txt`, `src/freedreno/ci/freedreno-a630-skqp-gles_rendertests.txt` and , which one refers to GL and GLES tests respectfully. The unit tests file for a630 is located at `src/freedreno/ci/freedreno-a630-skqp_unittests.txt` ``` aaclip domain formats highcontrastfilter rectangle_texture yuv_make_color_space ``` ``` ProcessorOptimizationValidationTest VkProtectedContext_CreateNonprotectedContext VkYCbcrSampler_DrawImageWithYcbcrSampler VkYCbcrSampler_NoYcbcrSurface ``` Each test was updated with the max_error count equal to the first run result. ``` analytic_antialias_inverse async_rescale_and_read_dog_down async_rescale_and_read_dog_up async_rescale_and_read_rose async_rescale_and_read_text_down async_rescale_and_read_text_up async_rescale_and_read_text_up_large async_rescale_and_read_yuv420_rose complexclip2_path_bw encode-platform imageblur_large lcdtextsize onebadarc onefailarc scale-pixels surfaceprops textfilter_color textfilter_image ``` Considering all the following tests results as wrong. ``` async_rescale_and_read_no_bleed backdrop_imagefilter_croprect_persp complexclip2 imageblurrepeatmode mixerCF overdrawcolorfilter patch_alpha patch_primitive rrect_clip_bw scaledemoji_rendering yuv_splitter ``` v2: a) add link to HTML report on job log b) remove extraneous spaces diff c) remove unnecessary conditions from build-skqp.sh d) use fixed skqp source commit SHA v3: a) Use only main skia repository to fetch models and build skqp b) Use list_gpu_unit_tests binary to create a base unittests.txt file c) Remove crashing tests d) Set failing tests expectations for the first skqp run v4: a) Remove clang dependency b) Separate each skqp backend result into its folder c) Regroup a630_skqp in one job v5: a) Separate tests files per driver Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/5580 Signed-off-by: Guilherme Gallo <guilherme.gallo@collabora.com> Reviewed-by: Emma Anholt <emma@anholt.net> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14146>
2021-12-07 14:13:00 +00:00
python-is-python3 \
python3-distutils \
python3-mako \
python3-numpy \
python3-serial \
ci: Build skqp on ARM64 images This commit makes `kernel+rootfs_arm64` job build and install skqp on ARM64 devices rootfs. Skia repository has a tool to prepare skqp models located at `tools/skqp/cut-release`, which get files from [Skia Gold](https://skia.org/docs/dev/testing/skiagold/), generate files.checksum, rendertests.txt and unittests.txt. One gives a range of commits to let `cut-release` find the right resources to prepare skqp for the user. However, it is failing, since it fails when trying to get image packages from a range of commits via HTTPS from the host https://public-gold.skia.org but it responds with error 404 every time. I tried a range a thousand of commits, yet it still does not give results. The workaround employed was to recover the most recent `files.checksum` and `rendertests.txt` files from the git history and generate `unittests.txt` from `list_gpu_unit_tests` binary. `skqp` runs two lists of tests, `rendertests.txt` and `unittests.txt`. Both must be located inside the `skqp` assets folder. The first list uses GL and GLES to test rendering scenarios. The second runs some unit tests that do not render an image per se. In order to make the first `a630_skqp` to be green, the crashing tests were removed from the test lists and the expectations of the failing ones were updated. It is worth noting that `rendertests.txt` can bring some detail about each test expectation, so each test can have a max pixel error count, to tell `skqp` that it is OK to have at most that number of errors for that test. See also: https://github.com/google/skia/blob/main/tools/skqp/README_ALGORITHM.md As each render backend has a different error count, two different `rendertests.txt` files were created, `src/freedreno/ci/freedreno-a630-skqp-gl_rendertests.txt`, `src/freedreno/ci/freedreno-a630-skqp-gles_rendertests.txt` and , which one refers to GL and GLES tests respectfully. The unit tests file for a630 is located at `src/freedreno/ci/freedreno-a630-skqp_unittests.txt` ``` aaclip domain formats highcontrastfilter rectangle_texture yuv_make_color_space ``` ``` ProcessorOptimizationValidationTest VkProtectedContext_CreateNonprotectedContext VkYCbcrSampler_DrawImageWithYcbcrSampler VkYCbcrSampler_NoYcbcrSurface ``` Each test was updated with the max_error count equal to the first run result. ``` analytic_antialias_inverse async_rescale_and_read_dog_down async_rescale_and_read_dog_up async_rescale_and_read_rose async_rescale_and_read_text_down async_rescale_and_read_text_up async_rescale_and_read_text_up_large async_rescale_and_read_yuv420_rose complexclip2_path_bw encode-platform imageblur_large lcdtextsize onebadarc onefailarc scale-pixels surfaceprops textfilter_color textfilter_image ``` Considering all the following tests results as wrong. ``` async_rescale_and_read_no_bleed backdrop_imagefilter_croprect_persp complexclip2 imageblurrepeatmode mixerCF overdrawcolorfilter patch_alpha patch_primitive rrect_clip_bw scaledemoji_rendering yuv_splitter ``` v2: a) add link to HTML report on job log b) remove extraneous spaces diff c) remove unnecessary conditions from build-skqp.sh d) use fixed skqp source commit SHA v3: a) Use only main skia repository to fetch models and build skqp b) Use list_gpu_unit_tests binary to create a base unittests.txt file c) Remove crashing tests d) Set failing tests expectations for the first skqp run v4: a) Remove clang dependency b) Separate each skqp backend result into its folder c) Regroup a630_skqp in one job v5: a) Separate tests files per driver Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/5580 Signed-off-by: Guilherme Gallo <guilherme.gallo@collabora.com> Reviewed-by: Emma Anholt <emma@anholt.net> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14146>
2021-12-07 14:13:00 +00:00
unzip \
wget
if [[ "$DEBIAN_ARCH" = "armhf" ]]; then
apt-get install -y --no-remove \
libegl1-mesa-dev:armhf \
libelf-dev:armhf \
libgbm-dev:armhf \
libgles2-mesa-dev:armhf \
libpng-dev:armhf \
libudev-dev:armhf \
libvulkan-dev:armhf \
libwaffle-dev:armhf \
libwayland-dev:armhf \
libx11-xcb-dev:armhf \
libxkbcommon-dev:armhf
fi
ci/deqp: Switch to a new dEQP runner written in Rust. I found the C++ runner hard to develop on, and we had stability issues and outstanding feature needs that made me want something I felt good about hacking on. Thus, Rewrite It In Rust of the deqp runner. The new runner includes: - Skip lists don't reshuffle the test list. - Known-flake handling without resorting to skip lists (fixing our main CI reliability issue on a3xx right now). - Per-thread Vulkan shader caches should speed up VK CI runtime. - Tracking of crashes separate from fails (so we can see progress on that front). - Logging of deqp stderr spam (particularly assertion failures!) in the CI log. - Integrated QPA filtering so we don't have bash perf issues for it. - Logging of what caselist to go look at for a given error report (in red, so it's easier to find in your CI log). - The code is 1/3 unit tests, and easy to extend for more coverage. - Non-LAVA CI runs create a failures.csv in artifacts that you can check in as your deqp-*-fails.txt file. - Test runtime is included in results.csv so you can debug how to speed up your CI job. - Pretty summary at the end of the run of slow/flaky/failed tests. Since this is a new runner with a different RNG, the test groups are shuffled one more time. This seems to result in some panfrost T720 stability issues (See its new deqp-panfrost-t720-flakes.txt), and one new flake in freedreno a630. Reviewed-by: Tomeu Vizoso <tomeu.vizoso@collabora.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7434>
2020-10-29 17:29:28 +00:00
############### Building
STRIP_CMD="${GCC_ARCH}-strip"
mkdir -p /lava-files/rootfs-${DEBIAN_ARCH}/usr/lib/$GCC_ARCH
############### Build apitrace
. .gitlab-ci/container/build-apitrace.sh
mkdir -p /lava-files/rootfs-${DEBIAN_ARCH}/apitrace
mv /apitrace/build /lava-files/rootfs-${DEBIAN_ARCH}/apitrace
rm -rf /apitrace
############### Build dEQP runner
. .gitlab-ci/container/build-deqp-runner.sh
mkdir -p /lava-files/rootfs-${DEBIAN_ARCH}/usr/bin
mv /usr/local/bin/*-runner /lava-files/rootfs-${DEBIAN_ARCH}/usr/bin/.
############### Build dEQP
DEQP_TARGET=surfaceless . .gitlab-ci/container/build-deqp.sh
mv /deqp /lava-files/rootfs-${DEBIAN_ARCH}/.
ci: Build skqp on ARM64 images This commit makes `kernel+rootfs_arm64` job build and install skqp on ARM64 devices rootfs. Skia repository has a tool to prepare skqp models located at `tools/skqp/cut-release`, which get files from [Skia Gold](https://skia.org/docs/dev/testing/skiagold/), generate files.checksum, rendertests.txt and unittests.txt. One gives a range of commits to let `cut-release` find the right resources to prepare skqp for the user. However, it is failing, since it fails when trying to get image packages from a range of commits via HTTPS from the host https://public-gold.skia.org but it responds with error 404 every time. I tried a range a thousand of commits, yet it still does not give results. The workaround employed was to recover the most recent `files.checksum` and `rendertests.txt` files from the git history and generate `unittests.txt` from `list_gpu_unit_tests` binary. `skqp` runs two lists of tests, `rendertests.txt` and `unittests.txt`. Both must be located inside the `skqp` assets folder. The first list uses GL and GLES to test rendering scenarios. The second runs some unit tests that do not render an image per se. In order to make the first `a630_skqp` to be green, the crashing tests were removed from the test lists and the expectations of the failing ones were updated. It is worth noting that `rendertests.txt` can bring some detail about each test expectation, so each test can have a max pixel error count, to tell `skqp` that it is OK to have at most that number of errors for that test. See also: https://github.com/google/skia/blob/main/tools/skqp/README_ALGORITHM.md As each render backend has a different error count, two different `rendertests.txt` files were created, `src/freedreno/ci/freedreno-a630-skqp-gl_rendertests.txt`, `src/freedreno/ci/freedreno-a630-skqp-gles_rendertests.txt` and , which one refers to GL and GLES tests respectfully. The unit tests file for a630 is located at `src/freedreno/ci/freedreno-a630-skqp_unittests.txt` ``` aaclip domain formats highcontrastfilter rectangle_texture yuv_make_color_space ``` ``` ProcessorOptimizationValidationTest VkProtectedContext_CreateNonprotectedContext VkYCbcrSampler_DrawImageWithYcbcrSampler VkYCbcrSampler_NoYcbcrSurface ``` Each test was updated with the max_error count equal to the first run result. ``` analytic_antialias_inverse async_rescale_and_read_dog_down async_rescale_and_read_dog_up async_rescale_and_read_rose async_rescale_and_read_text_down async_rescale_and_read_text_up async_rescale_and_read_text_up_large async_rescale_and_read_yuv420_rose complexclip2_path_bw encode-platform imageblur_large lcdtextsize onebadarc onefailarc scale-pixels surfaceprops textfilter_color textfilter_image ``` Considering all the following tests results as wrong. ``` async_rescale_and_read_no_bleed backdrop_imagefilter_croprect_persp complexclip2 imageblurrepeatmode mixerCF overdrawcolorfilter patch_alpha patch_primitive rrect_clip_bw scaledemoji_rendering yuv_splitter ``` v2: a) add link to HTML report on job log b) remove extraneous spaces diff c) remove unnecessary conditions from build-skqp.sh d) use fixed skqp source commit SHA v3: a) Use only main skia repository to fetch models and build skqp b) Use list_gpu_unit_tests binary to create a base unittests.txt file c) Remove crashing tests d) Set failing tests expectations for the first skqp run v4: a) Remove clang dependency b) Separate each skqp backend result into its folder c) Regroup a630_skqp in one job v5: a) Separate tests files per driver Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/5580 Signed-off-by: Guilherme Gallo <guilherme.gallo@collabora.com> Reviewed-by: Emma Anholt <emma@anholt.net> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14146>
2021-12-07 14:13:00 +00:00
############### Build SKQP
if [[ "$DEBIAN_ARCH" = "arm64" ]] \
|| [[ "$DEBIAN_ARCH" = "amd64" ]]; then
. .gitlab-ci/container/build-skqp.sh
ci: Build skqp on ARM64 images This commit makes `kernel+rootfs_arm64` job build and install skqp on ARM64 devices rootfs. Skia repository has a tool to prepare skqp models located at `tools/skqp/cut-release`, which get files from [Skia Gold](https://skia.org/docs/dev/testing/skiagold/), generate files.checksum, rendertests.txt and unittests.txt. One gives a range of commits to let `cut-release` find the right resources to prepare skqp for the user. However, it is failing, since it fails when trying to get image packages from a range of commits via HTTPS from the host https://public-gold.skia.org but it responds with error 404 every time. I tried a range a thousand of commits, yet it still does not give results. The workaround employed was to recover the most recent `files.checksum` and `rendertests.txt` files from the git history and generate `unittests.txt` from `list_gpu_unit_tests` binary. `skqp` runs two lists of tests, `rendertests.txt` and `unittests.txt`. Both must be located inside the `skqp` assets folder. The first list uses GL and GLES to test rendering scenarios. The second runs some unit tests that do not render an image per se. In order to make the first `a630_skqp` to be green, the crashing tests were removed from the test lists and the expectations of the failing ones were updated. It is worth noting that `rendertests.txt` can bring some detail about each test expectation, so each test can have a max pixel error count, to tell `skqp` that it is OK to have at most that number of errors for that test. See also: https://github.com/google/skia/blob/main/tools/skqp/README_ALGORITHM.md As each render backend has a different error count, two different `rendertests.txt` files were created, `src/freedreno/ci/freedreno-a630-skqp-gl_rendertests.txt`, `src/freedreno/ci/freedreno-a630-skqp-gles_rendertests.txt` and , which one refers to GL and GLES tests respectfully. The unit tests file for a630 is located at `src/freedreno/ci/freedreno-a630-skqp_unittests.txt` ``` aaclip domain formats highcontrastfilter rectangle_texture yuv_make_color_space ``` ``` ProcessorOptimizationValidationTest VkProtectedContext_CreateNonprotectedContext VkYCbcrSampler_DrawImageWithYcbcrSampler VkYCbcrSampler_NoYcbcrSurface ``` Each test was updated with the max_error count equal to the first run result. ``` analytic_antialias_inverse async_rescale_and_read_dog_down async_rescale_and_read_dog_up async_rescale_and_read_rose async_rescale_and_read_text_down async_rescale_and_read_text_up async_rescale_and_read_text_up_large async_rescale_and_read_yuv420_rose complexclip2_path_bw encode-platform imageblur_large lcdtextsize onebadarc onefailarc scale-pixels surfaceprops textfilter_color textfilter_image ``` Considering all the following tests results as wrong. ``` async_rescale_and_read_no_bleed backdrop_imagefilter_croprect_persp complexclip2 imageblurrepeatmode mixerCF overdrawcolorfilter patch_alpha patch_primitive rrect_clip_bw scaledemoji_rendering yuv_splitter ``` v2: a) add link to HTML report on job log b) remove extraneous spaces diff c) remove unnecessary conditions from build-skqp.sh d) use fixed skqp source commit SHA v3: a) Use only main skia repository to fetch models and build skqp b) Use list_gpu_unit_tests binary to create a base unittests.txt file c) Remove crashing tests d) Set failing tests expectations for the first skqp run v4: a) Remove clang dependency b) Separate each skqp backend result into its folder c) Regroup a630_skqp in one job v5: a) Separate tests files per driver Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/5580 Signed-off-by: Guilherme Gallo <guilherme.gallo@collabora.com> Reviewed-by: Emma Anholt <emma@anholt.net> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14146>
2021-12-07 14:13:00 +00:00
mv /skqp /lava-files/rootfs-${DEBIAN_ARCH}/.
fi
############### Build piglit
PIGLIT_OPTS="-DPIGLIT_BUILD_DMA_BUF_TESTS=ON" . .gitlab-ci/container/build-piglit.sh
mv /piglit /lava-files/rootfs-${DEBIAN_ARCH}/.
############### Build libva tests
if [[ "$DEBIAN_ARCH" = "amd64" ]]; then
. .gitlab-ci/container/build-va-tools.sh
mv /va/bin/* /lava-files/rootfs-${DEBIAN_ARCH}/usr/bin/
fi
############### Build Crosvm
if [[ ${DEBIAN_ARCH} = "amd64" ]]; then
. .gitlab-ci/container/build-crosvm.sh
mv /usr/local/bin/crosvm /lava-files/rootfs-${DEBIAN_ARCH}/usr/bin/
mv /usr/local/lib/$GCC_ARCH/libvirglrenderer.* /lava-files/rootfs-${DEBIAN_ARCH}/usr/lib/$GCC_ARCH/
fi
############### Build libdrm
EXTRA_MESON_ARGS+=" -D prefix=/libdrm"
. .gitlab-ci/container/build-libdrm.sh
############### Build local stuff for use by igt and kernel testing, which
############### will reuse most of our container build process from a specific
############### hash of the Mesa tree.
if [[ -e ".gitlab-ci/local/build-rootfs.sh" ]]; then
. .gitlab-ci/local/build-rootfs.sh
fi
############### Build kernel
. .gitlab-ci/container/build-kernel.sh
############### Delete rust, since the tests won't be compiling anything.
rm -rf /root/.cargo
rm -rf /root/.rustup
############### Create rootfs
set +e
if ! debootstrap \
--variant=minbase \
--arch=${DEBIAN_ARCH} \
--components main,contrib,non-free \
bullseye \
/lava-files/rootfs-${DEBIAN_ARCH}/ \
http://deb.debian.org/debian; then
cat /lava-files/rootfs-${DEBIAN_ARCH}/debootstrap/debootstrap.log
exit 1
fi
set -e
cp .gitlab-ci/container/create-rootfs.sh /lava-files/rootfs-${DEBIAN_ARCH}/.
cp .gitlab-ci/container/debian/llvm-snapshot.gpg.key /lava-files/rootfs-${DEBIAN_ARCH}/.
chroot /lava-files/rootfs-${DEBIAN_ARCH} sh /create-rootfs.sh
rm /lava-files/rootfs-${DEBIAN_ARCH}/llvm-snapshot.gpg.key
rm /lava-files/rootfs-${DEBIAN_ARCH}/create-rootfs.sh
############### Install the built libdrm
# Dependencies pulled during the creation of the rootfs may overwrite
# the built libdrm. Hence, we add it after the rootfs has been already
# created.
find /libdrm/ -name lib\*\.so\* | xargs cp -t /lava-files/rootfs-${DEBIAN_ARCH}/usr/lib/$GCC_ARCH/.
mkdir -p /lava-files/rootfs-${DEBIAN_ARCH}/libdrm/
cp -Rp /libdrm/share /lava-files/rootfs-${DEBIAN_ARCH}/libdrm/share
rm -rf /libdrm
if [ ${DEBIAN_ARCH} = arm64 ]; then
# Make a gzipped copy of the Image for db410c.
gzip -k /lava-files/Image
KERNEL_IMAGE_NAME+=" Image.gz"
fi
du -ah /lava-files/rootfs-${DEBIAN_ARCH} | sort -h | tail -100
pushd /lava-files/rootfs-${DEBIAN_ARCH}
tar czf /lava-files/lava-rootfs.tgz .
popd
. .gitlab-ci/container/container_post_build.sh
############### Upload the files!
ci-fairy minio login --token-file "${CI_JOB_JWT_FILE}"
FILES_TO_UPLOAD="lava-rootfs.tgz \
$KERNEL_IMAGE_NAME"
if [[ -n $DEVICE_TREES ]]; then
FILES_TO_UPLOAD="$FILES_TO_UPLOAD $(basename -a $DEVICE_TREES)"
fi
for f in $FILES_TO_UPLOAD; do
ci-fairy minio cp /lava-files/$f \
minio://${MINIO_PATH}/$f
done
touch /lava-files/done
ci-fairy minio cp /lava-files/done minio://${MINIO_PATH}/done