aboutsummaryrefslogtreecommitdiff
path: root/elf/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'elf/Makefile')
-rw-r--r--elf/Makefile16
1 files changed, 10 insertions, 6 deletions
diff --git a/elf/Makefile b/elf/Makefile
index 0f37804..36ea9b8 100644
--- a/elf/Makefile
+++ b/elf/Makefile
@@ -1181,10 +1181,14 @@ $(objpfx)tst-initorder.out: $(objpfx)tst-initorder
cmp $@ tst-initorder.exp > /dev/null
ifeq (yes,$(config-cflags-avx))
-CFLAGS-tst-audit4.c += -mavx
-CFLAGS-tst-auditmod4a.c += -mavx
-CFLAGS-tst-auditmod4b.c += -mavx
-CFLAGS-tst-auditmod6b.c += -mavx
-CFLAGS-tst-auditmod6c.c += -mavx
-CFLAGS-tst-auditmod7b.c += -mavx
+AVX-CFLAGS=-mavx
+ifeq (yes,$(config-cflags-novzeroupper))
+AVX-CFLAGS+=-mno-vzeroupper
+endif
+CFLAGS-tst-audit4.c += $(AVX-CFLAGS)
+CFLAGS-tst-auditmod4a.c += $(AVX-CFLAGS)
+CFLAGS-tst-auditmod4b.c += $(AVX-CFLAGS)
+CFLAGS-tst-auditmod6b.c += $(AVX-CFLAGS)
+CFLAGS-tst-auditmod6c.c += $(AVX-CFLAGS)
+CFLAGS-tst-auditmod7b.c += $(AVX-CFLAGS)
endif