Skip to content

main() uses lots of stack due to boot_out.txt handling #904

@jepler

Description

@jepler

I initially diagnosed #900 as being due to the stack above main being hundreds of bytes on Metro M4. However, on further investigation, it is actually the stack of main itself being over 600 bytes. This is primarily due to f486ead which added a 512-byte on stack buffer for checking whether the contents of the boot_out.txt file matched what was already written to flash.

I think this could be greatly improved if the code which allocates the char[512] array was moved out of line, similar to what is mentioned in the comment above filesystem_init().

See #903 and #900 for more background.

This calls into question whether #903 really will fix the rosie-ci problems I've heard mentioned.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions