zephyr/cmake
Daniel Leung ff720cd9b3 x86: enable soft float support for Zephyr SDK
This adds the correct compiler and linker flags to
support software floating point operations. The flags
need to be added to TOOLCHAIN_*_FLAGS for GCC to find
the correct library (when calling GCC with
--print-libgcc-file-name).

Note that software floating point needs to be turned
on for Newlib. This is due to Newlib having floating
point numbers in its various printf() functions which
results in floating point instructions being emitted
from toolchain. These instructions are placed very
early in the functions which results in them being
executed even though the format string contains
no floating point conversions. Without using CONFIG_FPU
to enable hardware floating point support, any calls to
printf() like functions will result in exceptions
complaining FPU is not available. Although forcing
CONFIG_FPU=y with newlib is an option, and because
the OS doesn't know which threads would call these
printf() functions, Zephyr has to assume all threads
are using FPU and thus incurring performance penalty as
every context switching now needs to save FPU registers.
A compromise here is to use soft float instead. Newlib
with soft float enabled does not have floating point
instructions and yet can still support its printf()
like functions.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2021-01-20 16:45:31 -05:00
..
app modules: introducing MODULE_EXT_ROOT to allow glue code in Zephyr repo 2021-01-18 18:02:46 +01:00
bintools bintools: append ; to > to ensure a space 2020-11-26 14:20:03 +01:00
compiler x86: enable soft float support for Zephyr SDK 2021-01-20 16:45:31 -05:00
emu cmake: Fix unexpected token after & 2021-01-18 19:08:45 +01:00
flash
ide
linker cmake: scripts: supporting gen_relocate_app feature in windows 2021-01-20 11:51:47 +01:00
makefile_exports cmake: using zephyr_get_compile_options_for_lang_as_string for export 2020-12-15 08:37:54 -05:00
reports
toolchain xtensa: set toolchain variant per SoC 2020-12-20 14:30:50 -05:00
usage boards/shields: re-work handling in cmake and west 2021-01-15 15:07:49 -05:00
util
boards.cmake boards/shields: re-work handling in cmake and west 2021-01-15 15:07:49 -05:00
ccache.cmake
cfb.cmake
dts.cmake devicetree: generate extern's for devicetree struct devices 2021-01-15 07:16:21 -06:00
extensions.cmake cmake: zephyr modules: sanitize all module name when used as variable 2021-01-20 12:59:19 +01:00
extra_flags.cmake
gcc-m-cpu.cmake arch: arm: Add Cortex-R7 support 2021-01-13 15:04:43 +01:00
generic_toolchain.cmake cmake: Ignore LDFLAGS and AFLAGS from environment 2020-09-10 15:35:50 -05:00
git.cmake
hex.cmake
host-tools.cmake
kconfig.cmake cmake: zephyr modules: sanitize all module name when used as variable 2021-01-20 12:59:19 +01:00
kobj.cmake
mcuboot.cmake
pristine.cmake
python.cmake
shields.cmake boards/shields: re-work handling in cmake and west 2021-01-15 15:07:49 -05:00
target_toolchain.cmake cmake: use the toolchain path, id and version as extended signature. 2020-12-14 11:56:00 -05:00
target_toolchain_flags.cmake cmake: use the toolchain path, id and version as extended signature. 2020-12-14 11:56:00 -05:00
version.cmake
west.cmake
zephyr_module.cmake cmake: zephyr modules: sanitize all module name when used as variable 2021-01-20 12:59:19 +01:00