Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Free memory budget is wrong #128

Open
ljahn opened this issue Nov 11, 2023 · 1 comment
Open

Free memory budget is wrong #128

ljahn opened this issue Nov 11, 2023 · 1 comment
Labels
bug Something isn't working

Comments

@ljahn
Copy link
Contributor

ljahn commented Nov 11, 2023

The memory budget displayed when pressing p is wrong.
It overestimates the free space left by a substantial amount (I think around 15000).
I am pretty sure this comes from not considering FreeRTOS tasks getting their stack allocated on the heap on creation, now that the heaps were unified.

@JF002
Copy link
Contributor

JF002 commented Nov 11, 2023

This is probably a side effect of the new heap memory management we introduce a few months ago.

Previously, the memory usage displayed in InfiniSim showed the status of the LVGL heap memory. With this new memory management, all 3 memory heaps of InfiniTime (FreeRTOS, LVGL and Nimble) are merged into a single one managed by FreeRTOS.
In InfiniTime, we ensured that all runtime memory allocations are done in this single heap.

In InfiniSim, this is much more complicated since it does a lot of memory allocations that do not happen in InfiniTime (SDL, for example). So that it's not that easy to catch memory allocations that are done by InfiniTime and filter out the ones that are done by InfiniSim.

So... yeah, the memory usage in InfiniSim might be wrong, and I do not know yet how we'll fix it :/

@NeroBurner NeroBurner added the bug Something isn't working label Nov 14, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants