This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: non-local goto optimization
> Therefore, the conservatively correct change is very likely to test
>
> current_function_has_nonlocal_label || current_function_saves_all_registers
>
> in your back-end. However, your back-end could further benefit from Nathan's
> work by substituting the latter flag for the former in the test(s).
In the S/390 back end we are using the
current_function_has_nonlocal_label flag when calculating a
regs_ever_clobbered array which is then used to save only the
registers which a really clobbered - not just read. Regarding
builtin_unwind_init and non-local gotos we just copied what reload did
for regs_ever_live and since the reload check changed to
current_function_saves_all_registers it should be the right thing to
do in the S/390 back end as well.
I'll post a patch.
Bye,
-Andreas-