-
Notifications
You must be signed in to change notification settings - Fork 3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Yi Zhang
committed
Sep 11, 2024
1 parent
2936f7c
commit 1c0f420
Showing
2 changed files
with
69 additions
and
1 deletion.
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 |
---|---|---|
@@ -0,0 +1,66 @@ | ||
diff --git a/CMakeLists.txt b/CMakeLists.txt | ||
index 3e78307..91bd676 100644 | ||
--- a/CMakeLists.txt | ||
+++ b/CMakeLists.txt | ||
@@ -150,61 +150,6 @@ target_compile_options(kleidiai | ||
PRIVATE ${KLEIDIAI_WARNING_FLAGS} | ||
) | ||
|
||
-if(KLEIDIAI_BUILD_TESTS) | ||
- enable_testing() | ||
- include(GoogleTest) | ||
- | ||
- add_library(kleidiai_test_framework | ||
- test/common/data_type.cpp | ||
- test/common/data_format.cpp | ||
- test/common/printer.cpp | ||
- test/common/int4.cpp | ||
- test/common/compare.cpp | ||
- test/common/matrix_portion.cpp | ||
- test/common/rect.cpp | ||
- test/common/round.cpp | ||
- test/common/bfloat16.cpp | ||
- test/common/float16.cpp | ||
- test/common/cpu_info.cpp | ||
- test/common/sme.cpp | ||
- | ||
- test/reference/binary_elementwise.cpp | ||
- test/reference/matmul.cpp | ||
- test/reference/fill.cpp | ||
- test/reference/pack.cpp | ||
- test/reference/quantize.cpp | ||
- test/reference/reduce.cpp | ||
- test/reference/transpose.cpp | ||
- test/reference/cast.cpp | ||
- ) | ||
- | ||
- target_compile_options(kleidiai_test_framework | ||
- PUBLIC ${KLEIDIAI_WARNING_FLAGS} | ||
- PUBLIC -march=armv8.2-a+fp16+bf16 | ||
- ) | ||
- | ||
- set_source_files_properties(test/common/sme.cpp PROPERTIES COMPILE_OPTIONS -march=armv8.2-a+sve) | ||
- | ||
- target_link_libraries(kleidiai_test_framework | ||
- PUBLIC kleidiai | ||
- ) | ||
- | ||
- add_executable(kleidiai_test | ||
- test/tests/matmul_test.cpp | ||
- test/tests/matmul_clamp_f32_qai8dxp_qsi4cxp_test.cpp | ||
- test/tests/matmul_clamp_f32_qsi8d32p_qsi4c32p_test.cpp | ||
- ) | ||
- | ||
- target_link_libraries(kleidiai_test | ||
- PRIVATE kleidiai_test_framework | ||
- PRIVATE GTest::gtest_main | ||
- ) | ||
- | ||
- # Cross-compiling is a common use case which creates a conflict if DISCOVERY_MODE is set to POST_BUILD (by default) | ||
- # since the host platform does not match the target. Setting the mode to PRE_TEST avoids this conflict. | ||
- gtest_discover_tests(kleidiai_test DISCOVERY_MODE PRE_TEST) | ||
-endif() | ||
- | ||
if(KLEIDIAI_BUILD_BENCHMARK) | ||
# https://github.com/google/benchmark/issues/351 | ||
if(NOT (${CMAKE_SYSTEM_PROCESSOR} MATCHES "ARM")) |