Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
3d55d6a
Extend Dockerflow with GAP9 Support
Xeratec Nov 13, 2025
8ae3fef
Improve speed of LLVM cloning
Xeratec Nov 12, 2025
6acde80
Initial GAP9 Support
Xeratec Nov 13, 2025
a7ac74e
Minor cleanup
Xeratec Nov 13, 2025
f916db8
Update Readme
Xeratec Nov 13, 2025
3cd6e29
[GAP9] Fix DeeployTest.c nested team fork issue
runwangdl Nov 14, 2025
9ca4595
[GAP9]Fix GCC segmentation fault in Transpose template syntax
runwangdl Nov 14, 2025
7e77991
[GAP9] Link PULP-NN
runwangdl Nov 15, 2025
294d83a
[GAP9] OpRepre n_cores Missing
runwangdl Nov 15, 2025
4946ed5
[GAP9] LInk Math and PULP Kernels
runwangdl Nov 15, 2025
a08b6fd
[GAP9] Replace MCHAN DMA with cl_dma.h API and Decouple deployer form…
runwangdl Nov 17, 2025
b51e29d
[GAP0] WIP Tiling Support for L3
runwangdl Nov 21, 2025
6b5c2e5
[GAP9] Layernorm Epsilon ABI Issue
runwangdl Nov 21, 2025
3a1d877
[GAP9] Fixed Zero Cyclecounter Issue
runwangdl Nov 27, 2025
faa6421
[GAP9] Add CI
runwangdl Nov 28, 2025
584729c
[GAP9] Fix L2 GVSoC target build with hexlist
runwangdl Nov 28, 2025
3e2fc87
[GAP9] Sdk.config add macro for clusterstack
runwangdl Nov 28, 2025
6b55e98
[GAP9] Fix Cluster DMA Concurrent Tasks Bug with Mchan Template from …
runwangdl Nov 30, 2025
ccaad61
[GAP9] Fix free template from PULP-sdk to GAP9sdk
runwangdl Nov 30, 2025
af01a2e
[GAP9] Fix duplicate L3 Alloc Code generation due to PULP inheritance…
runwangdl Nov 30, 2025
e4ed675
Merge remote-tracking branch 'run/devel' into gap9-operators-github
runwangdl Nov 30, 2025
71896e7
[GAP9] Change GAP9 DWConV Based on PULP change
runwangdl Nov 30, 2025
f88d5c5
[GAP-CI] Update runner-gap9.yml
runwangdl Dec 16, 2025
4429a6a
[GAP-CI] Some CI Bugs fixed
runwangdl Dec 17, 2025
40d1dec
Update default docker for gap9 platform
runwangdl Jan 11, 2026
ff05304
Change other target to default docker
runwangdl Jan 11, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
82 changes: 82 additions & 0 deletions .github/workflows/_runner-gap9-tiled.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,82 @@
# SPDX-FileCopyrightText: 2025 ETH Zurich and University of Bologna
#
# SPDX-License-Identifier: Apache-2.0

---
name: _runner-gap9-tiled

"on":
workflow_call:
inputs:
runner:
required: true
type: string
docker-image:
required: true
type: string
test-name:
required: true
type: string
num-cores:
required: false
default: 8
type: number
L1:
required: false
default: "[64000]"
type: string
default-memory-level:
required: false
default: "L2"
type: string
double-buffer:
required: false
default: false
type: boolean
memory-allocation-strategy:
required: false
default: "MiniMalloc"
type: string
search-strategy:
required: false
default: "random-max"
type: string

jobs:
test-runner-gap9-tiled:
strategy:
fail-fast: false
matrix:
L1: ${{ fromJSON(inputs.L1) }}
runs-on: ${{ inputs.runner }}
container:
image: ${{ inputs.docker-image }}
steps:
- name: Checkout Repo
uses: actions/checkout@v4
with:
submodules: recursive
- name: Build Deeploy
shell: bash
run: |
source /app/install/gap9-sdk/.gap9-venv/bin/activate
source /app/install/gap9-sdk/configs/gap9_evk_audio.sh || true
pip install -e . || true
deactivate
- name: Setup ccache
uses: actions/cache@v4
with:
path: /app/.ccache
key: ccache-ci
- name: Run Test
run: |
source /app/install/gap9-sdk/.gap9-venv/bin/activate
source /app/install/gap9-sdk/configs/gap9_evk_audio.sh || true
export GVSOC_INSTALL_DIR=/app/install/gap9-sdk/install/workstation
export GAP_RISCV_GCC_TOOLCHAIN=/app/install/gcc/gap9
cd DeeployTest
mkdir -p /app/.ccache
export CCACHE_DIR=/app/.ccache
python testRunner_tiled_gap9.py -t Tests/${{ inputs.test-name }} --cores=${{ inputs.num-cores }} --l1 ${{ matrix.L1 }} --defaultMemLevel=${{ inputs.default-memory-level }} ${{ inputs.double-buffer && '--doublebuffer' || '' }} --memAllocStrategy=${{ inputs.memory-allocation-strategy }} --searchStrategy=${{ inputs.search-strategy }}
deactivate
shell: bash
63 changes: 63 additions & 0 deletions .github/workflows/_runner-gap9.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
# SPDX-FileCopyrightText: 2025 ETH Zurich and University of Bologna
#
# SPDX-License-Identifier: Apache-2.0

---
name: _runner-gap9

"on":
workflow_call:
inputs:
runner:
required: true
type: string
docker-image:
required: true
type: string
test-names:
required: true
type: string
num-cores:
required: true
type: number

jobs:
test-runner-gap9:
runs-on: ${{ inputs.runner }}
container:
image: ${{ inputs.docker-image }}
steps:
- name: Checkout Repo
uses: actions/checkout@v4
with:
submodules: recursive
- name: Build Deeploy
shell: bash
run: |
source /app/install/gap9-sdk/.gap9-venv/bin/activate
source /app/install/gap9-sdk/configs/gap9_evk_audio.sh || true
pip install -e . || true
deactivate
Comment on lines +34 to +40
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🔴 Critical

Don’t mask environment/build failures with || true.

pip install -e . || true (and source ... || true) can turn real breakages into false-green CI. Prefer failing fast unless you have an explicit fallback path.

Proposed fix
       - name: Build Deeploy
         shell: bash
         run: |
           source /app/install/gap9-sdk/.gap9-venv/bin/activate
-          source /app/install/gap9-sdk/configs/gap9_evk_audio.sh || true
-          pip install -e . || true
+          source /app/install/gap9-sdk/configs/gap9_evk_audio.sh
+          pip install -e .
           deactivate
🤖 Prompt for AI Agents
In @.github/workflows/_runner-gap9.yml around lines 34 - 40, The CI step "Build
Deeploy" currently masks failures by appending "|| true" to commands (notably
the "source /app/install/gap9-sdk/configs/gap9_evk_audio.sh || true" and "pip
install -e . || true"); remove the "|| true" from these commands so errors cause
the job to fail, and for the optional sourcing use a guarded conditional (e.g.,
test for the file before sourcing) rather than swallowing errors—locate the
commands inside the "Build Deeploy" run block in the workflow and update the
"source ... || true" and "pip install -e . || true" lines accordingly.

- name: Setup ccache
uses: actions/cache@v4
with:
path: /app/.ccache
key: ccache-ci
- name: Run Test
run: |
testNames="${{ inputs.test-names }}"
source /app/install/gap9-sdk/.gap9-venv/bin/activate
source /app/install/gap9-sdk/configs/gap9_evk_audio.sh || true
export GVSOC_INSTALL_DIR=/app/install/gap9-sdk/install/workstation
export GAP_RISCV_GCC_TOOLCHAIN=/app/install/gcc/gap9
cd DeeployTest
mkdir -p /app/.ccache
export CCACHE_DIR=/app/.ccache
echo "$testNames" | while IFS= read -r testName; do
if [[ -n "$testName" ]]; then
echo "Running test: $testName"
python testRunner_gap9.py -t Tests/$testName
fi
done
deactivate
shell: bash
2 changes: 1 addition & 1 deletion .github/workflows/_select-env.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,4 +45,4 @@ jobs:
echo "runner=self-hosted" >> "$GITHUB_OUTPUT"
else
echo "runner=ubuntu-latest" >> "$GITHUB_OUTPUT"
fi
fi
4 changes: 2 additions & 2 deletions .github/workflows/ci-deeploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ name: CI • Deeploy
docker_image_deeploy:
description: "Deeploy Image to use"
required: false
default: "ghcr.io/pulp-platform/deeploy:devel"
default: "ghcr.io/runwangdl/deeploy:gap9"
Comment on lines 17 to +20
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟠 Major

Personal Docker registry should not be used in production CI.

The default image was changed from ghcr.io/pulp-platform/deeploy:devel to ghcr.io/runwangdl/deeploy:gap9, which references a personal registry. This is problematic for:

  1. Reliability: Personal accounts can delete or modify images
  2. Security: Personal images are less auditable than organization-managed images
  3. Maintainability: The image lifecycle isn't tied to the project

Given the PR's DRAFT status, this is likely a development convenience. Before merging, ensure the image is published to the official ghcr.io/pulp-platform registry.

Expected change before merge
-        default: "ghcr.io/runwangdl/deeploy:gap9"
+        default: "ghcr.io/pulp-platform/deeploy:gap9"

Or revert to devel if GAP9-specific image isn't ready:

-        default: "ghcr.io/runwangdl/deeploy:gap9"
+        default: "ghcr.io/pulp-platform/deeploy:devel"
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
docker_image_deeploy:
description: "Deeploy Image to use"
required: false
default: "ghcr.io/pulp-platform/deeploy:devel"
default: "ghcr.io/runwangdl/deeploy:gap9"
docker_image_deeploy:
description: "Deeploy Image to use"
required: false
default: "ghcr.io/pulp-platform/deeploy:gap9"
🤖 Prompt for AI Agents
In @.github/workflows/ci-deeploy.yml around lines 17 - 20, The workflow input
docker_image_deeploy currently defaults to a personal registry image
("ghcr.io/runwangdl/deeploy:gap9"), which must not be used for CI; update the
default value of the docker_image_deeploy input to point to an official,
organization-managed image (e.g., "ghcr.io/pulp-platform/deeploy:gap9" if
published, or revert to "ghcr.io/pulp-platform/deeploy:devel" until a GAP9 image
is available) and ensure any documentation or README referencing
docker_image_deeploy is consistent with the org registry change.


concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
Expand Down Expand Up @@ -235,4 +235,4 @@ jobs:
shell: bash
run: |
cd DeeployTest
python testDmas.py
python testDmas.py
207 changes: 207 additions & 0 deletions .github/workflows/ci-platform-gap9-tiled.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,207 @@
# SPDX-FileCopyrightText: 2025 ETH Zurich and University of Bologna
#
# SPDX-License-Identifier: Apache-2.0

---
name: CI • GAP9 (Tiled)

"on":
push:
branches:
- "**"
tags:
- "v*.*.*"
pull_request:
workflow_dispatch:
inputs:
docker_image_deeploy:
description: "Deeploy Image to use"
required: false
default: "ghcr.io/runwangdl/deeploy:gap9"

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
select-env:
uses: ./.github/workflows/_select-env.yml
with:
docker_image_deeploy: ${{ inputs.docker_image_deeploy }}

gap9-kernels-tiled-singlebuffer-L2:
needs: select-env
strategy:
fail-fast: false
matrix:
test-data:
- name: "testMatMul"
L1: [64000, 32000, 16000]
- name: "test2DRequantizedConv"
L1: [8000, 6000, 4000]
- name: "test2DRequantizedStriddedPaddedConv"
L1: [600]
- name: "testRequantizedDWConv"
L1: [2561]
- name: "iSoftmax"
L1: [800, 500, 300]
- name: "testConcat"
L1: [32000, 16000, 8000]
- name: "Hardswish"
L1: [750]
- name: "RQHardswish"
L1: [750]
- name: "testFloatGEMM"
L1: [8000]
- name: "testFloat2DConvolution"
L1: [1600]
- name: "testFloat2DConvolutionBias"
L1: [6600]
- name: "testFloat2DConvolutionZeroBias"
L1: [6600]
- name: "testFloat2DDWConvolution"
L1: [7200]
- name: "testFloat2DDWConvolutionBias"
L1: [7200]
- name: "testFloat2DDWConvolutionZeroBias"
L1: [7200]
- name: "testFloatLayerNorm"
L1: [2000]
- name: "testFloatMaxPool"
L1: [2000]
- name: "testFloatMatmul"
L1: [2000]
- name: "testFloatRelu"
L1: [2000]
- name: "testFloatReshapeWithSkipConnection"
L1: [1400]
- name: "testFloatSoftmax"
L1: [4000]
- name: "testFloatTranspose"
L1: [2000]
- name: "testFloatMul"
L1: [2000]
- name: "testRQGEMMwBatch"
L1: [20000]
- name: "testMatMulBatch"
L1: [20000]
uses: ./.github/workflows/_runner-gap9-tiled.yml
with:
runner: ${{ needs.select-env.outputs.runner }}
docker-image: ${{ needs.select-env.outputs.image }}
test-name: ${{ matrix.test-data.name }}
num-cores: 8
L1: ${{ toJson(matrix.test-data.L1) }}

gap9-kernels-tiled-doublebuffer-L2:
needs: select-env
strategy:
fail-fast: false
matrix:
test-data:
- name: "testMatMul"
L1: [64000, 32000, 16000]
- name: "test2DRequantizedConv"
L1: [8000, 6000, 5000]
- name: "testRequantizedDWConv"
L1: [5121]
- name: "iSoftmax"
L1: [1600, 1000, 600]
- name: "testConcat"
L1: [64000, 32000, 16000]
- name: "Hardswish"
L1: [750]
- name: "RQHardswish"
L1: [800]
- name: "testFloatGEMM"
L1: [8000]
- name: "testFloat2DConvolution"
L1: [2000]
- name: "testFloat2DConvolutionBias"
L1: [8800]
- name: "testFloat2DConvolutionZeroBias"
L1: [8800]
- name: "testFloat2DDWConvolution"
L1: [9800]
- name: "testFloat2DDWConvolutionBias"
L1: [10000]
- name: "testFloat2DDWConvolutionZeroBias"
L1: [9800]
- name: "testFloatLayerNorm"
L1: [2000]
- name: "testFloatMaxPool"
L1: [5000]
- name: "testFloatMatmul"
L1: [5000]
- name: "testFloatRelu"
L1: [20]
- name: "testFloatReshapeWithSkipConnection"
L1: [2600]
- name: "testFloatSoftmax"
L1: [8000]
- name: "testFloatTranspose"
L1: [2000]
- name: "testFloatMul"
L1: [2000]
uses: ./.github/workflows/_runner-gap9-tiled.yml
with:
runner: ${{ needs.select-env.outputs.runner }}
docker-image: ${{ needs.select-env.outputs.image }}
test-name: ${{ matrix.test-data.name }}
num-cores: 8
L1: ${{ toJson(matrix.test-data.L1) }}
double-buffer: true

gap9-models-tiled-singlebuffer-L2:
needs: select-env
strategy:
fail-fast: false
matrix:
test-data:
- name: "simpleRegression"
L1: [45000, 30000, 15000]
- name: "miniMobileNet"
L1: [60000, 12000, 6000, 3000]
- name: "miniMobileNetv2"
L1: [60000, 16000, 12000, 8000]
- name: "Attention"
L1: [60000, 10000, 5000]
- name: "MLPerf/KeywordSpotting"
L1: [64000]
- name: "MLPerf/ImageClassification"
L1: [64000]
- name: "MLPerf/AnomalyDetection"
L1: [64000]
num-cores: [8]
uses: ./.github/workflows/_runner-gap9-tiled.yml
with:
runner: ${{ needs.select-env.outputs.runner }}
docker-image: ${{ needs.select-env.outputs.image }}
test-name: ${{ matrix.test-data.name }}
num-cores: ${{ matrix.num-cores }}
L1: ${{ toJson(matrix.test-data.L1) }}

gap9-models-tiled-doublebuffer-L2:
needs: select-env
strategy:
fail-fast: false
matrix:
test-data:
- name: "simpleRegression"
L1: [60000, 45000, 30000]
- name: "miniMobileNet"
L1: [60000, 24000, 12000, 6000]
- name: "miniMobileNetv2"
L1: [60000, 32000, 24000, 16000]
- name: "Attention"
L1: [60000, 20000, 10000, 5000]
num-cores: [8]
double-buffer: [true]
uses: ./.github/workflows/_runner-gap9-tiled.yml
with:
runner: ${{ needs.select-env.outputs.runner }}
docker-image: ${{ needs.select-env.outputs.image }}
test-name: ${{ matrix.test-data.name }}
num-cores: ${{ matrix.num-cores }}
L1: ${{ toJson(matrix.test-data.L1) }}
double-buffer: ${{ matrix.double-buffer }}
Loading