blob: b59cb20bc1b163a5cf29e2a9307b0d4f40c7bd51 [file] [log] [blame]
# Copyright 2024 The IREE Authors
#
# Licensed under the Apache License v2.0 with LLVM Exceptions.
# See https://llvm.org/LICENSE.txt for license information.
# SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
name: PkgCI Test NVIDIA T4
on:
workflow_call:
inputs:
artifact_run_id:
type: string
default: ""
workflow_dispatch:
inputs:
artifact_run_id:
type: string
default: ""
jobs:
test_t4:
# TODO(#18238): migrate to new runner cluster
runs-on:
- self-hosted # must come first
- runner-group=${{ github.event_name == 'pull_request' && 'presubmit' || 'postsubmit' }}
- environment=prod
- gpu
- os-family=Linux
env:
PACKAGE_DOWNLOAD_DIR: ${{ github.workspace }}/.packages
BUILD_DIR: build-tests
VENV_DIR: ${{ github.workspace }}/.venv
CC: clang
CXX: clang++
IREE_CPU_DISABLE: 1
IREE_VULKAN_DISABLE: 0
IREE_CUDA_ENABLE: 1
IREE_HIP_ENABLE: 0
steps:
- name: Check out repository
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
with:
submodules: false
- name: Check out runtime submodules
run: ./build_tools/scripts/git/update_runtime_submodules.sh
- name: Query GPU information
run: |
./build_tools/scripts/check_cuda.sh
./build_tools/scripts/check_vulkan.sh
- uses: actions/setup-python@f677139bbe7f9c59b41e40162b753c062f5d49a3 # v5.1.0
with:
# Must match the subset of versions built in pkgci_build_packages.
python-version: "3.11"
- uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 # v4.1.8
with:
name: linux_x86_64_release_packages
path: ${{ env.PACKAGE_DOWNLOAD_DIR }}
- name: Setup base venv
run: |
./build_tools/pkgci/setup_venv.py ${VENV_DIR} \
--artifact-path=${PACKAGE_DOWNLOAD_DIR} \
--fetch-gh-workflow=${{ inputs.artifact_run_id }}
- name: Install build dependencies
run: |
sudo apt update
sudo apt install -y cmake clang ninja-build libstdc++-12-dev
- name: Build tests
run: ./build_tools/pkgci/build_tests_using_package.sh ${VENV_DIR}/bin
- name: Run GPU tests
env:
CTEST_PARALLEL_LEVEL: 2
IREE_CTEST_LABEL_REGEX: ^requires-gpu|^driver=vulkan$|^driver=cuda$
IREE_NVIDIA_GPU_TESTS_DISABLE: 0
IREE_NVIDIA_SM80_TESTS_DISABLE: 1
IREE_MULTI_DEVICE_TESTS_DISABLE: 1
IREE_VULKAN_F16_DISABLE: 0
run: ./build_tools/cmake/ctest_all.sh ${BUILD_DIR}