@@ -94,29 +94,29 @@ if (CMAKE_HOST_SYSTEM_PROCESSOR MATCHES "(aarch64)|(arm64)|(ARM64)|(armv.*)")
9494 if (NOT ARMPL_LIB)
9595 message (STATUS "Could not find ARM Performance Libraries" )
9696 else ()
97+ add_compile_definitions (OPT_ARMPL)
9798 message (STATUS "Found ARM Performance Libraries: ${ARMPL_LIB} " )
98- endif ()
99-
100- # Create different optimization implementations for ARM architecture
101- # ArmPL used for standard ARMv8-A with NEON
102- if (CXX_ARMV8A)
103- message ("Building with ARMV8A and ArmPL" )
104- set_source_files_properties (functions/ARMPL_NEON.cpp PROPERTIES COMPILE_FLAGS "-march=armv8-a" )
105- list (APPEND OPTIMIZATIONS functions/ARMPL_NEON.cpp)
106- endif ()
107-
108- # ArmPL with SVE support
109- if (CXX_SVE)
110- message ("Building with SVE and ArmPL" )
111- set_source_files_properties (functions/ARMPL_SVE.cpp PROPERTIES COMPILE_FLAGS "-march=armv8-a+sve" )
112- list (APPEND OPTIMIZATIONS functions/ARMPL_SVE.cpp)
113- endif ()
114-
115- # ArmPL with SVE2 support
116- if (CXX_SVE2)
117- message ("Building with ARMV9 and ArmPL" )
118- set_source_files_properties (functions/ARMPL_SVE2.cpp PROPERTIES COMPILE_FLAGS "-march=armv9-a+sve2" )
119- list (APPEND OPTIMIZATIONS functions/ARMPL_SVE2.cpp)
99+ # Create different optimization implementations for ARM architecture
100+ # ArmPL used for standard ARMv8-A with NEON
101+ if (CXX_ARMV8A)
102+ message ("Building with ARMV8A and ArmPL" )
103+ set_source_files_properties (functions/ARMPL_NEON.cpp PROPERTIES COMPILE_FLAGS "-march=armv8-a" )
104+ list (APPEND OPTIMIZATIONS functions/ARMPL_NEON.cpp)
105+ endif ()
106+
107+ # ArmPL with SVE support
108+ if (CXX_SVE)
109+ message ("Building with SVE and ArmPL" )
110+ set_source_files_properties (functions/ARMPL_SVE.cpp PROPERTIES COMPILE_FLAGS "-march=armv8-a+sve" )
111+ list (APPEND OPTIMIZATIONS functions/ARMPL_SVE.cpp)
112+ endif ()
113+
114+ # ArmPL with SVE2 support
115+ if (CXX_SVE2)
116+ message ("Building with ARMV9 and ArmPL" )
117+ set_source_files_properties (functions/ARMPL_SVE2.cpp PROPERTIES COMPILE_FLAGS "-march=armv9-a+sve2" )
118+ list (APPEND OPTIMIZATIONS functions/ARMPL_SVE2.cpp)
119+ endif ()
120120 endif ()
121121endif ()
122122
0 commit comments