Tom de Vries <tom_devr...@mentor.com> writes:
> This patch adds scanning of clobbers in CALL_INSN_FUNCTION_USAGE to 
> find_all_hard_reg_sets.
>
> For MIPS, calls are split at some point. After the split, one of the
> resulting insns may clobber $6. But before the split, that's not
> explicit in the rtl representation of the unsplit call.
>
> For -fuse-caller-save, that's a problem, and Richard S. suggested to
> add the clobber of $6 to the CALL_INSN_FUNCTION_USAGE of the unsplit
> call.

Maybe here's a good place to raise this, but I was hoping all targets
could use CALL_INSN_FUNCTION_USAGE and we'd be able to drop the new
hook for -fuse-caller-save.  That seems better than adding another
place that needs to be checked when figuring out what a call clobbers.

In other words, I didn't want MIPS to be different from the other targets.
If we decide to keep the hook then MIPS should use it too.

Thanks,
Richard

Reply via email to