This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
r9 on ARM32?
- From: Jay K <jayk123 at hotmail dot com>
- To: gcc <gcc at gcc dot gnu dot org>
- Date: Tue, 24 Apr 2018 02:22:40 +0000
- Subject: r9 on ARM32?
I'm wondering what is the role of r9 on ARM32, on Linux and Android.
On Apple it is documented as long ago reserved, these days available for scratch.
I've looked around a bit but haven't gotten the full answer.
It is "the PIC register", I see.
What does that imply? Volatile? Von-volatile?
In particular I'm looking for a spare register, to pass an extra "special" parameter in, that can be considered volatile and never otherwise has a parameter.
Most ABIs have a few candidates, but arm32 comes up relatively short.
Intra procedural scratch (r12) probably cannot work for me.
I know gcc uses it for nested function context and that is laudable. I wish I could guarantee no code between me setting it and it being consumed.
And if it is volatile, I'd want the dynamic linker stubs to still preserve it incoming.
Thank you,
- Jay