mirror of
git://gcc.gnu.org/git/gcc.git
synced 2025-04-16 23:31:05 +08:00
re PR middle-end/91708 ([ARM] Bootstrap fails in gen_movsi, at config/arm/arm.md:5258)
2019-09-13 Bernd Edlinger <bernd.edlinger@hotmail.de> PR middle-end/91708 * cse.c (cse_insn): Do not replace anything with a MEM. From-SVN: r275701
This commit is contained in:
parent
57cccc860e
commit
2374137476
@ -1,3 +1,9 @@
|
||||
2019-09-13 Bernd Edlinger <bernd.edlinger@hotmail.de>
|
||||
|
||||
PR middle-end/91708
|
||||
* cse.c (cse_insn): Do not replace anything with a
|
||||
MEM.
|
||||
|
||||
2019-09-13 Ian Lance Taylor <iant@golang.org>
|
||||
|
||||
* doc/invoke.texi (Optimize Options): Fix typo.
|
||||
|
23
gcc/cse.c
23
gcc/cse.c
@ -5238,23 +5238,6 @@ cse_insn (rtx_insn *insn)
|
||||
src_elt_cost = MAX_COST;
|
||||
}
|
||||
|
||||
/* Avoid creation of overlapping memory moves. */
|
||||
if (MEM_P (trial) && MEM_P (dest) && !rtx_equal_p (trial, dest))
|
||||
{
|
||||
rtx src, dest;
|
||||
|
||||
/* BLKmode moves are not handled by cse anyway. */
|
||||
if (GET_MODE (trial) == BLKmode)
|
||||
break;
|
||||
|
||||
src = canon_rtx (trial);
|
||||
dest = canon_rtx (SET_DEST (sets[i].rtl));
|
||||
|
||||
if (!MEM_P (src) || !MEM_P (dest)
|
||||
|| !nonoverlapping_memrefs_p (src, dest, false))
|
||||
break;
|
||||
}
|
||||
|
||||
/* Try to optimize
|
||||
(set (reg:M N) (const_int A))
|
||||
(set (reg:M2 O) (const_int B))
|
||||
@ -5385,6 +5368,12 @@ cse_insn (rtx_insn *insn)
|
||||
/* Do nothing for this case. */
|
||||
;
|
||||
|
||||
/* Do not replace anything with a MEM, except the replacement
|
||||
is a no-op. This allows this loop to terminate. */
|
||||
else if (MEM_P (trial) && !rtx_equal_p (trial, SET_SRC(sets[i].rtl)))
|
||||
/* Do nothing for this case. */
|
||||
;
|
||||
|
||||
/* Look for a substitution that makes a valid insn. */
|
||||
else if (validate_unshare_change (insn, &SET_SRC (sets[i].rtl),
|
||||
trial, 0))
|
||||
|
Loading…
x
Reference in New Issue
Block a user