This was fun to track down
Jeffrey A Law
law@cygnus.com
Tue Sep 23 19:05:00 GMT 1997
In message < 199709232053.WAA03509@squid.pdc.kth.se >you write:
> 1. It seems strange that convert_modes put a constant into a register.
> Maybe that is a bug.
convert_modes has always put a constant into a reg if it couldn't
make find any other way to change the mode of the constant. This
is nothing new.
I believe this can happen when you need to truncate from one
mode to another, but such truncations are not "nops" -- ie they
need real instructions.
There's probably similar situations when extending a constant
from one mode to another.
I think it's safe to say that convert_modes is doing the correct
thing.
> 2. If convert_modes is really right, the proper fix to expand_divmod
> would be to avoid calling it when op1 is constant.
I don't think you can just avoid the call -- you can't just
operate on constants without any regard to their size. That's
one of the things that gets us in trouble so often with
64bit targets.
jeff
More information about the Gcc
mailing list