Files
derek.holloway 7502bf64a4
CodeQL / Analyze (actions) (push) Canceled after 0s
CodeQL / Analyze (python) (push) Canceled after 0s
pre-commit / pre-commit (push) Canceled after 0s
Multi-Arch CI / setup (push) Canceled after 0s
Publish build_manylinux_x86_64 images / publish_build_manylinux_x86_64 (push) Canceled after 0s
Setup (Multi-Arch) / setup (push) Canceled after 0s
Multi-Arch CI / Linux::${{ fromJSON(needs.setup.outputs.linux_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubi10 image / publish_no_rocm_image_ubi10 (push) Canceled after 0s
Multi-Arch CI / Windows::${{ fromJSON(needs.setup.outputs.windows_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Multi-Arch CI / Manifest Diff (push) Canceled after 0s
TheRock Manifest Diff Report / Generate Manifest Diff Report (push) Canceled after 0s
Multi-Arch CI / CI Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_ocl_rt images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_rocgdb images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Unit Tests / Unit Tests :: ubuntu-24.04 (push) Canceled after 0s
Unit Tests / Unit Tests :: windows-2022 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_media (push) Canceled after 0s
Unit Tests / Unit Tests Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_openmpi (push) Canceled after 0s
Flatten subprojects into a single base monorepo
2026-09-02 16:34:47 -07:00

154 lines
5.6 KiB
YAML

name: TheRock Sanity Check
on:
workflow_dispatch:
inputs:
artifact_group:
type: string
artifact_run_id:
type: string
default: ""
amdgpu_families:
type: string
default: ""
amdgpu_targets:
type: string
default: ""
test_runs_on:
type: string
platform:
type: string
workflow_call:
inputs:
artifact_group:
type: string
artifact_run_id:
type: string
default: ""
amdgpu_families:
type: string
default: ""
amdgpu_targets:
type: string
default: ""
test_runs_on:
type: string
platform:
type: string
push:
branches:
- ADHOCBUILD
permissions:
contents: read
jobs:
test_sanity_check:
if: ${{ github.repository == 'ROCm/SPIRV-LLVM-Translator' }}
name: "Sanity ROCM Test (${{ inputs.amdgpu_families }})"
runs-on: ${{ inputs.test_runs_on }}
# Running docker with cap-add and -v /lib/modiles, by recommendation of Github: https://rocm.docs.amd.com/projects/amdsmi/en/amd-staging/how-to/setup-docker-container.html
container:
image: ${{ inputs.platform == 'linux' && 'ghcr.io/rocm/no_rocm_image_ubuntu24_04@sha256:4150afe4759d14822f0e3f8930e1124f26e11f68b5c7b91ec9a02b20b1ebbb98' || null }}
# --ulimit memlock=-1:-1 - Prevents memory allocation issues with ROCm inside container
# --security-opt seccomp=unconfined - enables memory mapping, and is recommended for containers running in HPC environments
# --env-file /etc/podinfo/gha-gpu-isolation-settings - Required for GPU isolation on OSSCI MIXXX runners
# --user 0:0 - Running as root, by recommendation of GitHub: https://docs.github.com/en/actions/reference/workflows-and-actions/dockerfile-support#user
options: --ipc host
--group-add video
--device /dev/kfd
--device /dev/dri
--group-add 992
--group-add 110
--cap-add SYS_MODULE
-v /lib/modules:/lib/modules
--ulimit memlock=-1:-1
--security-opt seccomp=unconfined
--env-file /etc/podinfo/gha-gpu-isolation-settings
--user 0:0
defaults:
run:
shell: bash
env:
VENV_DIR: ${{ github.workspace }}/.venv
ARTIFACT_RUN_ID: "${{ inputs.artifact_run_id != '' && inputs.artifact_run_id || github.run_id }}"
OUTPUT_ARTIFACTS_DIR: ${{ github.workspace }}/build
THEROCK_BIN_DIR: ${{ github.workspace }}/build/bin
AMDGPU_FAMILIES: ${{ inputs.amdgpu_families }}
AMDGPU_TARGETS: ${{ inputs.amdgpu_targets }}
ARTIFACT_GROUP: ${{ inputs.artifact_group }}
steps:
- name: "Fetch 'build_tools' from repository"
if: ${{ runner.os == 'Windows' }}
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
sparse-checkout: build_tools
path: prejob
- name: Pre-job cleanup processes on Windows
if: ${{ runner.os == 'Windows' }}
timeout-minutes: 5
shell: powershell
run: . '${{ github.workspace }}\prejob\build_tools\github_actions\cleanup_processes.ps1'
- name: Checkout Repository
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
repository: "ROCm/TheRock"
ref: 'compiler/amd-staging'
- name: Pre-job cleanup Docker containers on Linux
if: ${{ runner.os == 'Linux' }}
timeout-minutes: 5
shell: bash
run: |
# Remove any stopped containers
docker container prune -f || true
# Remove dangling networks
docker network prune -f || true
- name: Run setup test environment workflow
timeout-minutes: 15
uses: './.github/actions/setup_test_environment'
with:
ARTIFACT_GROUP: ${{ inputs.artifact_group }}
AMDGPU_TARGETS: ${{ inputs.amdgpu_targets }}
ARTIFACT_RUN_ID: ${{ env.ARTIFACT_RUN_ID }}
OUTPUT_ARTIFACTS_DIR: ${{ env.OUTPUT_ARTIFACTS_DIR }}
VENV_DIR: ${{ env.VENV_DIR }}
FETCH_ARTIFACT_ARGS: "--base-only"
IS_PR_FROM_FORK: ${{ github.event.pull_request.head.repo.fork }}
# The sanity checks run tools like 'offload-arch' which may search for
# DLLs on multiple search paths (PATH, CWD, system32, etc.).
# For typical "installs" of ROCm, the rocm/bin/ dir can be expected to be
# added to PATH, so we do that here. If we don't do this, DLLs on test
# runners in system32 may be picked up instead and the tests may not be
# representative, see https://github.com/ROCm/TheRock/issues/2019 and
# https://github.com/ROCm/TheRock/pull/3230#issuecomment-3844854922.
- name: Set PATH and HIP_CLANG_PATH for windows
if: ${{ runner.os == 'Windows' }}
run: |
echo "HIP_CLANG_PATH=${OUTPUT_ARTIFACTS_DIR}\lib\llvm\bin" >> $GITHUB_ENV
echo "${OUTPUT_ARTIFACTS_DIR}\bin" >> $GITHUB_PATH
- name: Driver / GPU sanity check
timeout-minutes: 3
run: |
python ./build_tools/print_driver_gpu_info.py
- name: Run ROCm Sanity Tests
timeout-minutes: 5
env:
# Enable verbose logging, see
# https://rocm.docs.amd.com/projects/HIP/en/latest/how-to/debugging.html
AMD_LOG_LEVEL: 4
run: |
pytest tests/ --log-cli-level=info --timeout=300
- name: Post-job cleanup processes on Windows
if: ${{ always() && runner.os == 'Windows' }}
timeout-minutes: 5
shell: powershell
run: . '${{ github.workspace }}\build_tools\github_actions\cleanup_processes.ps1'