[PATCH] D96004: [AArch64] Stack probing for function prologues
Tamar Christina via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Mar 31 01:43:37 PDT 2021
tnfchris added a comment.
> For GCC this is guard-page - 1k. The reasoning is that with any outgoing argument larger than 1k we would probe such that we maintain the invariant, but probing that 1k means we have a whole guard-size -1k left that we can use without probing. These sizes were chose as they cover about 99% of all programs (for a subset of all :)).
As an addendum, as I mentioned above, wrt the outgoing argument not being larger than 1k. That's the buffer we guarantee. We're able to do so because during a function call the storing of `LR` counts as an implicit probe. So in order for this scheme to be secure you'd need to check that LLVM (like GCC) always stores `LR`, even for `no-return` leaf functions.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D96004/new/
https://reviews.llvm.org/D96004
More information about the llvm-commits
mailing list