Currently tasks in PROS are limited to 64k words, or 256kb of stack space. Most applications do not appear to reach this limit, but the folks working on vex-rt have ran into issues due to rust's memory management. Currently, the limit appears to be due to the fact that the stack depth is a uint16_t:
After talking with the folks porting Rust to PROS, they found that their issues were not due to the limited stack size. I am leaving this PR open as it could be a useful addition in the future though.
Problem:
Currently tasks in PROS are limited to 64k words, or 256kb of stack space. Most applications do not appear to reach this limit, but the folks working on vex-rt have ran into issues due to rust's memory management. Currently, the limit appears to be due to the fact that the stack depth is a uint16_t:
Proposed Solution:
Change the FreeRTOS function to take a uint32_t for the stack depth, and add extra code to perform checks for things like:
Additionally, other things need to be considered such as: