[Bug target/17381] Unnecessary register move for float extend
pinskia at gcc dot gnu dot org
gcc-bugzilla@gcc.gnu.org
Sun Dec 18 02:10:00 GMT 2005
------- Comment #2 from pinskia at gcc dot gnu dot org 2005-12-18 02:10 -------
It is even worse with:
double d;
float test1(float fParm)
{
d = fParm + 1.0;
return fParm + 1.0f;
}
We get two extra fmr's and one extra load:
_test1:
fmr f12,f1 <---- extra fmr
lis r2,ha16(LC1)
fmr f0,f1 <---- extra fmr
lfs f13,lo16(LC1)(r2) <--- load of 1.0f
lfs f1,lo16(LC1)(r2) <--- load of 1.0f, extra load
lis r2,ha16(_d)
fadd f0,f0,f13
fadds f1,f12,f1
stfd f0,lo16(_d)(r2)
blr
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17381
More information about the Gcc-bugs
mailing list