Conversation

The call stack in basically every programming environment is a virtual memory system with overcommit and allocation that never returns errors.
5
68
Replying to and
Linux kernel will also lazily map in the main thread stack even with overcommit disabled. Runtime has to do something about that during initialization if it wants to guarantee that a certain amount can be used later. An error can occur simply when you reach deepest stack usage.
2
-fstack-clash-protection just prevents you from jumping over a guard page/region. It doesn't map in the whole stack before you start using it. It doesn't prevent dying because of memory allocation failure with overcommit disabled when you call a function because mapping fails.
1
1
Show replies