From 77f9d57de4989f5012b1651df6512c4828144d93 Mon Sep 17 00:00:00 2001 From: Waldemar Brodkorb Date: Tue, 16 Feb 2016 22:15:39 +0100 Subject: rework ARM NEON support Don't build C library with -ffast-math when NEON is globally enabled. Disable NEON support by default. Remove dangerous -funsafe-math-optimizations. Most suggestions from Rich Felker after analyzing libc-test failures in my setup. --- toolchain/musl/Makefile | 2 ++ toolchain/uclibc-ng/Makefile | 6 ++++-- 2 files changed, 6 insertions(+), 2 deletions(-) (limited to 'toolchain') diff --git a/toolchain/musl/Makefile b/toolchain/musl/Makefile index 8390b13a7..0c628806a 100644 --- a/toolchain/musl/Makefile +++ b/toolchain/musl/Makefile @@ -12,6 +12,8 @@ endif # not yet possible TARGET_CFLAGS:= $(filter-out -fstack-protector-all,$(TARGET_CFLAGS)) TARGET_LDFLAGS:= $(filter-out -fstack-protector-all,$(TARGET_LDFLAGS)) +# don't use fast-math for C library +TARGET_CFLAGS:= $(filter-out -ffast-math,$(TARGET_CFLAGS)) $(WRKBUILD)/.configured: (cd $(WRKBUILD); CC='$(TARGET_CC)' CROSS_COMPILE='$(TARGET_CROSS)' \ diff --git a/toolchain/uclibc-ng/Makefile b/toolchain/uclibc-ng/Makefile index 5882dd7e2..981843c82 100644 --- a/toolchain/uclibc-ng/Makefile +++ b/toolchain/uclibc-ng/Makefile @@ -9,10 +9,12 @@ include Makefile.inc include ${ADK_TOPDIR}/mk/buildhlp.mk # disable LTO -TARGET_CFLAGS:=$(filter-out -flto,$(TARGET_CFLAGS)) +TARGET_CFLAGS:= $(filter-out -flto,$(TARGET_CFLAGS)) # handled by uClibc-ng makefiles -TARGET_CFLAGS:=$(filter-out -fstack-protector-all,$(TARGET_CFLAGS)) +TARGET_CFLAGS:= $(filter-out -fstack-protector-all,$(TARGET_CFLAGS)) TARGET_LDFLAGS:=$(filter-out -fstack-protector-all,$(TARGET_LDFLAGS)) +# don't use fast-math for C library +TARGET_CFLAGS:= $(filter-out -ffast-math,$(TARGET_CFLAGS)) ifeq ($(ADK_TARGET_HARD_FLOAT),y) ifeq ($(ADK_TARGET_ARCH_ARM),y) -- cgit v1.2.3