This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
Re: Reg-stack and cmove bug
- To: Zack Weinberg <zackw at Stanford dot EDU>
- Subject: Re: Reg-stack and cmove bug
- From: Jan Hubicka <jh at suse dot cz>
- Date: Fri, 16 Feb 2001 12:50:26 +0100
- Cc: Tim Prince <tprince at computer dot org>, tprinceusa at mindspring dot com, gcc-bugs at gcc dot gnu dot org, jh at suse dot cz
- References: <Springmail.105.982281121.0.18922500@www.springmail.com> <20010215161557.J814@wolery.stanford.edu> <015201c097df$a90d82b0$b50cd63f@amr.corp.intel.com> <20010216010413.C9664@wolery.stanford.edu>
> Notice how the 'ge' in the first insn has mysteriously become an 'le'
> after reg-stack. It is NOT trying to reverse the sense of the
> comparison here; it has got confused while trying to reorder operands
> to fit the 387 register stack. fcmov can only move to top-of-stack.
No what really he is trying is to avoid extra fxch on comparison.
There is loop searching for CC user and trying to swap the operands.
This gets messed up, since there are actually two CC users.
One way is to verify presense of REG_DEAD note, better is probably to
try swap all users.
I will prepare patch later today.
Honza