From 0029b66df185691a9b7cec6c1587af771cd2e1d7 Mon Sep 17 00:00:00 2001 From: Yi Zhang Date: Wed, 11 Sep 2024 15:49:58 +0800 Subject: [PATCH] add avx512sx always --- .../xnnpack/AddEmscriptenAndIosSupport.patch | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/cmake/patches/xnnpack/AddEmscriptenAndIosSupport.patch b/cmake/patches/xnnpack/AddEmscriptenAndIosSupport.patch index 3abf2d3afec42..cb08eb82f4c1b 100644 --- a/cmake/patches/xnnpack/AddEmscriptenAndIosSupport.patch +++ b/cmake/patches/xnnpack/AddEmscriptenAndIosSupport.patch @@ -1,5 +1,5 @@ diff --git a/CMakeLists.txt b/CMakeLists.txt -index 1ff85b538..c3ef2183f 100644 +index 1ff85b538..02ed85879 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -253,7 +253,7 @@ ENDIF() @@ -11,7 +11,15 @@ index 1ff85b538..c3ef2183f 100644 MESSAGE(FATAL_ERROR "Unrecognized CMAKE_SYSTEM_NAME value \"${CMAKE_SYSTEM_NAME}\"") ENDIF() IF(CMAKE_SYSTEM_NAME MATCHES "Windows") -@@ -763,7 +763,12 @@ IF(XNNPACK_BUILD_LIBRARY) +@@ -489,6 +489,7 @@ SET(TABLE_SRCS + src/tables/vlog.c) + + SET(PROD_MICROKERNEL_SRCS ${PROD_SCALAR_MICROKERNEL_SRCS}) ++LIST(APPEND PROD_MICROKERNEL_SRCS ${PROD_AVX512SKX_MICROKERNEL_SRCS}) + SET(NON_PROD_MICROKERNEL_SRCS ${NON_PROD_SCALAR_MICROKERNEL_SRCS}) + IF(XNNPACK_TARGET_PROCESSOR STREQUAL "arm") + LIST(APPEND PROD_MICROKERNEL_SRCS ${PROD_ARMSIMD32_MICROKERNEL_SRCS}) +@@ -763,7 +764,12 @@ IF(XNNPACK_BUILD_LIBRARY) TARGET_LINK_LIBRARIES(operator-run PRIVATE xnnpack-base logging) TARGET_LINK_LIBRARIES(operator-utils PRIVATE xnnpack-base logging) TARGET_LINK_LIBRARIES(subgraph PRIVATE xnnpack-base allocator logging memory mutex operators operator-run) @@ -25,7 +33,7 @@ index 1ff85b538..c3ef2183f 100644 TARGET_LINK_LIBRARIES(XNNPACK PUBLIC xnnpack-base) SET_TARGET_PROPERTIES(XNNPACK PROPERTIES C_EXTENSIONS YES) ENDIF() -@@ -772,7 +777,8 @@ IF(NOT MSVC) +@@ -772,7 +778,8 @@ IF(NOT MSVC) ENDIF() IF(XNNPACK_TARGET_PROCESSOR STREQUAL "arm") SET_PROPERTY(SOURCE ${ALL_MICROKERNEL_SRCS} APPEND_STRING PROPERTY COMPILE_FLAGS " -marm ")