Commit 4aab32d
authored
Document the behaviour of RUST_MIN_STACK=0
While digging through the code I noticed it went out of its way to distinguish RUST_MIN_STACK=0 from the sentinel value of 0, with no justification given.
Then I did some searching and discovered at least one person knew that it made Rust use the platform default stack size to work under valgrind better. [0]
This took me deeper into the guts of the platform-specific thread code where indeed i saw comments and/or explicit checks about 0 being a special sentinel to discard the 2MiB default in favour of "whatever the platform thread API wants to pick".
These docs are already heavily caveated with "this is platform-specific" so I see no harm in specifying this further-platform-specific behaviour.
[0]: https://nest.pijul.com/pijul/pijul/discussions/4981 parent 0f1e965 commit 4aab32d
1 file changed
+10
-3
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
125 | 125 | | |
126 | 126 | | |
127 | 127 | | |
128 | | - | |
| 128 | + | |
| 129 | + | |
129 | 130 | | |
130 | | - | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
131 | 134 | | |
132 | 135 | | |
133 | 136 | | |
| |||
495 | 498 | | |
496 | 499 | | |
497 | 500 | | |
498 | | - | |
| 501 | + | |
| 502 | + | |
| 503 | + | |
| 504 | + | |
| 505 | + | |
499 | 506 | | |
500 | 507 | | |
501 | 508 | | |
| |||
0 commit comments