-
Notifications
You must be signed in to change notification settings - Fork 2.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[NPUW] Add initial unpack and partitioning unit tests on NPUW (#25780)
This PR adds unit tests on 1) unpack routines within NPUW 2) main online partitioning functionality (smaller unit tests on `Graph`, `Group`, `Repeated`, etc will be added separately) Local run: ``` [----------] Global test environment tear-down [==========] 334 tests from 6 test suites ran. (3379 ms total) [ PASSED ] 334 tests. ```
- Loading branch information
1 parent
9284684
commit ad448dd
Showing
6 changed files
with
1,478 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -8,3 +8,4 @@ if (MSVC) | |
ov_add_compiler_flags(/wd5105) | ||
endif() | ||
add_subdirectory(functional) | ||
add_subdirectory(unit) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
# Copyright (C) 2024 Intel Corporation | ||
# SPDX-License-Identifier: Apache-2.0 | ||
# | ||
|
||
set(TARGET_NAME "ov_npu_unit_tests") | ||
|
||
set(MANDATORY_UNIT_TESTS_LIBS | ||
"openvino::commonTestUtils" | ||
"openvino::gmock" | ||
"openvino::gtest" | ||
"openvino::gtest_main" | ||
"openvino::runtime" | ||
"openvino::npu_al" | ||
"openvino::npu_logger_utils" | ||
) | ||
|
||
ov_add_test_target( | ||
NAME ${TARGET_NAME} | ||
ROOT ${CMAKE_CURRENT_SOURCE_DIR} | ||
ADDITIONAL_SOURCE_DIRS | ||
${OpenVINO_SOURCE_DIR}/src/plugins/intel_npu/src/plugin/npuw/ | ||
DEPENDENCIES | ||
openvino::runtime | ||
INCLUDES | ||
${CMAKE_CURRENT_SOURCE_DIR} | ||
${CMAKE_CURRENT_SOURCE_DIR}/npuw | ||
${OpenVINO_SOURCE_DIR}/src/plugins/intel_npu/src/plugin/npuw | ||
${OpenVINO_SOURCE_DIR}/src/plugins/intel_npu/src/utils/include | ||
${OpenVINO_SOURCE_DIR}/src/plugins/intel_npu/src/plugin/include | ||
${OpenVINO_SOURCE_DIR}/src/plugins/intel_npu/src/al/include | ||
LINK_LIBRARIES | ||
${MANDATORY_UNIT_TESTS_LIBS} | ||
LABELS | ||
NPUW | ||
) | ||
|
||
if(CMAKE_CXX_COMPILER_ID MATCHES "Clang" OR CMAKE_CXX_COMPILER_ID MATCHES "GNU") | ||
target_compile_options(${TARGET_NAME} PRIVATE -mavx2 -mf16c) | ||
elseif(CMAKE_CXX_COMPILER_ID MATCHES "MSVC") | ||
target_compile_options(${TARGET_NAME} PRIVATE /arch:AVX2) | ||
else() | ||
message(AUTHOR_WARNING "Unknown compiler, may miss the AVX2 baseline setting") | ||
endif() | ||
|
||
install(TARGETS ${TARGET_NAME} | ||
RUNTIME DESTINATION tests | ||
COMPONENT tests | ||
EXCLUDE_FROM_ALL | ||
) |
Oops, something went wrong.