#15450: Remove default values from circular buffer parameters in LLK compute APIs: Bcast #37460
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: "[post-commit] all - Static checks, linters etc." | |
on: | |
workflow_dispatch: | |
workflow_call: | |
pull_request: | |
branches: | |
- "main" | |
jobs: | |
pre-commit: | |
name: Run Pre-commit Hooks | |
runs-on: ubuntu-latest | |
permissions: | |
contents: write | |
pull-requests: write | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 # Fetch all history so 'origin/main' is available | |
fetch-refs: true # Ensure all refs are fetched | |
- name: Set up Python | |
uses: actions/setup-python@v4 | |
with: | |
python-version: 3.11 | |
- name: Run Pre-commit | |
uses: pre-commit/[email protected] | |
with: | |
extra_args: | | |
--from-ref ${{ github.event_name == 'pull_request' && format('refs/remotes/origin/{0}', github.event.pull_request.base.ref) || 'HEAD^' }} \ | |
--to-ref HEAD | |
continue-on-error: false | |
check-black: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Do Nothing | |
run: echo "Black is covered by pre-commit. This is a placeholder to be removed after updating branch restrictions." | |
check-spdx-licenses: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/[email protected] | |
with: | |
cache: 'pip' | |
cache-dependency-path: infra/requirements-infra.txt | |
python-version: '3.10' | |
- name: Install infra deps | |
run: python -m pip install -r infra/requirements-infra.txt | |
- name: Check SPDX licenses | |
run: python -m check_copyright --verbose --dry-run --config ./check_copyright_config.yaml . | |
check-metal-kernel-count: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Check kernel count in base metal is less than maximum | |
run: if (( $(find tt_metal/kernels/ -type f | wc -l) > 8 )); then exit 1; fi | |
check-doc: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install ASPELL | |
run: sudo apt-get install -y aspell | |
- name: Run checks on docs | |
run: TT_METAL_HOME=$(pwd) docs/spellcheck.sh | |
check-forbidden-imports: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Check ttnn is not used in tt_metal tests | |
run: if (( $(grep -Rnw 'tests/tt_metal' -e 'ttnn' | wc -l ) > 11 )); then exit 1; fi | |
- name: Check tt_eager constructs is not used in tt_metal tests | |
run: | | |
if (( $(grep -Rnw 'tests/tt_metal' -e 'tt_lib' | wc -l ) > 0 )); then exit 1; fi | |
if (( $(grep -Rnw 'tests/tt_metal' -e 'tt_eager' | wc -l ) > 10 )); then exit 1; fi | |
check-sweeps-workflow: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/[email protected] | |
with: | |
python-version: '3.10' | |
- name: Check sweeps workflow option count against sweep file count | |
run: | | |
pip install pyyaml | |
python tests/sweep_framework/framework/sweeps_workflow_verification.py | |
cmake-version: | |
runs-on: ubuntu-22.04 | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
submodules: recursive | |
- name: Check for changed CMake files | |
id: changed-cmake-files | |
uses: tj-actions/changed-files@c3a1bb2c992d77180ae65be6ae6c166cf40f857c | |
with: | |
files: | | |
**/*.cmake | |
**/CMakeLists.txt | |
- uses: lukka/get-cmake@b516803a3c5fac40e2e922349d15cdebdba01e60 | |
if: steps.changed-cmake-files.outputs.any_changed == 'true' | |
with: | |
cmakeVersion: "~3.18.0" | |
- name: Check CMake version | |
if: steps.changed-cmake-files.outputs.any_changed == 'true' | |
run: cmake --version | |
- name: Install LLVM and Clang | |
if: steps.changed-cmake-files.outputs.any_changed == 'true' | |
run: | | |
wget https://apt.llvm.org/llvm.sh | |
chmod u+x llvm.sh | |
sudo ./llvm.sh 17 | |
- name: Install deps | |
if: steps.changed-cmake-files.outputs.any_changed == 'true' | |
env: | |
DEBIAN_FRONTEND: noninteractive | |
run: | | |
sudo apt update | |
sudo xargs -a scripts/docker/requirements-22.04.txt apt install -y --no-install-recommends | |
- name: Check CMake compatibility | |
if: steps.changed-cmake-files.outputs.any_changed == 'true' | |
env: | |
ARCH_NAME: wormhole_b0 | |
CMAKE_GENERATOR: Ninja | |
# TODO: Use a lukka/run-cmake with a preset after upgrading to a more modern CMake | |
run: | | |
echo "Checking compatibility with $(cmake --version)" | |
# FIXME: Why is HAVE_STD_REGEX needed? Clean up when we solve it. | |
cmake -DCMAKE_TOOLCHAIN_FILE=cmake/x86_64-linux-clang-17-libcpp-toolchain.cmake -DHAVE_STD_REGEX=ON -B build . |