diff options
author | Jakub Jelinek <jakub@redhat.com> | 2009-04-24 08:58:02 +0200 |
---|---|---|
committer | Jakub Jelinek <jakub@gcc.gnu.org> | 2009-04-24 08:58:02 +0200 |
commit | 6216f94e37db8de5a846c5945f4aa5f4e32aaedf (patch) | |
tree | b915c002276568ad8d30cd5e3340544d674fc103 /gcc/gcse.c | |
parent | 6de7a512f0e76268d8ff69e51be80527c58d854b (diff) | |
download | gcc-6216f94e37db8de5a846c5945f4aa5f4e32aaedf.zip gcc-6216f94e37db8de5a846c5945f4aa5f4e32aaedf.tar.gz gcc-6216f94e37db8de5a846c5945f4aa5f4e32aaedf.tar.bz2 |
re PR rtl-optimization/39794 (Miscompile with -O2 -funroll-loops)
PR rtl-optimization/39794
* alias.c (canon_true_dependence): Add x_addr argument.
* rtl.h (canon_true_dependence): Adjust prototype.
* cse.c (check_dependence): Adjust canon_true_dependence callers.
* cselib.c (cselib_invalidate_mem): Likewise.
* gcse.c (compute_transp): Likewise.
* dse.c (scan_reads_nospill): Likewise.
(record_store, check_mem_read_rtx): Likewise. For non-const-or-frame
addresses pass base->val_rtx as mem_addr, for const-or-frame addresses
canon_base_addr of the group, plus optional offset.
(struct group_info): Rename canon_base_mem to
canon_base_addr.
(get_group_info): Set canon_base_addr to canon_rtx of base, not
canon_rtx of base_mem.
* gcc.dg/pr39794.c: New test.
From-SVN: r146669
Diffstat (limited to 'gcc/gcse.c')
-rw-r--r-- | gcc/gcse.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -1,7 +1,7 @@ /* Global common subexpression elimination/Partial redundancy elimination and global constant/copy propagation for GNU compiler. Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, - 2006, 2007, 2008 Free Software Foundation, Inc. + 2006, 2007, 2008, 2009 Free Software Foundation, Inc. This file is part of GCC. @@ -2512,7 +2512,7 @@ compute_transp (const_rtx x, int indx, sbitmap *bmap, int set_p) dest_addr = XEXP (list_entry, 0); if (canon_true_dependence (dest, GET_MODE (dest), dest_addr, - x, rtx_addr_varies_p)) + x, NULL_RTX, rtx_addr_varies_p)) { if (set_p) SET_BIT (bmap[bb_index], indx); |