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 rtl-optimization/23098] [3.4/4.0/4.1 Regression] store of 0.0 to float


------- Additional Comments From pinskia at gcc dot gnu dot org  2005-07-27 19:13 -------
Another testcase which is a regression (on x86) caused by the same problem:
int g (float* g1,float t)
{
  *g1 = 0.0 + t;
}

Without -fPIC,
        fldz
        movl    4(%esp), %eax
        fadds   8(%esp)
        fstps   (%eax)
        ret
With -fPIC:
g:
        call    __i686.get_pc_thunk.cx
        addl    $_GLOBAL_OFFSET_TABLE_, %ecx
        movl    4(%esp), %eax
        flds    .LC0@GOTOFF(%ecx)
        fadds   8(%esp)
        fstps   (%eax)
        ret

in 2.95.3, we get:
g:
        fldz
        fadds 8(%esp)
        movl 4(%esp),%eax
        fstps (%eax)
        ret

But from 3.0.4 and above we get the same issue as the mainline with -fPIC.

-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=23098


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