This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: i386 setcc pattern tweek
On Wed, Oct 17, 2001 at 08:11:48PM +0200, Jan Hubicka wrote:
> * i386.c (ix86_expand_setcc): Always expect target to be QImode.
You didn't get all of it. In particular
/* Three modes of generation:
0 -- destination does not overlap compare sources:
clear dest first, emit strict_low_part setcc.
1 -- destination does overlap compare sources:
emit subreg setcc, zero extend.
2 -- destination is in QImode:
emit setcc only.
We don't use mode 0 early in compilation because it confuses CSE.
There are peepholes to turn mode 1 into mode 0 if things work out
nicely after reload. */
type = cse_not_expected ? 0 : 1;
if (GET_MODE (dest) == QImode)
type = 2;
else if (reg_overlap_mentioned_p (dest, ix86_compare_op0)
|| reg_overlap_mentioned_p (dest, ix86_compare_op1))
type = 1;
if (type == 0)
emit_move_insn (dest, const0_rtx);
but otherwise ok.
r~