From 10ddf7be0b7b5bb537eb0743227f66451a10b2c4 Mon Sep 17 00:00:00 2001 From: Davide Bettio Date: Fri, 1 Mar 2024 00:42:49 +0100 Subject: [PATCH] ESP32: use single precision floats for performance reasons Documentation says: "Avoid using double precision floating point arithmetic double. These calculations are emulated in software and are very slow. If possible then use an integer-based representation, or single-precision floating point." Signed-off-by: Davide Bettio --- src/platforms/esp32/CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/platforms/esp32/CMakeLists.txt b/src/platforms/esp32/CMakeLists.txt index eeb0ab6255..91c9261b94 100644 --- a/src/platforms/esp32/CMakeLists.txt +++ b/src/platforms/esp32/CMakeLists.txt @@ -53,7 +53,7 @@ endif() # Options that make sense for this platform option(AVM_DISABLE_SMP "Disable SMP." OFF) -option(AVM_USE_32BIT_FLOAT "Use 32 bit floats." OFF) +option(AVM_USE_32BIT_FLOAT "Use 32 bit floats." ON) option(AVM_VERBOSE_ABORT "Print module and line number on VM abort" OFF) option(AVM_CREATE_STACKTRACES "Create stacktraces" ON)