This is the mail archive of the gcc-patches@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: regclass fix 2


On Thu, Feb 15, 2001 at 11:27:19AM +0100, Jan Hubicka wrote:
>     double b,c;
>     asm("%0 %1":"=f,r"(c):"f,r"(b));
>     asm("%0"::"r"(c));
> 
> Now both c and b gets GENERAL_REGISTERS.

No they don't.  C gets GENERAL, but B still gets FLOAT_INT.

>     asm("%0 %1":"=f,r"(c):"f,r"(b));
>     asm("%0"::"f,r"(c));
>
> Both gets FLOAT_INT_REGS.

Yep, but if you look at the costs listing, it's impossible to tell why:

  [ Trimmed to the relevant bits ]
  Register 42 costs: GENERAL_REGS:0 FLOAT_INT_REGS:10 MEM:2
  Register 43 costs: GENERAL_REGS:0 FLOAT_INT_REGS:22 MEM:6

It sure looks like we've gone and chosen the most expensive version.
Can you explain what is happening here?

> Looking forward to wipe out those # if this gets accepted!

A noble goal.


r~


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