[RFC PATCH 0/3] arm64: Implement reliable stack trace

Madhavan T. Venkataraman madvenka at linux.microsoft.com
Sun Jan 31 22:20:07 EST 2021



On 1/29/21 3:39 PM, Madhavan T. Venkataraman wrote:
> - A separate register has to be reserved for holding the shadow stack
>   pointer. The compiler (gcc) has to be changed to not use this register for
>   other purposes. And we have to trust that there are no compiler bugs
>   in this area. All assembly code that currently uses this register for
>   anything needs to be reviewed and potentially changed. This includes
>   all inline assembly code. BTW, I believe clang uses x18 for the shadow
>   stack pointer register.

Actually, if the stack and the shadow stack are allocated so that they are
adjacent or at a fixed distance from each other, we don't need a separate
register. We can compute parallel stack addresses from stack addresses by
a simple calculation.

So, this is not an issue.

Madhavan



More information about the linux-arm-kernel mailing list