Skip to content

Fix stack prefaulting

Bjarne von Horn requested to merge fix_prefaulting into master

If compiling with optimizations enabled, the memset() in stack_prefault() is optimized away (dead write). Using the asm trick, we force the compiler not no optimize the dead store away.

Try it out on godbolt: https://godbolt.org/z/3naGnrh6h

Merge request reports