This is the mail archive of the gcc@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]

Re: dangerous cleverness? ppc int<->float conversions, subreg


> The right way to do what you want to do is to change register
> allocation when this flag is specified, so that it only allocates a FP
> register as a last resort.

But that would pessimize fp-heavy code.

You still have the problem that fpregs usage might seep out of inlined
functions and never-actually-executed basic block into other basic blocks.

You'd need not only to make sure that REGISTER_MOVE_COST is high when it
involves int<->fp reg moves (it already does for the sparc, because it needs
secondary memory), but also to jack up MEMORY_MOVE_COST so that
mem -> fpreg -> mem moves won't be generated.
And fix all the bugs and imperfect heuristics in the compiler that can cause
it to use fpregs even if the costs say it's not a good choice.

-- 
Joern Rennecke                  |            gcc expert for hire
amylaar@onetel.net.uk           |  send enquiries to: jwr_jobs@onetel.net.uk


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