Skip to content

Align AArch64 ACL integration with oneDNN v3.10.x #68

Align AArch64 ACL integration with oneDNN v3.10.x

Align AArch64 ACL integration with oneDNN v3.10.x #68

Workflow file for this run

# *******************************************************************************
# Copyright 2024-2025 Arm Limited and affiliates.
# Copyright 2025 Intel Corporation
# SPDX-License-Identifier: Apache-2.0
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
# *******************************************************************************
name: "CI RISC-V"
on:
push:
branches: [v3.10_for_ie_master, "rls-*"]
paths:
- ".github/automation/riscv/**"
- ".github/workflows/ci-riscv.yml"
- "cmake/**"
- "examples/**"
- "include/**"
- "src/common/**"
- "src/cpu/*"
- "src/cpu/rv64/**"
- "tests/**"
- "CMakeLists.txt"
pull_request:
types: [opened, synchronize, reopened]
paths:
- ".github/automation/riscv/**"
- ".github/workflows/ci-riscv.yml"
- "cmake/**"
- "examples/**"
- "include/**"
- "src/common/**"
- "src/cpu/*"
- "src/cpu/rv64/**"
- "tests/**"
- "CMakeLists.txt"
workflow_dispatch:
concurrency:
group: ${{ github.workflow }}-${{ github.event_name == 'pull_request' && format('pr-{0}', github.event.pull_request.number) || github.ref }}
cancel-in-progress: ${{ github.ref != format('refs/heads/{0}', github.event.repository.default_branch) }}
permissions: read-all
jobs:
build:
strategy:
fail-fast: true
matrix:
config: [
{ name: riscv-build, label: ubuntu-24.04, threading: OMP, toolset: gcc, build: RelWithAssert, testset: SMOKE }
]
name: ${{ matrix.config.name }}, ${{ matrix.config.toolset }}, ${{ matrix.config.threading }}, ${{ matrix.config.build }}
runs-on: ${{ matrix.config.label }}
steps:
- name: Checkout oneDNN
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
persist-credentials: false
path: oneDNN
- name: Read version file
id: get-versions
run: |
content=`cat ${{ github.workspace }}/oneDNN/.github/automation/riscv/ci.json`
content="${content//[$'\t\r\n$ ']}"
echo "output=$content" >> $GITHUB_OUTPUT
- name: Get latest CMake and Ninja
uses: lukka/get-cmake@56d043d188c3612951d8755da8f4b709ec951ad6 # v3.31.6
with:
cmakeVersion: 3.31.0
ninjaVersion: 1.12.0
- name: Install cross-compilation tools
run: |
sudo apt-get update
sudo apt-get install -y gcc-${{ fromJson(steps.get-versions.outputs.output).dependencies.gcc }}-riscv64-linux-gnu g++-${{ fromJson(steps.get-versions.outputs.output).dependencies.gcc }}-riscv64-linux-gnu
- name: Setup ccache
uses: Chocobo1/setup-ccache-action@f433cb1e0b3ed576864d7fc361ce43b23b181e67 # v1.5.4
with:
remove_stale_cache: false
ccache_options: |
max_size=750M
- name: Configure oneDNN
run: ${{ github.workspace }}/oneDNN/.github/automation/riscv/build.sh
working-directory: ${{ github.workspace }}/oneDNN
env:
BUILD_TOOLSET: ${{ matrix.config.toolset }}
CMAKE_BUILD_TYPE: ${{ matrix.config.build }}
CMAKE_GENERATOR: Ninja
GCC_VERSION: ${{ fromJson(steps.get-versions.outputs.output).dependencies.gcc }}
ONEDNN_ACTION: configure
ONEDNN_CMAKE_EXTRA_FLAGS: -DCMAKE_C_COMPILER_LAUNCHER=ccache -DCMAKE_CXX_COMPILER_LAUNCHER=ccache
ONEDNN_TEST_SET: ${{ matrix.config.testset }}
ONEDNN_THREADING: ${{ matrix.config.threading }}
CCACHE_BASEDIR: ${{ github.workspace }}/oneDNN
- name: Build oneDNN
run: ${{ github.workspace }}/oneDNN/.github/automation/riscv/build.sh
working-directory: ${{ github.workspace }}/oneDNN
env:
BUILD_TOOLSET: ${{ matrix.config.toolset }}
GCC_VERSION: ${{ fromJson(steps.get-versions.outputs.output).dependencies.gcc }}
ONEDNN_ACTION: build
CCACHE_BASEDIR: ${{ github.workspace }}/oneDNN
- name: Create archive with preserved permissions
working-directory: ${{ github.workspace }}/oneDNN
run: tar -czf build.tar.gz build
- name: Upload build artifacts
uses: actions/upload-artifact@bbbca2ddaa5d8feaa63e36b76fdaad77386f024f # v7.0.0
with:
name: build-artifact
path: ${{ github.workspace }}/oneDNN/build.tar.gz
retention-days: 1
test:
needs: build
strategy:
fail-fast: true
matrix:
config: [
{ name: riscv-test-vlen128, threading: OMP, testset: SMOKE, vlen: 128, build: RelWithAssert },
{ name: riscv-test-vlen256, threading: OMP, testset: SMOKE, vlen: 256, build: RelWithAssert }
]
name: ${{ matrix.config.name }}, ${{ matrix.config.threading }}
runs-on: ubuntu-24.04
steps:
- name: Checkout oneDNN
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
persist-credentials: false
path: oneDNN
- name: Read version file
id: get-versions
run: |
content=`cat ${{ github.workspace }}/oneDNN/.github/automation/riscv/ci.json`
content="${content//[$'\t\r\n$ ']}"
echo "output=$content" >> $GITHUB_OUTPUT
- name: Set up QEMU
uses: docker/setup-qemu-action@ce360397dd3f832beb865e1373c09c0e9f86d70a # v4.0.0
with:
platforms: riscv64
- name: Install cross-compilation tools
run: |
sudo apt-get update
sudo apt-get install -y gcc-${{ fromJson(steps.get-versions.outputs.output).dependencies.gcc }}-riscv64-linux-gnu g++-${{ fromJson(steps.get-versions.outputs.output).dependencies.gcc }}-riscv64-linux-gnu
- name: Download build artifacts
uses: actions/download-artifact@70fc10c6e5e1ce46ad2ea6f2b72d43f7d47b13c3 # v8.0.0
with:
name: build-artifact
path: ${{ github.workspace }}/oneDNN/
- name: Extract archive
working-directory: ${{ github.workspace }}/oneDNN/
run: tar -xzf build.tar.gz
- name: Run oneDNN tests
run: ${{ github.workspace }}/oneDNN/.github/automation/riscv/test.sh
working-directory: ${{ github.workspace }}/oneDNN/build
env:
CTEST_PARALLEL_LEVEL: 4
ONEDNN_THREADING: ${{ matrix.config.threading }}
ONEDNN_TEST_SET: ${{ matrix.config.testset }}
QEMU_CPU: "rv64,v=true,vlen=${{ matrix.config.vlen }},vext_spec=v1.0"
status:
needs: [build, test]
runs-on: ubuntu-24.04
name: "CI RISC-V"
steps:
- name: Print success
run: echo Success