Merge branch 'feature/newlib_iram_cleanup' into 'master'

feat(newlib): optimize IRAM usage

Closes IDF-7146

See merge request espressif/esp-idf!37647
This commit is contained in:
Marius Vikhammer
2025-03-14 10:28:45 +08:00
5 changed files with 43 additions and 28 deletions

View File

@@ -193,6 +193,7 @@ The following options will reduce IRAM usage of some ESP-IDF features:
- Refer to the sdkconfig menu ``Auto-detect Flash chips``, and you can disable flash drivers which you do not need to save some IRAM.
:SOC_GPSPI_SUPPORTED: - Enable :ref:`CONFIG_HEAP_PLACE_FUNCTION_INTO_FLASH`. Provided that :ref:`CONFIG_SPI_MASTER_ISR_IN_IRAM` is not enabled and the heap functions are not incorrectly used from ISRs, this option is safe to enable in all configurations.
:esp32c2: - Enable :ref:`CONFIG_BT_RELEASE_IRAM`. Release BT text section and merge BT data, bss & text into a large free heap region when ``esp_bt_mem_release`` is called. This makes Bluetooth unavailable until the next restart, but saving ~22 KB or more of IRAM.
- Disable :ref:`CONFIG_LIBC_LOCKS_PLACE_IN_IRAM` if no ISRs that run while cache is disable (i.e. IRAM ISRs) are using libc lock APIs.
.. only:: esp32