Krishna Myneni <[EMAIL PROTECTED]> wrote:
Under "gcc (GCC) 4.1.0 (SUSE Linux)", with CFLAGS = -m32 -S, and under all of the optimization levels (O0 through O3), the following is produced : flds .LC2 fldz fxch %st(1) fucompp fnstsw %ax :
The FXCH instruction is unnecessary if the FLDS and FLDZ instructions were ordered in reverse. Why does this type of optimization not take place?
This is actually PR target/15492. And the optimization doesn't take place for the simple fact, that nobody implemented the optimization yet. I have a prototype patch that catches these simple opportunities. Uros.