Skip to content

Commit

Permalink
Test failures
Browse files Browse the repository at this point in the history
  • Loading branch information
Maxim-Doronin committed Nov 14, 2024
1 parent c64890a commit 7dbd063
Show file tree
Hide file tree
Showing 4 changed files with 104 additions and 8 deletions.
96 changes: 96 additions & 0 deletions .github/workflows/windows-precommit.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,96 @@
name: "Windows precommit"

permissions:
contents: read

on:
push:
branches: [ "npu/release/18.x" ]
pull_request:
branches: [ "npu/release/18.x" ]
workflow_dispatch:
branches: [ "npu/release/18.x" ]

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: ${{ startsWith(github.ref, 'refs/pull/') }}


jobs:
Build:
name: Build and Test
runs-on: windows-latest
defaults:
run:
shell: bash
env:
CMAKE_BUILD_TYPE: 'Release'
LLVM_ENABLE_ASSERTIONS: 'ON'
NPU_PLUGIN_LLVM_PROJECT: llvm
NPU_PLUGIN_LLVM_PROJECT_BUILD_DIR: llvm/build
NPU_PLUGIN_LLVM_PROJECT_INSTALL_DIR: llvm/install
steps:
- name: Clone NPU Plugin LLVM sources
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
submodules: 'true'

- name: Install build dependencies
run: |
Invoke-WebRequest https://github.com/ninja-build/ninja/releases/download/v1.11.1/ninja-win.zip -OutFile ninja-win.zip -MaximumRetryCount 10
Expand-Archive -Force ninja-win.zip
Add-Content -Path $env:GITHUB_PATH -Value "${{ github.workspace }}/ninja-win"
- name: Configure Developer Command Prompt for Microsoft Visual C++ (2019)
uses: ilammy/msvc-dev-cmd@0b201ec74fa43914dc39ae48a89fd1d8cb592756 # v1.13.0
with:
toolset: 14.29

- name: Configure CMake
run: |
cmake \
-G "Ninja Multi-Config" \
-B ${NPU_PLUGIN_LLVM_PROJECT_BUILD_DIR} \
-S ${NPU_PLUGIN_LLVM_PROJECT} \
-DCMAKE_INSTALL_PREFIX=${NPU_PLUGIN_LLVM_PROJECT_INSTALL_DIR} \
-DCMAKE_BUILD_TYPE=${CMAKE_BUILD_TYPE} \
-DLLVM_ENABLE_WARNINGS=OFF \
-DLLVM_ENABLE_BINDINGS=OFF \
-DLLVM_ENABLE_RTTI=ON \
-DLLVM_ENABLE_EH=ON \
-DLLVM_ENABLE_BACKTRACES=OFF \
-DLLVM_ENABLE_CRASH_OVERRIDES=OFF \
-DLLVM_ENABLE_PROJECTS="mlir" \
-DLLVM_ENABLE_ASSERTIONS=${LLVM_ENABLE_ASSERTIONS} \
-DLLVM_INCLUDE_TESTS=ON \
-DLLVM_INCLUDE_BENCHMARKS=OFF \
-DLLVM_TARGETS_TO_BUILD="host" \
-DLLVM_ENABLE_TERMINFO=OFF \
-DLLVM_BUILD_EXAMPLES=OFF \
-DLLVM_INCLUDE_EXAMPLES=OFF \
-DLLVM_BUILD_TOOLS=OFF \
-DLLVM_BUILD_UTILS=ON \
-DLLVM_INSTALL_UTILS=ON \
- name: Build
run: |
cmake \
--build ${NPU_PLUGIN_LLVM_PROJECT_BUILD_DIR} \
--config ${CMAKE_BUILD_TYPE} \
--parallel $(nproc)
- name: Test LLVM
run: |
cmake \
--build ${NPU_PLUGIN_LLVM_PROJECT_BUILD_DIR} \
--config ${CMAKE_BUILD_TYPE} \
--parallel $(nproc) \
--target check-llvm
- name: Test MLIR
run: |
cmake \
--build ${NPU_PLUGIN_LLVM_PROJECT_BUILD_DIR} \
--config ${CMAKE_BUILD_TYPE} \
--parallel $(nproc) \
--target check-mlir
4 changes: 2 additions & 2 deletions mlir/test/Dialect/Quant/parse-any-invalid.mlir
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,12 @@

// -----
// Unrecognized storage type: illegal prefix
// expected-error@+1 {{illegal quantized storage type alias}}
// expected-error@+1 {{Blah}}
!qalias = !quant.any<int8<-4:3>:f32>

// -----
// Unrecognized storage type: no width
// expected-error@+1 {{illegal quantized storage type alias}}
// expected-error@+1 {{Blah}}
!qalias = !quant.any<i<-4:3>:f32>

// -----
Expand Down
6 changes: 3 additions & 3 deletions mlir/test/Dialect/Quant/parse-quantile-invalid.mlir
Original file line number Diff line number Diff line change
Expand Up @@ -63,12 +63,12 @@ func.func @parse() -> !qalias {

// -----
// Unrecognized storage type: illegal prefix
// expected-error@+1 {{illegal quantized storage type alias}}
// expected-error@+1 {{Hello world}}
!qalias = !quant.quantile<int8<-4:3>:f16:f32, {-1.0,1.0}:0.99872:127>

// -----
// Unrecognized storage type: no width
// expected-error@+1 {{illegal quantized storage type alias}}
// expected-error@+1 {{Hello world}}
!qalias = !quant.quantile<i<-4:3>:f16:f32, {-1.0,1.0}:0.99872:127>

// -----
Expand All @@ -78,7 +78,7 @@ func.func @parse() -> !qalias {

// -----
// Unrecognized storage type: storage size < 0
// expected-error@+1 {{illegal quantized storage type alias}}
// expected-error@+1 {{Hello world}}
!qalias = !quant.quantile<i-1<-4:3>:f16:f32, {-1.0,1.0}:0.99872:127>

// -----
Expand Down
6 changes: 3 additions & 3 deletions mlir/test/Dialect/Quant/parse-uniform-invalid.mlir
Original file line number Diff line number Diff line change
Expand Up @@ -37,12 +37,12 @@

// -----
// Unrecognized storage type: illegal prefix
// expected-error@+1 {{illegal quantized storage type alias}}
// expected-error@+1 {{Fus}}
!qalias = !quant.uniform<int8<-4:3>:f32, 0.99872:127>

// -----
// Unrecognized storage type: no width
// expected-error@+1 {{illegal quantized storage type alias}}
// expected-error@+1 {{Ro}}
!qalias = !quant.uniform<i<-4:3>:f32, 0.99872:127>

// -----
Expand All @@ -52,7 +52,7 @@

// -----
// Unrecognized storage type: storage size < 0
// expected-error@+1 {{illegal quantized storage type alias}}
// expected-error@+1 {{Dah}}
!qalias = !quant.uniform<i-1<-4:3>:f32, 0.99872:127>

// -----
Expand Down

0 comments on commit 7dbd063

Please sign in to comment.