This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug target/67260] [sh] Register spill bug for sibcall+complex+softfloat


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67260

--- Comment #11 from Oleg Endo <olegendo at gcc dot gnu.org> ---
(In reply to Alexander Monakov from comment #10)
> If always using r0 is not an issue, I think it's possible to just use
> operands[0] (casting it to the right size with subreg:SI, if needed) to
> avoid using a potentially-reserved hardreg.  This would allow to remove the
> clobber from the pattern altogether.

I'm not sure it's a good idea.  All the call patterns are written with "=rf"
for operand[0], i.e. it could be a floating point register.  Under the current
ABI all function calls always clobber GP regs r0..r3 though.  To avoid more
potential r0-spill-failure cases, I'd rather put the explicit r1 clobber.

> (I also imagine that sh.md could benefit from a rework of call patterns, I
> don't understand why it's done this way with postreload splits)

Do you have anything in particular in mind?  I guess some of the things are
tied to the way constant/literal pools work on SH.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]