Skip to content

Commit

Permalink
Merge branch 'main' into brosko/soc_new_api6
Browse files Browse the repository at this point in the history
  • Loading branch information
broskoTT committed Feb 7, 2025
2 parents 971671a + e7e86d7 commit 4ee3370
Show file tree
Hide file tree
Showing 429 changed files with 14,334 additions and 5,967 deletions.
11 changes: 8 additions & 3 deletions .github/actions/docker-run/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ inputs:
description: 'Docker image architecture'
required: false
default: tt-metalium/ubuntu-20.04-amd64
docker_version:
description: 'Specify version for the Docker image tag to use.'
docker_image:
description: 'Specify Docker image to use.'
required: false
docker_username:
description: docker login username
Expand All @@ -37,11 +37,16 @@ inputs:
runs:
using: "composite"
steps:
- name: Set docker image tag
if: ${{ inputs.docker_image }}
shell: bash
run: |
echo "TT_METAL_DOCKER_IMAGE_TAG=${{ inputs.docker_image }}" >> $GITHUB_ENV
- name: Determine docker image tag
if: ${{ ! inputs.docker_image }}
uses: ./.github/actions/generate-docker-tag
with:
image: ${{ inputs.docker_os_arch }}
version: ${{ inputs.docker_version }}
- name: Set
shell: bash
run: |
Expand Down
45 changes: 20 additions & 25 deletions .github/actions/generate-docker-tag/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,39 +2,34 @@ name: "Run set of commands in Docker"
description: "Run commands in docker"

inputs:
run_args:
description: 'Commands to run in docker'
required: true
image:
description: 'Docker image to run commands in - follows os-arch format'
required: false
default: ubuntu-20.04-amd64
version:
description: 'Docker image version'
required: false
runs:
using: "composite"
steps:
- name: Determine Docker Tag
shell: bash
run: |
# If the version was provided use it, otherwise, determine what the version should be.
if [ "${{ inputs.version }}" != "" ]; then
echo "IMAGE_TAG=${{ inputs.version }}" >> $GITHUB_ENV
else
if [[ "${GITHUB_REF_NAME}" == "main" ]]; then
echo "IMAGE_TAG=latest" >> $GITHUB_ENV
else
echo "IMAGE_TAG=dev-${GITHUB_REF_NAME//\//-}" >> $GITHUB_ENV
fi
fi
- name: Determine Full Docker Image Tag
- name: Deprecation warning
shell: bash
run: |
echo "TT_METAL_DOCKER_IMAGE_TAG=ghcr.io/${{ github.repository }}/${{ inputs.image }}:${{ env.IMAGE_TAG }}" >> $GITHUB_ENV
echo "TT_METAL_REF_IMAGE_TAG=ghcr.io/${{ github.repository }}/${{ inputs.image }}:latest" >> $GITHUB_ENV
- name: Output Docker Image Tag
echo "::notice::[DEPRECATION] This action is deprecated. Please migrate to reading the Docker image from the pipeline."
- name: Checkout repo
uses: actions/checkout@v3
with:
fetch-depth: 1
clean: false

- name: Compute tags
id: tags
shell: bash
run: |
echo "IMAGE_TAG=${{ env.IMAGE_TAG }}"
echo "TT_METAL_DOCKER_IMAGE_TAG=${{ env.TT_METAL_DOCKER_IMAGE_TAG}}"
BUILD_TAG=$(cat \
install_dependencies.sh \
dockerfile/Dockerfile \
tt_metal/python_env/requirements-dev.txt \
docs/requirements-docs.txt \
tests/sweep_framework/requirements-sweeps.txt \
| sha1sum | cut -d' ' -f1)
echo "BUILD_TAG=$BUILD_TAG" >> $GITHUB_ENV
echo "TT_METAL_DOCKER_IMAGE_TAG=ghcr.io/${{ github.repository }}/${{ inputs.image }}:${BUILD_TAG}" >> $GITHUB_ENV
67 changes: 0 additions & 67 deletions .github/workflows/_build-wheels-impl.yaml

This file was deleted.

6 changes: 6 additions & 0 deletions .github/workflows/_produce-data.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,12 @@ jobs:
echo "attempt-number=$attempt_number" >> "$GITHUB_OUTPUT"
echo "::notice title=target-workflow-link::The workflow being analyzed is available at https://github.com/tenstorrent/tt-metal/actions/runs/$run_id/attempts/$attempt_number"
- name: Get API rate limit status
env:
GH_TOKEN: ${{ github.token }}
run: |
echo "[Info] Grabbing API rate limit status"
gh api rate_limit
- name: Output auxiliary values
env:
GH_TOKEN: ${{ github.token }}
Expand Down
44 changes: 22 additions & 22 deletions .github/workflows/all-post-commit-workflows.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,35 +38,24 @@ jobs:
static-checks:
uses: ./.github/workflows/all-static-checks.yaml
secrets: inherit
build-wheels:
needs: build-artifact
strategy:
matrix:
# Since pre-compiled builds only run on 20.04, we can only test on 20.04 for now
# The full 22.04 flow can be tested without precompiled
os: [ubuntu-20.04]
uses: ./.github/workflows/_build-wheels-impl.yaml
with:
os: ${{ matrix.os }}
from-precompiled: true
secrets: inherit
test-wheels:
needs: build-wheels
uses: ./.github/workflows/_test-wheels-impl.yaml
with:
from-precompiled: true
secrets: inherit
build-artifact:
uses: ./.github/workflows/build-artifact.yaml
secrets: inherit
with:
build-type: ${{ inputs.build-type || 'Release' }}
build-wheel: true
build-artifact-profiler:
uses: ./.github/workflows/build-artifact.yaml
with:
build-type: ${{ inputs.build-type || 'Release' }}
tracy: true
secrets: inherit
test-wheels:
needs: build-artifact
uses: ./.github/workflows/_test-wheels-impl.yaml
with:
from-precompiled: true
secrets: inherit
# Slow Dispatch Unit Tests
sd-unit-tests:
needs: build-artifact
Expand All @@ -85,7 +74,7 @@ jobs:
runner-label: ${{ matrix.test-group.runner-label }}
# Fast Dispatch Unit Tests
fast-dispatch-unit-tests:
needs: build-wheels
needs: build-artifact
secrets: inherit
strategy:
fail-fast: false
Expand All @@ -102,7 +91,7 @@ jobs:
runner-label: ${{ matrix.test-group.runner-label }}
# TTNN FD Unit tests
ttnn-unit-tests:
needs: build-wheels
needs: build-artifact
secrets: inherit
strategy:
fail-fast: false
Expand All @@ -118,7 +107,7 @@ jobs:
runner-label: ${{ matrix.test-group.runner-label }}
# FD Model Tests
models-unit-tests:
needs: build-wheels
needs: build-artifact
secrets: inherit
strategy:
fail-fast: false
Expand Down Expand Up @@ -168,10 +157,21 @@ jobs:
with:
arch: ${{ matrix.test-group.arch }}
runner-label: ${{ matrix.test-group.runner-label }}
profiler-regression:
run-profiler-regression:
needs: build-artifact-profiler
strategy:
fail-fast: false
matrix:
test-group: [
{ arch: grayskull, runner-label: E150 },
{ arch: wormhole_b0, runner-label: N150 },
{ arch: wormhole_b0, runner-label: N300 },
]
uses: ./.github/workflows/run-profiler-regression.yaml
secrets: inherit
with:
arch: ${{ matrix.test-group.arch}}
runner-label: ${{ matrix.test-group.runner-label}}
build-docs:
needs: build-artifact
uses: ./.github/workflows/docs-latest-public.yaml
Expand Down
16 changes: 3 additions & 13 deletions .github/workflows/all-static-checks.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -104,23 +104,13 @@ jobs:
- uses: lukka/get-cmake@b516803a3c5fac40e2e922349d15cdebdba01e60
if: steps.changed-cmake-files.outputs.any_changed == 'true'
with:
cmakeVersion: "~3.18.0"
cmakeVersion: "~3.19.0"
- name: Check CMake version
if: steps.changed-cmake-files.outputs.any_changed == 'true'
run: cmake --version
- name: Install LLVM and Clang
- name: Install Build Dependencies
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
run: sudo ./install_dependencies.sh --mode build
- name: Check CMake compatibility
if: steps.changed-cmake-files.outputs.any_changed == 'true'
env:
Expand Down
31 changes: 25 additions & 6 deletions .github/workflows/blackhole-post-commit.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,15 @@ on:
required: true
type: string
default: 'BH'
build-type:
required: false
default: Release
type: choice
options:
- Release
- Debug
- RelWithDebInfo
- CI
schedule:
- cron: "0 */2 * * *"
# Pause this since not enough runners to support every commit to main
Expand All @@ -37,13 +46,23 @@ jobs:
uses: ./.github/workflows/build-artifact.yaml
secrets: inherit
with:
build-type: ${{ inputs.build-type || 'Release' }}
build-wheel: true
version: "22.04"
build-wheels:
needs: build-artifact
uses: ./.github/workflows/_build-wheels-impl.yaml
build-artifact-profiler:
uses: ./.github/workflows/build-artifact.yaml
secrets: inherit
with:
os: "ubuntu-22.04"
from-precompiled: true
build-type: ${{ inputs.build-type || 'Release' }}
tracy: true
version: "20.04"
run-profiler-regression:
needs: build-artifact-profiler
uses: ./.github/workflows/run-profiler-regression.yaml
secrets: inherit
with:
arch: "blackhole"
runner-label: ${{ inputs.runner-label || 'BH' }}
umd-unit-tests:
secrets: inherit
uses: ./.github/workflows/umd-unit-tests.yaml
Expand All @@ -60,7 +79,7 @@ jobs:
timeout: 30
os: "ubuntu-22.04"
fd-unit-tests:
needs: build-wheels
needs: build-artifact
uses: ./.github/workflows/fast-dispatch-build-and-unit-tests.yaml
secrets: inherit
with:
Expand Down
14 changes: 1 addition & 13 deletions .github/workflows/build-and-test-wheels.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,20 +15,8 @@ jobs:
if: ${{ github.event_name == 'workflow_dispatch' && inputs.from-precompiled }}
uses: ./.github/workflows/build-artifact.yaml
secrets: inherit
build-wheels:
needs: build-artifact
if: ${{ always() }}
strategy:
matrix:
# Since pre-compiled builds only run on 20.04, we can only test on 20.04 for now
# The full 22.04 flow can be tested without precompiled
os: ${{ fromJson((github.event_name == 'schedule' || inputs.from-precompiled) && '["ubuntu-20.04"]' || '["ubuntu-20.04", "ubuntu-22.04"]') }}
uses: ./.github/workflows/_build-wheels-impl.yaml
with:
os: ${{ matrix.os }}
from-precompiled: ${{ inputs.from-precompiled }}
test-wheels:
needs: build-wheels
needs: build-artifact
if: ${{ always() }}
uses: ./.github/workflows/_test-wheels-impl.yaml
with:
Expand Down
Loading

0 comments on commit 4ee3370

Please sign in to comment.