gitlab-ci: Place files from the Mesa repo into the build tarball

There's some files from the .gitlab-ci directory that are needed in the
test stage and that, because the Mesa repository isn't checked out in
that stage, need to be made available through other means.

Because those files are going to be needed in LAVA devices, place them
ino the tarball containing the built files so it's available to both
gitlab-ci runners and LAVA devices.

Before those files were passed in the artifacts of the Gitlab CI job,
but this commit places them into the built tarball so scripts later in
the pipeline don't need to account for this discrepancy.

Signed-off-by: Tomeu Vizoso <tomeu.vizoso@collabora.com>
Reviewed-by: Eric Anholt <eric@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4295>
This commit is contained in:
Tomeu Vizoso 2020-03-24 12:58:30 +01:00 committed by Marge Bot
parent b94c277fd1
commit 92f3c51560
10 changed files with 49 additions and 57 deletions

View File

@ -587,7 +587,7 @@ scons-old-llvm:
LIBGL_ALWAYS_SOFTWARE: 1
PIGLIT_NO_WINDOW: 1
script:
- artifacts/piglit/run.sh
- install/piglit/run.sh
piglit-quick_gl:
extends: .piglit-test
@ -624,7 +624,7 @@ piglit-quick_shader:
variables:
DEQP_SKIPS: deqp-default-skips.txt
script:
- ./artifacts/deqp-runner.sh
- ./install/deqp-runner.sh
.deqp-test-gl:
extends:
@ -641,7 +641,7 @@ piglit-quick_shader:
.fossilize-test:
extends: .test-vk
script:
- ./artifacts/fossilize-runner.sh
- ./install/fossilize-runner.sh
llvmpipe-gles2:
variables:
@ -790,8 +790,8 @@ arm64_a530_gles3:
- .fossilize-test
- .test-radv
script:
- ./artifacts/fossilize-runner.sh
- ACO_DEBUG=validateir,validatera RADV_PERFTEST=aco ./artifacts/fossilize-runner.sh
- ./install/fossilize-runner.sh
- ACO_DEBUG=validateir,validatera RADV_PERFTEST=aco ./install/fossilize-runner.sh
# Can only be triggered manually on personal branches because RADV is the only
# driver that does Vulkan testing at the moment.
@ -812,16 +812,16 @@ radv-fossils:
script:
# Polaris10
- export RADV_FORCE_FAMILY="polaris10"
- ./artifacts/fossilize-runner.sh
- ACO_DEBUG=validateir,validatera RADV_PERFTEST=aco ./artifacts/fossilize-runner.sh
- ./install/fossilize-runner.sh
- ACO_DEBUG=validateir,validatera RADV_PERFTEST=aco ./install/fossilize-runner.sh
# Vega10
- export RADV_FORCE_FAMILY="gfx900"
- ./artifacts/fossilize-runner.sh
- ACO_DEBUG=validateir,validatera RADV_PERFTEST=aco ./artifacts/fossilize-runner.sh
- ./install/fossilize-runner.sh
- ACO_DEBUG=validateir,validatera RADV_PERFTEST=aco ./install/fossilize-runner.sh
# Navi10
- export RADV_FORCE_FAMILY="gfx1010"
- ./artifacts/fossilize-runner.sh
- ACO_DEBUG=validateir,validatera RADV_PERFTEST=aco ./artifacts/fossilize-runner.sh
- ./install/fossilize-runner.sh
- ACO_DEBUG=validateir,validatera RADV_PERFTEST=aco ./install/fossilize-runner.sh
# Traces CI
.traces-test:
@ -835,14 +835,14 @@ radv-fossils:
- .test-gl
- .traces-test
script:
- ./artifacts/tracie-runner-gl.sh
- ./install/tracie-runner-gl.sh
.traces-test-vk:
extends:
- .test-vk
- .traces-test
script:
- ./artifacts/tracie-runner-vk.sh
- ./install/tracie-runner-vk.sh
llvmpipe-traces:
extends:

View File

@ -56,10 +56,9 @@ ln -sf $CI_PROJECT_DIR/install rootfs/install
# Copy the deqp runner script and metadata.
cp .gitlab-ci/deqp-runner.sh rootfs/deqp/.
mkdir -p rootfs/artifacts/deqp
cp .gitlab-ci/$DEQP_SKIPS rootfs/artifacts/deqp-skips.txt
cp .gitlab-ci/$DEQP_SKIPS rootfs/$CI_PROJECT_DIR/install/deqp-skips.txt
if [ -n "$DEQP_EXPECTED_FAILS" ]; then
cp .gitlab-ci/$DEQP_EXPECTED_FAILS rootfs/artifacts/deqp-expected-fails.txt
cp .gitlab-ci/$DEQP_EXPECTED_FAILS rootfs/$CI_PROJECT_DIR/install/deqp-expected-fails.txt
fi
# Finally, pack it up into a cpio rootfs.

View File

@ -15,7 +15,7 @@ export DEQP_PARALLEL=DEQP_PARALLEL_REPLACE
export CI_NODE_INDEX=CI_NODE_INDEX_REPLACE
export CI_NODE_TOTAL=CI_NODE_TOTAL_REPLACE
export DEQP_SKIPS=deqp-skips.txt
if [ -e /artifacts/deqp-expected-fails.txt ]; then
if [ -e /install/deqp-expected-fails.txt ]; then
export DEQP_EXPECTED_FAILS=deqp-expected-fails.txt
fi

View File

@ -31,7 +31,7 @@ if [ -z "$DEQP_SKIPS" ]; then
exit 1
fi
ARTIFACTS=`pwd`/artifacts
INSTALL=`pwd`/install
# Set up the driver environment.
export LD_LIBRARY_PATH=`pwd`/install/lib/
@ -66,7 +66,7 @@ if [ ! -s /tmp/case-list.txt ]; then
fi
if [ -n "$DEQP_EXPECTED_FAILS" ]; then
XFAIL="--xfail-list $ARTIFACTS/$DEQP_EXPECTED_FAILS"
XFAIL="--xfail-list $INSTALL/$DEQP_EXPECTED_FAILS"
fi
set +e
@ -83,7 +83,7 @@ run_cts() {
--deqp $deqp \
--output $output \
--caselist $caselist \
--exclude-list $ARTIFACTS/$DEQP_SKIPS \
--exclude-list $INSTALL/$DEQP_SKIPS \
$XFAIL \
$JOB \
--allow-flakes true \

View File

@ -7,10 +7,10 @@ if [ -z "$VK_DRIVER" ]; then
exit 1
fi
ARTIFACTS=`pwd`/artifacts
INSTALL=`pwd`/install
# Set up the driver environment.
export LD_LIBRARY_PATH=`pwd`/install/lib/
export VK_ICD_FILENAMES=`pwd`/install/share/vulkan/icd.d/"$VK_DRIVER"_icd.x86_64.json
"$ARTIFACTS/fossils/fossils.sh" "$ARTIFACTS/fossils.yml"
"$INSTALL/fossils/fossils.sh" "$INSTALL/fossils.yml"

View File

@ -83,6 +83,9 @@ actions:
- export {{ env_vars }}
{% endif %}
# deqp-runner.sh assumes some stuff is in pwd
- cd /
- export DEQP_NO_SAVE_RESULTS=1
- 'export DEQP_RUNNER_OPTIONS="--compact-display false --shuffle false"'
- export DEQP_EXPECTED_FAILS=deqp-{{ gpu_version }}-fails.txt
@ -90,15 +93,7 @@ actions:
- export DEQP_VER={{ deqp_version }}
- export LIBGL_DRIVERS_PATH=`pwd`/install/lib/dri
# Put stuff where the runner script expects it
- mkdir artifacts
- mkdir results
- mkdir -p install/lib
- cp /deqp/$DEQP_EXPECTED_FAILS artifacts/.
- cp /deqp/$DEQP_SKIPS artifacts/.
- mv /mesa/lib/* install/lib/.
- "if sh /deqp/deqp-runner.sh; then
- "if sh /install/deqp-runner.sh; then
echo 'deqp: pass';
else
echo 'deqp: fail';

View File

@ -3,7 +3,7 @@
set -e
set -o xtrace
VERSION=`cat artifacts/VERSION`
VERSION=`cat install/VERSION`
cd /piglit
@ -15,7 +15,7 @@ xvfb-run --server-args="-noreset" sh -c \
PIGLIT_RESULTS=${PIGLIT_RESULTS:-$PIGLIT_PROFILES}
mkdir -p .gitlab-ci/piglit
cp $OLDPWD/artifacts/piglit/$PIGLIT_RESULTS.txt .gitlab-ci/piglit/$PIGLIT_RESULTS.txt.baseline
cp $OLDPWD/install/piglit/$PIGLIT_RESULTS.txt .gitlab-ci/piglit/$PIGLIT_RESULTS.txt.baseline
./piglit summary console $OLDPWD/results | head -n -1 | grep -v ": pass" >.gitlab-ci/piglit/$PIGLIT_RESULTS.txt
if diff -q .gitlab-ci/piglit/$PIGLIT_RESULTS.txt{.baseline,}; then

View File

@ -22,20 +22,23 @@ find install -name \*.so -exec $STRIP {} \;
# Test runs don't pull down the git tree, so put the dEQP helper
# script and associated bits there.
mkdir -p artifacts/
cp VERSION artifacts/
cp -Rp .gitlab-ci/deqp* artifacts/
cp -Rp .gitlab-ci/piglit artifacts/
cp -Rp .gitlab-ci/traces.yml artifacts/
cp -Rp .gitlab-ci/tracie artifacts/
cp -Rp .gitlab-ci/tracie-runner-gl.sh artifacts/
cp -Rp .gitlab-ci/tracie-runner-vk.sh artifacts/
cp -Rp .gitlab-ci/fossils.yml artifacts/
cp -Rp .gitlab-ci/fossils artifacts/
cp -Rp .gitlab-ci/fossilize-runner.sh artifacts/
cp VERSION install/
cp -Rp .gitlab-ci/deqp* install/
cp -Rp .gitlab-ci/piglit install/
cp -Rp .gitlab-ci/traces.yml install/
cp -Rp .gitlab-ci/tracie install/
cp -Rp .gitlab-ci/tracie-runner-gl.sh install/
cp -Rp .gitlab-ci/tracie-runner-vk.sh install/
cp -Rp .gitlab-ci/fossils.yml install/
cp -Rp .gitlab-ci/fossils install/
cp -Rp .gitlab-ci/fossilize-runner.sh install/
cp -Rp .gitlab-ci/deqp-runner.sh install/
cp -Rp .gitlab-ci/deqp-*-fails.txt install/
cp -Rp .gitlab-ci/deqp-*-skips.txt install/
# Tar up the install dir so that symlinks and hardlinks aren't each
# packed separately in the zip file.
mkdir -p artifacts/
tar -cf artifacts/install.tar install
# If the container has LAVA stuff, prepare the artifacts for LAVA jobs
@ -45,13 +48,8 @@ if [ -d /lava-files ]; then
cp /lava-files/*.dtb artifacts/.
# Pack ramdisk for LAVA
mkdir -p /lava-files/rootfs-${CROSS:-arm64}/mesa
cp -a install/* /lava-files/rootfs-${CROSS:-arm64}/mesa/.
cp .gitlab-ci/deqp-runner.sh /lava-files/rootfs-${CROSS:-arm64}/deqp/.
cp .gitlab-ci/deqp-*-fails.txt /lava-files/rootfs-${CROSS:-arm64}/deqp/.
cp .gitlab-ci/deqp-*-skips.txt /lava-files/rootfs-${CROSS:-arm64}/deqp/.
find /lava-files/rootfs-${CROSS:-arm64}/ -type f -printf "%s\t%i\t%p\n" | sort -n | tail -100
mkdir -p /lava-files/rootfs-${CROSS:-arm64}/install
cp -a install/* /lava-files/rootfs-${CROSS:-arm64}/install/.
pushd /lava-files/rootfs-${CROSS:-arm64}/
find -H | cpio -H newc -o | gzip -c - > $CI_PROJECT_DIR/artifacts/lava-rootfs-${CROSS:-arm64}.cpio.gz

View File

@ -2,7 +2,7 @@
set -ex
ARTIFACTS="$(pwd)/artifacts"
INSTALL="$(pwd)/install"
# Set up the driver environment.
export LD_LIBRARY_PATH="$LD_LIBRARY_PATH:$(pwd)/install/lib/"
@ -23,6 +23,6 @@ export DISPLAY=
export WAFFLE_PLATFORM=surfaceless_egl
# Perform a self-test to ensure tracie is working properly.
"$ARTIFACTS/tracie/tests/test.sh"
"$INSTALL/tracie/tests/test.sh"
python3 $ARTIFACTS/tracie/tracie.py --file $ARTIFACTS/traces.yml --device-name $DEVICE_NAME
python3 $INSTALL/tracie/tracie.py --file $INSTALL/traces.yml --device-name $DEVICE_NAME

View File

@ -2,7 +2,7 @@
set -ex
ARTIFACTS="$(pwd)/artifacts"
INSTALL="$(pwd)/install"
# Set the Vulkan driver to use.
export VK_ICD_FILENAMES="$(pwd)/install/share/vulkan/icd.d/${VK_DRIVER}_icd.x86_64.json"
@ -12,7 +12,7 @@ export VK_LAYER_PATH="$VK_LAYER_PATH:/VulkanTools/build/etc/vulkan/explicit_laye
export LD_LIBRARY_PATH="$LD_LIBRARY_PATH:/VulkanTools/build/lib"
# Perform a self-test to ensure tracie is working properly.
"$ARTIFACTS/tracie/tests/test.sh"
"$INSTALL/tracie/tests/test.sh"
ret=0
@ -22,6 +22,6 @@ ret=0
# file:
# https://docs.gitlab.com/runner/configuration/advanced-configuration.html#the-runners-section
PATH="/gfxreconstruct/build/bin:$PATH" \
python3 $ARTIFACTS/tracie/tracie.py --file $ARTIFACTS/traces.yml --device-name $DEVICE_NAME
python3 $INSTALL/tracie/tracie.py --file $INSTALL/traces.yml --device-name $DEVICE_NAME
exit $ret