https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86340
Michal Schulz <michal.schulz at gmx dot de> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |michal.schulz at gmx dot de --- Comment #5 from Michal Schulz <michal.schulz at gmx dot de> --- Created attachment 44766 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=44766&action=edit File with correctly used "register" keyword The bug can be closed. The AROS macros were using "register" keyword in wrong way. Putting register keyword at that place of the code was fully legit but did not guarantee register reservation. The fact that in case of -O0 or -O1 optimizations the expected behavior was pure coincidence. Section pointing to correct and incorrect use of "register" keyword: https://gcc.gnu.org/onlinedocs/gcc/Local-Register-Variables.html#Local-Register-Variables AROS macros will be adjusted accordingly to attached file. The variables "extracted" from predefined registers will still be marked with the register keyword, but additionally, an empty extended asm forcing the output operands will be put into code, as shown in the file.