aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorJakub Jelinek <jakub@redhat.com>2013-06-03 19:38:39 +0200
committerJakub Jelinek <jakub@gcc.gnu.org>2013-06-03 19:38:39 +0200
commit1baf9159af13f8e4f404427831b383b54dcd8f40 (patch)
treefe88a886782d4d6ff5fb8743251beea8eb0c7ef4 /gcc
parent0f1d3965bdd6e7e050763603121662a1251071f2 (diff)
downloadgcc-1baf9159af13f8e4f404427831b383b54dcd8f40.zip
gcc-1baf9159af13f8e4f404427831b383b54dcd8f40.tar.gz
gcc-1baf9159af13f8e4f404427831b383b54dcd8f40.tar.bz2
re PR rtl-optimization/57268 (c nested loops hang compiler in sched-deps.c)
PR rtl-optimization/57268 * sched-deps.c (sched_analyze_2): Don't flush_pedning_lists if DEBUG_INSN_P (insn). Reapply 2013-05-31 Dinar Temirbulatov <dinar@kugelworks.com> PR rtl-optimization/57268 * sched-deps.c (sched_analyze_2): Flush dependence lists if the sum of the read and write lists exceeds MAX_PENDING_LIST_LENGTH. From-SVN: r199615
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ChangeLog13
-rw-r--r--gcc/sched-deps.c11
2 files changed, 22 insertions, 2 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index d39bddc..a638f79 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,16 @@
+2013-06-03 Jakub Jelinek <jakub@redhat.com>
+
+ PR rtl-optimization/57268
+ * sched-deps.c (sched_analyze_2): Don't flush_pedning_lists
+ if DEBUG_INSN_P (insn).
+
+ Reapply
+ 2013-05-31 Dinar Temirbulatov <dinar@kugelworks.com>
+
+ PR rtl-optimization/57268
+ * sched-deps.c (sched_analyze_2): Flush dependence lists if
+ the sum of the read and write lists exceeds MAX_PENDING_LIST_LENGTH.
+
2013-06-03 Yuri Rumyantsev <yuri.s.rumyantsev@intel.com>
* config/i386/i386.c (ix86_lea_outperforms): Fix formatting.
diff --git a/gcc/sched-deps.c b/gcc/sched-deps.c
index c7ef1d8..8270d58 100644
--- a/gcc/sched-deps.c
+++ b/gcc/sched-deps.c
@@ -2690,8 +2690,15 @@ sched_analyze_2 (struct deps_desc *deps, rtx x, rtx insn)
/* Always add these dependencies to pending_reads, since
this insn may be followed by a write. */
- if (!deps->readonly)
- add_insn_mem_dependence (deps, true, insn, x);
+ if (!deps->readonly)
+ {
+ if ((deps->pending_read_list_length
+ + deps->pending_write_list_length)
+ > MAX_PENDING_LIST_LENGTH
+ && !DEBUG_INSN_P (insn))
+ flush_pending_lists (deps, insn, true, true);
+ add_insn_mem_dependence (deps, true, insn, x);
+ }
sched_analyze_2 (deps, XEXP (x, 0), insn);