Skip to content

Commit 41e8549

Browse files
rgommersclaude
andcommitted
Remove -march=knl flag for GCC 15 compatibility
GCC 15 dropped support for Xeon Phi (KNL) targets, making -march=knl invalid. For optimized KNL kernels, remove -march=knl since -mavx512f is already specified explicitly. For reference kernels, replace -march=knl with -march=skylake to provide an AVX2 baseline (AVX-512 is then disabled via -mno-avx512f -mno-avx512cd). Follows the same approach as PR 129 which removed -mavx512pf. Closes gh-150 Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent 4e318c4 commit 41e8549

4 files changed

Lines changed: 964 additions & 964 deletions

File tree

blis/_src/config/knl/make_defs.mk

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -75,13 +75,13 @@ endif
7575
# Flags specific to optimized kernels.
7676
CKOPTFLAGS := $(COPTFLAGS)
7777
ifeq ($(CC_VENDOR),gcc)
78-
CKVECFLAGS := -mavx512f -mfpmath=sse -march=knl
78+
CKVECFLAGS := -mavx512f -mfpmath=sse
7979
else
8080
ifeq ($(CC_VENDOR),icc)
8181
CKVECFLAGS := -xMIC-AVX512
8282
else
8383
ifeq ($(CC_VENDOR),clang)
84-
CKVECFLAGS := -mavx512f -mfpmath=sse -march=knl
84+
CKVECFLAGS := -mavx512f -mfpmath=sse
8585
else
8686
$(error gcc, icc, or clang is required for this configuration.)
8787
endif
@@ -91,21 +91,21 @@ endif
9191
# The assembler on OS X won't recognize AVX512 without help.
9292
ifneq ($(CC_VENDOR),icc)
9393
ifeq ($(OS_NAME),Darwin)
94-
CKVECFLAGS += -Wa,-march=knl
94+
CKVECFLAGS += -Wa,-march=skylake-avx512
9595
endif
9696
endif
9797

9898
# Flags specific to reference kernels.
9999
# Note: We use AVX2 for reference kernels instead of AVX-512.
100100
CROPTFLAGS := $(CKOPTFLAGS)
101101
ifeq ($(CC_VENDOR),gcc)
102-
CRVECFLAGS := -march=knl -mno-avx512f -mno-avx512cd -funsafe-math-optimizations -ffp-contract=fast
102+
CRVECFLAGS := -march=skylake -mno-avx512f -mno-avx512cd -funsafe-math-optimizations -ffp-contract=fast
103103
else
104104
ifeq ($(CC_VENDOR),icc)
105105
CRVECFLAGS := -xMIC-AVX512
106106
else
107107
ifeq ($(CC_VENDOR),clang)
108-
CRVECFLAGS := -march=knl -mno-avx512f -mno-avx512cd -funsafe-math-optimizations -ffp-contract=fast
108+
CRVECFLAGS := -march=skylake -mno-avx512f -mno-avx512cd -funsafe-math-optimizations -ffp-contract=fast
109109
else
110110
$(error gcc, icc, or clang is required for this configuration.)
111111
endif

0 commit comments

Comments
 (0)