[PATCH] D40622: XOR the frame pointer with the stack cookie when protecting the stack

Reid Kleckner via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Nov 30 14:37:15 PST 2017


rnk marked an inline comment as done.
rnk added a comment.

Thanks! I think this is the way to go for now. Having some kind of virtual frame register might be nice if we had a second use case for it, but I can't think of one now.



================
Comment at: llvm/lib/CodeGen/StackProtector.cpp:390
+  // impossible to emit the check in IR, so the target *must* support stack
+  // protection in SDAG, and it's fast isel 'ret' selector must implement or
+  // fall back in the presence of stack protection.
----------------
hans wrote:
> hans wrote:
> > s/it's/its/
> This one still applies (for the second it's)
Hm, actually that comment is wrong. The target's fast isel implementation doesn't have to do anything. I checked, and the protection check is inserted at a higher level after fast isel.


https://reviews.llvm.org/D40622





More information about the llvm-commits mailing list