From c7be4f66b05aeb98962fda3dcf84cb895262a639 Mon Sep 17 00:00:00 2001 From: Richard Kenner Date: Wed, 17 Jan 2001 18:27:37 +0000 Subject: [PATCH] combine.c (try_combine): Don't set i3_subst_into_i2 for case of making new double-word constant. * combine.c (try_combine): Don't set i3_subst_into_i2 for case of making new double-word constant. Revert last change: instead just test i3_subst_into_i2. From-SVN: r39094 --- gcc/ChangeLog | 6 ++++++ gcc/combine.c | 8 +++++--- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 37baa52a7eb..3206f2ca6c5 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +Wed Jan 17 13:26:34 2001 Richard Kenner + + * combine.c (try_combine): Don't set i3_subst_into_i2 for + case of making new double-word constant. + Revert last change: instead just test i3_subst_into_i2. + 2001-01-17 Jakub Jelinek * config/i386/i386.md (cmpqi_minus_1): Use {b} for QImode operation. diff --git a/gcc/combine.c b/gcc/combine.c index e684ba15654..6028f6ae8d1 100644 --- a/gcc/combine.c +++ b/gcc/combine.c @@ -1558,13 +1558,16 @@ try_combine (i3, i2, i1, new_direct_jump_p) added_links_insn = 0; /* First check for one important special-case that the code below will - not handle. Namely, the case where I1 is zero, I2 has multiple sets, + not handle. Namely, the case where I1 is zero, I2 is a PARALLEL and I3 is a SET whose SET_SRC is a SET_DEST in I2. In that case, we may be able to replace that destination with the destination of I3. This occurs in the common code where we compute both a quotient and remainder into a structure, in which case we want to do the computation directly into the structure to avoid register-register copies. + Note that this case handles both multiple sets in I2 and also + cases where I2 has a number of CLOBBER or PARALLELs. + We make very conservative checks below and only try to handle the most common cases of this. For example, we only handle the case where I2 and I3 are adjacent to avoid making difficult register @@ -1673,7 +1676,6 @@ try_combine (i3, i2, i1, new_direct_jump_p) immed_double_const (lo, hi, GET_MODE (SET_DEST (temp)))); newpat = PATTERN (i2); - i3_subst_into_i2 = 1; goto validate_replacement; } @@ -2524,7 +2526,7 @@ try_combine (i3, i2, i1, new_direct_jump_p) actually came from I3, so that REG_UNUSED notes from I2 will be properly handled. */ - if (i3_subst_into_i2 && single_set (i2) == 0) + if (i3_subst_into_i2) { for (i = 0; i < XVECLEN (PATTERN (i2), 0); i++) if (GET_CODE (XVECEXP (PATTERN (i2), 0, i)) != USE -- 2.30.2