This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Simple ifcvt patch
- To: egcs-patches at egcs dot cygnus dot com, rth at cygnus dot com
- Subject: Simple ifcvt patch
- From: Jan Hubicka <hubicka at atrey dot karlin dot mff dot cuni dot cz>
- Date: Tue, 2 May 2000 16:30:16 +0200
Hi
Is there something wrong about this change? :)
Honza
Tue May 2 16:28:57 MET DST 2000 Jan Hubicka <jh@suse.cz>
* ifcvt.c (noce_try_cmove_arith): Use may_trap_p to thest
whether address may trap.
Index: egcs/gcc/ifcvt.c
===================================================================
RCS file: /cvs/gcc/egcs/gcc/ifcvt.c,v
retrieving revision 1.7
diff -c -3 -p -r1.7 ifcvt.c
*** ifcvt.c 2000/05/02 06:35:22 1.7
--- ifcvt.c 2000/05/02 14:28:36
*************** noce_try_cmove_arith (if_info)
*** 842,851 ****
is_mem = 1;
}
! /* ??? We could handle this if we knew that a load from A or B could
! not fault. This is true of stack memories or if we've already loaded
! from the address along the path from ENTRY. */
! else if (GET_CODE (a) == MEM || GET_CODE (b) == MEM)
return FALSE;
/* if (test) x = a + b; else x = c - d;
--- 842,848 ----
is_mem = 1;
}
! else if (may_trap_p (a) || may_trap_p (b))
return FALSE;
/* if (test) x = a + b; else x = c - d;