Skip to content

Commit

Permalink
#10800: Rework SD build and unit test workflow to accept inputs
Browse files Browse the repository at this point in the history
  • Loading branch information
ttmchiou committed Jul 30, 2024
1 parent f212d4b commit 69e724d
Show file tree
Hide file tree
Showing 2 changed files with 48 additions and 25 deletions.
19 changes: 18 additions & 1 deletion .github/workflows/build-and-unit-tests-wrapper.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,24 @@ jobs:
build-artifact:
uses: ./.github/workflows/build-artifact.yaml
secrets: inherit
sd-unit-tests:
sd-unit-tests-gs:
needs: build-artifact
uses: ./.github/workflows/build-and-unit-tests.yaml
secrets: inherit
with:
arch: grayskull
runner-label: E150
sd-unit-tests-n150:
needs: build-artifact
uses: ./.github/workflows/build-and-unit-tests.yaml
secrets: inherit
with:
arch: wormhole_b0
runner-label: N150
sd-unit-tests-n300:
needs: build-artifact
uses: ./.github/workflows/build-and-unit-tests.yaml
secrets: inherit
with:
arch: wormhole_b0
runner-label: N300
54 changes: 30 additions & 24 deletions .github/workflows/build-and-unit-tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,41 +2,47 @@ name: "[internal] Slow Dispatch unit tests impl"

on:
workflow_call:

inputs:
arch:
required: true
type: string
runner-label:
required: true
type: string
workflow_dispatch:
inputs:
arch:
required: true
type: choice
options:
- grayskull
- wormhole_b0
- blackhole
runner-label:
required: true
type: choice
options:
- E150
- N150
- N300
- BH
jobs:
unit-tests-slow-dispatch:
name: ${{ matrix.runner-info.arch }} ${{ matrix.runner-info.name }}

strategy:
# Do not fail-fast because we need to ensure all tests go to completion
# so we try not to get hanging machines
fail-fast: false
matrix:
runner-info: [
{arch: grayskull, runs-on: ["grayskull"], name: E150},
# N150
{arch: wormhole_b0, runs-on: ["wormhole_b0", "multi-chip-num-pcie-1", "multi-chip-num-chips-1"], name: N150},
# N300
{arch: wormhole_b0, runs-on: ["wormhole_b0", "multi-chip-num-pcie-1", "multi-chip-num-chips-2"], name: N300},
]
name: ${{ inputs.arch }} ${{ inputs.runner-label }}
runs-on:
- ${{ inputs.runner-label }}
- "in-service"
env:
TT_METAL_ENV: ${{ vars.TT_METAL_ENV }}
ARCH_NAME: ${{ matrix.runner-info.arch }}
ARCH_NAME: ${{ inputs.arch}}
TT_METAL_SLOW_DISPATCH_MODE: 1
LOGURU_LEVEL: INFO
LD_LIBRARY_PATH: ${{ github.workspace }}/build/lib
runs-on: ${{ matrix.runner-info.runs-on }}
steps:
- uses: tenstorrent-metal/metal-workflows/.github/actions/[email protected]
- uses: ./.github/actions/prepare-metal-run
- name: Set up dynamic env vars for build
run: |
echo "TT_METAL_HOME=$(pwd)" >> $GITHUB_ENV
- uses: actions/download-artifact@v4
with:
name: TTMetal_build_${{ matrix.runner-info.arch }}
- name: Extract files
run: tar -xvf ttm_${{ matrix.runner-info.arch }}.tar
- uses: ./.github/actions/install-python-deps
- name: Run pre/post regression tests
timeout-minutes: 15
run: |
Expand Down

0 comments on commit 69e724d

Please sign in to comment.