[Bug target/103503] RFE: no save registers attribute
hpa at zytor dot com
Mon Jun 6 17:00:06 GMT 2022
--- Comment #4 from H. Peter Anvin <hpa at zytor dot com> ---
The interrupt attribute typically does two things:
1. It changes the return instruction;
2. It marks all registers as saved.
2 is exactly the *opposite* of what I want; I would like to improve performance
by the fact that the compiler-invisible entry flow has already saved all
registers, whether or not they are saved in the ABI. Thus, I would like it to
treat all (non-fixed) registers as *clobbered*, not *saved*.
Ideally, "nosaved" and "interrupt" should be possible to use together, to get
effect #1 of the interrupt attribute, but that is usually less important.
More information about the Gcc-bugs