Description
I am opening this issue to track work regarding improving Arm 32-bit EABI exception-handling. There are a few fixmes that were never addressed and some things that I found a bit unclear. These are currently mostly questions, and it is possible this issue may be resolved fully by merely answering the questions (and hopefully committing an answer somewhere).
- How bad is reusing r12, anyways?
- What's up with NetBSD?
Arm, GCC, exceptions, and r12
We find this comment in our source:
rust/library/std/src/sys/personality/gcc.rs
Lines 126 to 136 in 6106b05
It's unclear what benefits this has, to me, and if our codegen backend could even exploit them, theoretically, if we did this. Mere correctness? Perhaps mere correctness is worth it, it might just be a fairly simple def.
NetBSD
According to this lovingly detailed commit message, NetBSD on 32-bit Arm using the EABI does not use the Arm EABI exception handling routines.
However, perhaps because it was not seen as relevant, it was not documented what it does use as its approach for unwinding. This is unfortunate, as we have recently seen Arm bugs on NetBSD that appear to be caused by assuming NetBSD on Arm must operate exactly like it does on x86, and discovering we are wrong, because of bugs or other reasons.
@he32 Do all NetBSD architectures use the same unwinding? Do we even unwind correctly on the not-so-x86 NetBSD architectures? Apparently not if this is to be believed? #96914
Activity