Skip to content

Commit 552e1c7

Browse files
committed
Correct compiler flags for NEOVERSEV1 target
1 parent 46b9b7a commit 552e1c7

File tree

3 files changed

+7
-7
lines changed

3 files changed

+7
-7
lines changed

cmake/cc.cmake

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -211,14 +211,14 @@ endif ()
211211
if (${CORE} STREQUAL NEOVERSEV1)
212212
if (NOT DYNAMIC_ARCH)
213213
if (${CMAKE_C_COMPILER_ID} STREQUAL "PGI" AND NOT NO_SVE)
214-
set (CCOMMON_OPT "${CCOMMON_OPT} -Msve_intrinsics -march=armv8.4-a+sve -mtune=neoverse-v1")
214+
set (CCOMMON_OPT "${CCOMMON_OPT} -Msve_intrinsics -march=armv8.4-a+sve+bf16 -mtune=neoverse-v1")
215215
elseif (${CMAKE_C_COMPILER_ID} STREQUAL "NVC" AND NOT NO_SVE)
216216
set (CCOMMON_OPT "${CCOMMON_OPT} -tp=neoverse-v1")
217217
else ()
218218
if (${GCC_VERSION} VERSION_GREATER 10.4 OR ${GCC_VERSION} VERSION_EQUAL 10.4)
219-
set (CCOMMON_OPT "${CCOMMON_OPT} -march=armv8.4-a+sve -mtune=neoverse-v1")
219+
set (CCOMMON_OPT "${CCOMMON_OPT} -march=armv8.4-a+sve+bf16 -mtune=neoverse-v1")
220220
else ()
221-
set (CCOMMON_OPT "${CCOMMON_OPT} -march=armv8.2-a+sve")
221+
set (CCOMMON_OPT "${CCOMMON_OPT} -march=armv8.2-a+sve+bf16")
222222
endif()
223223
endif()
224224
endif ()

cmake/system.cmake

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -291,10 +291,10 @@ if (DEFINED TARGET)
291291

292292
if (${TARGET} STREQUAL NEOVERSEV1)
293293
if (${CMAKE_C_COMPILER_ID} STREQUAL "PGI" AND NOT NO_SVE)
294-
set (KERNEL_DEFINITIONS "${KERNEL_DEFINITIONS} -Msve_intrinsics -march=armv8.4-a+sve -mtune=neoverse-v1")
294+
set (KERNEL_DEFINITIONS "${KERNEL_DEFINITIONS} -Msve_intrinsics -march=armv8.4-a+sve+bf16 -mtune=neoverse-v1")
295295
else ()
296296
if (CMAKE_C_COMPILER_VERSION VERSION_GREATER 10.4 OR CMAKE_C_COMPILER_VERSION VERSION_EQUAL 10.4)
297-
set (KERNEL_DEFINITIONS "${KERNEL_DEFINITIONS} -march=armv8.4-a+sve -mtune=neoverse-v1")
297+
set (KERNEL_DEFINITIONS "${KERNEL_DEFINITIONS} -march=armv8.4-a+sve+bf16 -mtune=neoverse-v1")
298298
else ()
299299
message(FATAL_ERROR "Compiler ${CMAKE_C_COMPILER} ${CMAKE_C_COMPILER_VERSION} does not support Neoverse V1.")
300300
endif()

getarch.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*****************************************************************************
2-
Copyright (c) 2011-2014, The OpenBLAS Project
2+
Copyright (c) 2011-2014, 2025 The OpenBLAS Project
33
All rights reserved.
44
55
Redistribution and use in source and binary forms, with or without
@@ -1476,7 +1476,7 @@ USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
14761476
"-DL2_SIZE=1048576 -DL2_LINESIZE=64 -DL2_ASSOCIATIVE=16 " \
14771477
"-DDTB_DEFAULT_ENTRIES=64 -DDTB_SIZE=4096 " \
14781478
"-DHAVE_VFPV4 -DHAVE_VFPV3 -DHAVE_VFP -DHAVE_NEON -DHAVE_SVE -DARMV8 " \
1479-
"-march=armv8.4-a+sve -mtune=neoverse-v1"
1479+
"-march=armv8.4-a+sve+bf16 -mtune=neoverse-v1"
14801480
#define LIBNAME "neoversev1"
14811481
#define CORENAME "NEOVERSEV1"
14821482
#endif

0 commit comments

Comments
 (0)