So, I just updated a project (FreeRTOS-based) from v8.4 to v9.5 (and also learned that v10 is a thing already
), and what surprised me the most was the increased Stack usage in our project.
With v8.x the allocated stack in a debug build was 4kB. This was enough with a good amount of slack when compiled for production. However, with v9.5, I had to increase the stack size to 8kB, with water making hovering around 7.6kB.
I know that a good amount of time has passed since the release of v9.x, but could anyone provide some insights on what is causing this major stack usage increase?
Is there any use case that from v8.x to v9. x that could result in extra stack usage? To be more specific, in the stack requirements for calling lv_timer_handler
Hi @Gildons,
I recommend you start checking:
- Objects/ widgets styles
- Make sure you are handling correctly with all animations
- And check if you have a memory leak when you create dynamic objects.
Each project needs special attention to detail, but itโs good practice to separate UI implementation and FW/Low Level to make sure everything is all right.
Obrigado sr!
You mentioned styles. Are there any changes to styles that you are aware of that would result in increased stack usage?
Well, a common problem is multiple initialization, this can be a problem.
But, itโs just a guess, I have no clue how you develop your project. Indeed, the v8.5 compared to v9.5 defines a change in feelings
I see your point, but multiple initialization, for example, without a matching uninit would affect the heap, not the stack, and here Iโm asking about the stack usage increase in the thread calling lv_timer_handler
Yeah, you are right about that. Could you share the lv_config.h file?