Skip to content

Commit 4d0866d

Browse files
committed
[Backend Tester] Add nightly CI job for XNNPACK
ghstack-source-id: 4b4a036 ghstack-comment-id: 3185963689 Pull-Request: #13390
1 parent 19d077d commit 4d0866d

File tree

2 files changed

+50
-0
lines changed

2 files changed

+50
-0
lines changed

.ci/scripts/backend-test-linux.sh

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
#!/usr/bin/env bash
2+
# Copyright (c) Meta Platforms, Inc. and affiliates.
3+
# All rights reserved.
4+
#
5+
# This source code is licensed under the BSD-style license found in the
6+
# LICENSE file in the root directory of this source tree.
7+
set -eux
8+
9+
# shellcheck source=/dev/null
10+
source "$(dirname "${BASH_SOURCE[0]}")/utils.sh"
11+
12+
read -r SUITE FLOW < <(parse_args "$@")
13+
14+
# The generic Linux job chooses to use base env, not the one setup by the image
15+
eval "$(conda shell.bash hook)"
16+
CONDA_ENV=$(conda env list --json | jq -r ".envs | .[-1]")
17+
conda activate "${CONDA_ENV}"
18+
19+
# Setup swiftshader and Vulkan SDK which are required to build the Vulkan delegate
20+
#source .ci/scripts/setup-vulkan-linux-deps.sh
21+
22+
# We need the runner to test the built library.
23+
.ci/scripts/setup-linux.sh "cmake" "release" "false"
24+
25+
python -m executorch.backends.test.suite.runner $SUITE --flow $FLOW --report test_results.csv

.github/workflows/nightly.yml

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,3 +36,28 @@ jobs:
3636
uses: ./.github/workflows/_link_check.yml
3737
with:
3838
ref: ${{ github.sha }}
39+
40+
backend-test-linux:
41+
uses: pytorch/test-infra/.github/workflows/linux_job_v2.yml@main
42+
strategy:
43+
fail-fast: false
44+
matrix:
45+
flow: [xnnpack, xnnpack_static_int8_per_channel]
46+
suite: [models, operators]
47+
runner: [linux.2xlarge]
48+
docker-image: [executorch-ubuntu-22.04-clang12]
49+
with:
50+
ref: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.sha || github.sha }}
51+
runner: ${{ matrix.runner }}
52+
docker-image: ci-image:${{ matrix.docker-image }}
53+
submodules: recursive
54+
timeout: 90
55+
script: |
56+
set -eux
57+
# The generic Linux job chooses to use base env, not the one setup by the image
58+
CONDA_ENV=$(conda env list --json | jq -r ".envs | .[-1]")
59+
conda activate "${CONDA_ENV}"
60+
61+
./install_requirements.sh > /dev/null
62+
cmake --preset ${{ matrix.preset }}
63+
cmake --build cmake-out -j$(( $(nproc) - 1 ))

0 commit comments

Comments
 (0)