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

Bump host-sp-comms stacksize #1775

Merged
merged 1 commit into from May 7, 2024
Merged

Bump host-sp-comms stacksize #1775

merged 1 commit into from May 7, 2024

Conversation

mkeeter
Copy link
Collaborator

@mkeeter mkeeter commented May 7, 2024

The compiler bump in #1703 left us with a mere 24 bytes of stackmargin on host-sp-comms (down from about 1 KiB). This manifests as sporadic stack overflows, basically if we hit an interrupt at exactly the wrong time.

Cores are collected in /staff/dogfood/cores-collected-20240507. All of the per-task cores show the same issue:

matt@cadbury /staff/dogfood/cores-collected-20240507 () $ for f in $(find . -name "hubris.core.host_sp_comms*"); do printf "\n$f\n"; h --dump $f tasks; done

./BRM42220009/hubris.core.host_sp_comms.0
humility: attached to dump
system time = 87005911
ID TASK                       GEN PRI STATE
16 host_sp_comms                0   7 FAULT: stack overflow; sp=0x2401fff0 (was: ready)

./BRM42220017/hubris.core.host_sp_comms.0
humility: attached to dump
system time = 86463960
ID TASK                       GEN PRI STATE
16 host_sp_comms                0   7 FAULT: stack overflow; sp=0x2401ffd8 (was: ready)

./BRM44220011/hubris.core.host_sp_comms.0
humility: attached to dump
system time = 35477746
ID TASK                       GEN PRI STATE
16 host_sp_comms                0   7 FAULT: stack overflow; sp=0x2401fff0 (was: ready)

./BRM23230018-rev-d/hubris.core.host_sp_comms.1
humility: attached to dump
system time = 86618702
ID TASK                       GEN PRI STATE
16 host_sp_comms                1   7 FAULT: stack overflow; sp=0x2401fff0 (was: ready)

./BRM23230018-rev-d/hubris.core.host_sp_comms.0
humility: attached to dump
system time = 41216464
ID TASK                       GEN PRI STATE
16 host_sp_comms                0   7 FAULT: stack overflow; sp=0x2401fff0 (was: ready)

./BRM44220010/hubris.core.host_sp_comms.1
humility: attached to dump
system time = 1550511
ID TASK                       GEN PRI STATE
16 host_sp_comms                1   7 FAULT: stack overflow; sp=0x2401ffe0 (was: ready)

./BRM44220010/hubris.core.host_sp_comms.0
humility: attached to dump
system time = 1550401
ID TASK                       GEN PRI STATE
16 host_sp_comms                0   7 FAULT: stack overflow; sp=0x2401ffd0 (was: ready)

./BRM42220057/hubris.core.host_sp_comms.0
humility: attached to dump
system time = 1584024
ID TASK                       GEN PRI STATE
16 host_sp_comms                0   7 FAULT: stack overflow; sp=0x2401fff0 (was: ready)

This PR bumps us back to a healthy 1 KiB of stack margin. Figuring out why rustc decided to sabotage our stacks is left as an exercise for the reader.

@labbott labbott merged commit a4fa6f7 into master May 7, 2024
104 checks passed
@labbott labbott deleted the bump-host-sp-comms-stack branch May 7, 2024 16:30
@morlandi7 morlandi7 added this to the 8 milestone May 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants