Repository navigation
LCD-7: a 64 KB data cache as well - #20
Merged
Merged
Conversation
On top of #17's 64-byte lines and 32 KB instruction cache. Measured with the board decoding and streaming audio while the LVGL UI runs: full redraw 205 -> 147 ms, panel switch 88 -> 59 ms, 30 list rows built 780 -> 399 ms and laid out 608 -> 335 ms. The same layout is ~216x faster on a desktop: the board is memory-bound and the data cache is the lever. Internal RAM free goes 54 -> 23 KB; a 30-minute soak of real use (about 25 track skips and picks, Wi-Fi streaming, the USB host running) kept a minimum of 17 KB with no allocation failures, Wi-Fi drops or audio stalls. The fragment's header no longer names the applications it was measured with; it describes them.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Follow-up to #17. Adds
CONFIG_ESP32S3_DATA_CACHE_64KB=yto the Waveshare ESP32-S3-Touch-LCD-7'ssdkconfig.lcd7.#17 left this out because it cuts internal RAM to ~13 KB free. It has now been soaked under real load. Measured while the board both runs an LVGL remote-control UI and decodes and streams audio to a USB sound card on its native port:
The same LVGL layout runs about 216× faster on a desktop, so this board is memory-bound (LVGL's objects live in PSRAM), and the data cache is the main lever left.
Soak: 30 minutes of real use: about 25 track skips and picks, Wi-Fi streaming, the USB host running. The minimum internal RAM free was 17 KB. There were no allocation failures, no Wi-Fi drops and no audio stalls. The earlier out-of-memory failure (24 bytes of DMA RAM free) came from every malloc under 8 KB going to internal RAM; the fragment's
SPIRAM_MALLOC_ALWAYSINTERNAL=512already fixes that.The fragment's header comment also stops naming the specific applications it was measured with; it describes them instead.