Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/thirdpin/libopencm3.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKarl Palsson <karlp@remake.is>2015-10-15 15:28:54 +0300
committerKarl Palsson <karlp@remake.is>2015-10-15 15:28:54 +0300
commitcaeeed2b0f3e231a8667deb57f0d75f5f63d0ec3 (patch)
treebd66ee013767c9500f23044198bc1d7f70460475
parent5ece67ad5dbe7ad9b5c378d41d77e2337caffe07 (diff)
stm32f7: FPU only single precision on f7 :(
Boo ST.
-rw-r--r--README.md5
-rw-r--r--lib/stm32/f7/Makefile4
2 files changed, 5 insertions, 4 deletions
diff --git a/README.md b/README.md
index 46a2120d..32a2ae6e 100644
--- a/README.md
+++ b/README.md
@@ -99,8 +99,9 @@ them as environment variables, for example:
behavior can be specified by setting `FP_FLAGS`.
Currently, M4F cores default to `-mfloat-abi=hard -mfpu=fpv4-sp-d16`,
- M7 core defaults to double precision `-mfloat-abi=hard -mfpu=fpv5-d16`
- and other architectures to no FP flags forcing to use software computation.
+ M7 cores defaults to double precision `-mfloat-abi=hard -mfpu=fpv5-d16` if available,
+ and single precision `-mfloat-abi=hard -mfpu=fpv5-sp-d16` otherwise.
+ Other architectures use no FP flags, in otherwords, traditional softfp.
You may find which FP_FLAGS you can use in particular architecture in readme.txt
shipped with gcc-arm-embedded package.
diff --git a/lib/stm32/f7/Makefile b/lib/stm32/f7/Makefile
index d7f314f7..a543d3e7 100644
--- a/lib/stm32/f7/Makefile
+++ b/lib/stm32/f7/Makefile
@@ -26,8 +26,8 @@ PREFIX ?= arm-none-eabi
CC = $(PREFIX)-gcc
AR = $(PREFIX)-ar
-# By default, use double precision FPU
-FP_FLAGS ?= -mfloat-abi=hard -mfpu=fpv5-d16
+# STM32F7 only supports single precision FPU
+FP_FLAGS ?= -mfloat-abi=hard -mfpu=fpv5-sp-d16
CFLAGS = -Os -g \
-Wall -Wextra -Wimplicit-function-declaration \