summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAngus Gratton <angus@redyak.com.au>2025-08-27 16:51:02 +1000
committerDamien George <damien@micropython.org>2025-08-29 13:35:53 +1000
commit9a9cc794222e6791d3d615aee4e32a06c5aeb1be (patch)
tree8ec0fdb9c3890478a3b8b5d9591c96ab90a60ffe
parent5b98126c21f8eaa996e258761a291a7a88624082 (diff)
esp32/boards: Build ESP32-C2 and C3 with -Os instead of -O2.
Same optimisation that was applied to C6 in the parent commit, now applied to all RISC-V boards. +------------+------------+------------+------------+ | Size | Before | After | Delta | +------------+------------+------------+------------+ | C2 Binary | 1680384 | 1494224 | -186160 | | C2 D/IRAM | 83710 | 79080 | -4630 | | C3 Binary | 1833328 | 1636624 | -196704 | | C3 D/IRAM | 139608 | 131896 | -7712 | +------------+------------+------------+------------+ This work was funded through GitHub Sponsors. Signed-off-by: Angus Gratton <angus@redyak.com.au>
-rw-r--r--ports/esp32/boards/ESP32_GENERIC_C2/mpconfigboard.cmake1
-rw-r--r--ports/esp32/boards/ESP32_GENERIC_C3/mpconfigboard.cmake1
-rw-r--r--ports/esp32/boards/GARATRONIC_PYBSTICK26_ESP32C3/mpconfigboard.cmake1
-rw-r--r--ports/esp32/boards/LOLIN_C3_MINI/mpconfigboard.cmake1
4 files changed, 4 insertions, 0 deletions
diff --git a/ports/esp32/boards/ESP32_GENERIC_C2/mpconfigboard.cmake b/ports/esp32/boards/ESP32_GENERIC_C2/mpconfigboard.cmake
index 7a8b0e0b3..6a59e8a25 100644
--- a/ports/esp32/boards/ESP32_GENERIC_C2/mpconfigboard.cmake
+++ b/ports/esp32/boards/ESP32_GENERIC_C2/mpconfigboard.cmake
@@ -2,6 +2,7 @@ set(IDF_TARGET esp32c2)
set(SDKCONFIG_DEFAULTS
boards/sdkconfig.base
+ boards/sdkconfig.riscv
boards/sdkconfig.ble
boards/sdkconfig.c2
# C2 has unusably low free RAM without these optimisations
diff --git a/ports/esp32/boards/ESP32_GENERIC_C3/mpconfigboard.cmake b/ports/esp32/boards/ESP32_GENERIC_C3/mpconfigboard.cmake
index 429366afa..41b32b84c 100644
--- a/ports/esp32/boards/ESP32_GENERIC_C3/mpconfigboard.cmake
+++ b/ports/esp32/boards/ESP32_GENERIC_C3/mpconfigboard.cmake
@@ -2,6 +2,7 @@ set(IDF_TARGET esp32c3)
set(SDKCONFIG_DEFAULTS
boards/sdkconfig.base
+ boards/sdkconfig.riscv
boards/sdkconfig.ble
boards/ESP32_GENERIC_C3/sdkconfig.c3usb
)
diff --git a/ports/esp32/boards/GARATRONIC_PYBSTICK26_ESP32C3/mpconfigboard.cmake b/ports/esp32/boards/GARATRONIC_PYBSTICK26_ESP32C3/mpconfigboard.cmake
index 81cfff1d7..81d7f6b7c 100644
--- a/ports/esp32/boards/GARATRONIC_PYBSTICK26_ESP32C3/mpconfigboard.cmake
+++ b/ports/esp32/boards/GARATRONIC_PYBSTICK26_ESP32C3/mpconfigboard.cmake
@@ -2,6 +2,7 @@ set(IDF_TARGET esp32c3)
set(SDKCONFIG_DEFAULTS
boards/sdkconfig.base
+ boards/sdkconfig.riscv
boards/sdkconfig.ble
boards/GARATRONIC_PYBSTICK26_ESP32C3/sdkconfig.board
)
diff --git a/ports/esp32/boards/LOLIN_C3_MINI/mpconfigboard.cmake b/ports/esp32/boards/LOLIN_C3_MINI/mpconfigboard.cmake
index 0ce7f85e5..4ecc71956 100644
--- a/ports/esp32/boards/LOLIN_C3_MINI/mpconfigboard.cmake
+++ b/ports/esp32/boards/LOLIN_C3_MINI/mpconfigboard.cmake
@@ -2,6 +2,7 @@ set(IDF_TARGET esp32c3)
set(SDKCONFIG_DEFAULTS
boards/sdkconfig.base
+ boards/sdkconfig.riscv
boards/sdkconfig.ble
boards/LOLIN_C3_MINI/sdkconfig.board
)