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
60 lines
1.6 KiB
Bash
60 lines
1.6 KiB
Bash
#!/bin/bash
|
|
# Copyright © Advanced Micro Devices, Inc., or its affiliates.
|
|
# SPDX-License-Identifier: MIT
|
|
|
|
# Get the directory where the script is located
|
|
BUILD_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
|
|
|
# Go one level up to PACKAGE_HOME
|
|
PACKAGE_HOME="$(dirname "$BUILD_DIR")"
|
|
|
|
SCRIPT_DIR="$PACKAGE_HOME/script/"
|
|
|
|
# Search for build.ninja under PACKAGE_HOME
|
|
BUILD_NINJA_FILE="$PACKAGE_HOME/build/build.ninja"
|
|
|
|
if [ -z "$BUILD_NINJA_FILE" ]; then
|
|
echo "Error: build.ninja not found under $PACKAGE_HOME"
|
|
exit 1
|
|
fi
|
|
|
|
python3 "$SCRIPT_DIR/dependency-parser/main.py" parse "$BUILD_NINJA_FILE" --workspace-root "$PACKAGE_HOME"
|
|
|
|
# Get the directory containing build.ninja
|
|
BUILD_DIR=$(dirname "$BUILD_NINJA_FILE")
|
|
|
|
# Path to dapper_mapping.json in the same directory
|
|
JSON_FILE="$BUILD_DIR/miopen_dapper_mapping.json"
|
|
|
|
# Check if the JSON file exists
|
|
if [ ! -f "$JSON_FILE" ]; then
|
|
echo "Error: $JSON_FILE not found."
|
|
exit 1
|
|
fi
|
|
|
|
branch=$(git rev-parse --abbrev-ref HEAD)
|
|
|
|
# Run the command
|
|
python3 "$SCRIPT_DIR/dependency-parser/main.py" select "$JSON_FILE" origin/develop $branch --folder ../
|
|
|
|
# Path to miopen_dapper_tests.json in the same directory
|
|
TEST_FILE="miopen_dapper_tests.json"
|
|
|
|
command=$(python3 -c "
|
|
import json
|
|
import os
|
|
with open('$TEST_FILE', 'r') as f:
|
|
data = json.load(f)
|
|
tests = data.get('tests_to_run', [])
|
|
if tests:
|
|
# Extract just the filename after the last '/'
|
|
clean_tests = [os.path.basename(test) for test in tests]
|
|
print('ctest -R \"' + '|'.join(clean_tests) + '\"')
|
|
else:
|
|
print('# No tests to run')
|
|
")
|
|
|
|
echo "$command"
|
|
|
|
eval "$command"
|