summaryrefslogtreecommitdiff
path: root/gcc/haifa-sched.c
diff options
context:
space:
mode:
authorrth <rth@138bc75d-0d04-0410-961f-82ee72b054a4>2000-11-22 19:22:58 +0000
committerrth <rth@138bc75d-0d04-0410-961f-82ee72b054a4>2000-11-22 19:22:58 +0000
commit1370a57b8b28dfaa3a85e477bf8e56f0abe685c4 (patch)
tree2e8de6d245b0c67e4c2cf64e912c841cc8338a4b /gcc/haifa-sched.c
parentdead3293929c5215fea523d0d83a188df8ba717a (diff)
downloadgcc-1370a57b8b28dfaa3a85e477bf8e56f0abe685c4.tar.gz
* haifa-sched.c (sched_analyze_1): Don't special-case calls
for clobbering registers. (sched_analyze_2): Likewise. (sched_analyze): Zap reg_last_uses and reg_last_sets after calls. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@37668 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/haifa-sched.c')
-rw-r--r--gcc/haifa-sched.c14
1 files changed, 3 insertions, 11 deletions
diff --git a/gcc/haifa-sched.c b/gcc/haifa-sched.c
index 01f08b5d811..cf8fe2b15b7 100644
--- a/gcc/haifa-sched.c
+++ b/gcc/haifa-sched.c
@@ -3384,11 +3384,6 @@ sched_analyze_1 (deps, x, insn)
}
else
SET_REGNO_REG_SET (reg_pending_clobbers, r);
-
- /* Function calls clobber all call_used regs. */
- if (global_regs[r] || (code == SET && call_used_regs[r]))
- for (u = deps->last_function_call; u; u = XEXP (u, 1))
- add_dependence (insn, XEXP (u, 0), REG_DEP_ANTI);
}
}
else
@@ -3540,11 +3535,6 @@ sched_analyze_2 (deps, x, insn)
/* ??? This should never happen. */
for (u = deps->reg_last_clobbers[r]; u; u = XEXP (u, 1))
add_dependence (insn, XEXP (u, 0), 0);
-
- if (call_used_regs[r] || global_regs[r])
- /* Function calls clobber all call_used regs. */
- for (u = deps->last_function_call; u; u = XEXP (u, 1))
- add_dependence (insn, XEXP (u, 0), REG_DEP_ANTI);
}
}
else
@@ -3987,9 +3977,11 @@ sched_analyze (deps, head, tail)
{
for (u = deps->reg_last_uses[i]; u; u = XEXP (u, 1))
add_dependence (insn, XEXP (u, 0), REG_DEP_ANTI);
+ free_INSN_LIST_list (&deps->reg_last_uses[i]);
for (u = deps->reg_last_sets[i]; u; u = XEXP (u, 1))
- add_dependence (insn, XEXP (u, 0), REG_DEP_ANTI);
+ add_dependence (insn, XEXP (u, 0), REG_DEP_OUTPUT);
+ free_INSN_LIST_list (&deps->reg_last_sets[i]);
SET_REGNO_REG_SET (reg_pending_clobbers, i);
}