Skip to content
This repository was archived by the owner on Nov 27, 2025. It is now read-only.

Commit 8f1f3cd

Browse files
committed
Linux precommit
1 parent 8c06cc7 commit 8f1f3cd

File tree

1 file changed

+62
-0
lines changed

1 file changed

+62
-0
lines changed
Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
name: "Linux precommit"
2+
3+
permissions:
4+
contents: read
5+
6+
on:
7+
push:
8+
pull_request:
9+
workflow_dispatch:
10+
branches: [ "npu/release/18.x" ]
11+
12+
concurrency:
13+
group: ${{ github.workflow }}-${{ github.ref }}
14+
cancel-in-progress: ${{ startsWith(github.ref, 'refs/pull/') }}
15+
16+
17+
jobs:
18+
Build:
19+
name: Build
20+
runs-on: ubuntu-latest
21+
defaults:
22+
run:
23+
shell: bash
24+
env:
25+
CMAKE_BUILD_TYPE: 'Debug'
26+
NPU_PLUGIN_LLVM_PROJECT: llvm
27+
NPU_PLUGIN_LLVM_PROJECT_BUILD_DIR: llvm/build
28+
NPU_PLUGIN_LLVM_PROJECT_INSTALL_DIR: llvm/install
29+
steps:
30+
- name: Clone NPU Plugin LLVM sources
31+
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
32+
with:
33+
submodules: 'true'
34+
- name: Print system info
35+
if: runner.os == 'Linux'
36+
shell: bash
37+
run: |
38+
# Install pre-requisites for Fedora
39+
if [[ -e /etc/fedora-release ]]; then
40+
yum update -y -q && yum install -y -q procps
41+
fi
42+
43+
echo "System: ${{ runner.os }}"
44+
echo "System Architecture: ${{ runner.arch }}"
45+
echo "CPU Info: "; lscpu
46+
echo "RAM Info: "; free -h --si
47+
echo "MEMORY Info: "; df -h
48+
49+
- name: Configure CMake
50+
run: |
51+
ls .
52+
ls ${GITHUB_WORKSPACE}
53+
ls ${NPU_PLUGIN_LLVM_REPO}
54+
cmake \
55+
-B ${NPU_PLUGIN_LLVM_PROJECT_BUILD_DIR} \
56+
-S ${NPU_PLUGIN_LLVM_PROJECT} \
57+
-DLLVM_ENABLE_PROJECTS=mlir \
58+
-DCMAKE_INSTALL_PREFIX=${NPU_PLUGIN_LLVM_PROJECT_INSTALL_DIR} \
59+
-DCMAKE_BUILD_TYPE=${CMAKE_BUILD_TYPE}
60+
61+
- name: Build
62+
run: cmake --build ${NPU_PLUGIN_LLVM_PROJECT_BUILD_DIR} --config ${CMAKE_BUILD_TYPE}

0 commit comments

Comments
 (0)