aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRichard Sandiford <richard.sandiford@arm.com>2019-09-30 16:20:12 +0000
committerRichard Sandiford <rsandifo@gcc.gnu.org>2019-09-30 16:20:12 +0000
commit016996861c7333f42772c84a5a2a4e52e0bd07c5 (patch)
tree5bf8aef888cc343864b239c4422ff9982fb64299
parent7392e5d8888462610b5536c2894d2923b826faed (diff)
downloadgcc-016996861c7333f42772c84a5a2a4e52e0bd07c5.zip
gcc-016996861c7333f42772c84a5a2a4e52e0bd07c5.tar.gz
gcc-016996861c7333f42772c84a5a2a4e52e0bd07c5.tar.bz2
Remove global call sets: cfgcleanup.c
old_insns_match_p just tests whether two instructions are similar enough to merge. With insn_callee_abi it makes more sense to compare the ABIs directly. 2019-09-30 Richard Sandiford <richard.sandiford@arm.com> gcc/ * cfgcleanup.c (old_insns_match_p): Compare the ABIs of calls instead of the call-clobbered sets. From-SVN: r276314
-rw-r--r--gcc/ChangeLog5
-rw-r--r--gcc/cfgcleanup.c8
2 files changed, 6 insertions, 7 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index d912a87..a3e4ff2 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,5 +1,10 @@
2019-09-30 Richard Sandiford <richard.sandiford@arm.com>
+ * cfgcleanup.c (old_insns_match_p): Compare the ABIs of calls
+ instead of the call-clobbered sets.
+
+2019-09-30 Richard Sandiford <richard.sandiford@arm.com>
+
* caller-save.c (setup_save_areas): Remove redundant |s of
fixed_reg_set.
(save_call_clobbered_regs): Likewise. Use the call ABI rather
diff --git a/gcc/cfgcleanup.c b/gcc/cfgcleanup.c
index 329fa0c..ced7e0a 100644
--- a/gcc/cfgcleanup.c
+++ b/gcc/cfgcleanup.c
@@ -1227,13 +1227,7 @@ old_insns_match_p (int mode ATTRIBUTE_UNUSED, rtx_insn *i1, rtx_insn *i2)
}
}
- HARD_REG_SET i1_used = insn_callee_abi (i1).full_reg_clobbers ();
- HARD_REG_SET i2_used = insn_callee_abi (i2).full_reg_clobbers ();
- /* ??? This preserves traditional behavior; it might not be needed. */
- i1_used |= fixed_reg_set;
- i2_used |= fixed_reg_set;
-
- if (i1_used != i2_used)
+ if (insn_callee_abi (i1) != insn_callee_abi (i2))
return dir_none;
}