summaryrefslogtreecommitdiff
path: root/gcc/store-motion.c
diff options
context:
space:
mode:
authorrsandifo <rsandifo@138bc75d-0d04-0410-961f-82ee72b054a4>2012-04-21 18:55:18 +0000
committerrsandifo <rsandifo@138bc75d-0d04-0410-961f-82ee72b054a4>2012-04-21 18:55:18 +0000
commit86e87ef6099fefa07d967a33b48ba2aefd18ab97 (patch)
treeb0d6f2ebda9f50cb79a963c6fdd93ec04cda0025 /gcc/store-motion.c
parent87e440281cb26fcad5bc61a9e3794d34d6e76dc1 (diff)
downloadgcc-86e87ef6099fefa07d967a33b48ba2aefd18ab97.tar.gz
gcc/
PR bootstrap/53021 * rtl.def (ADDRESS): Use "i" rather than "w". * rtl.h (find_base_term): Delete. (may_be_sp_based_p): Declare. * rtl.c (rtx_code_size): Remove ADDRESS special case. * alias.h (UNIQUE_BASE_VALUE_SP, UNIQUE_BASE_VALUE_ARGP) (UNIQUE_BASE_VALUE_FP, UNIQUE_BASE_VALUE_HFP): Move to... * alias.c: ...here. (find_base_term): Make static. (may_be_sp_based_p): New function. * dse.c (record_store): Use it. * store-motion.c (store_killed_in_insn): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@186657 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/store-motion.c')
-rw-r--r--gcc/store-motion.c12
1 files changed, 3 insertions, 9 deletions
diff --git a/gcc/store-motion.c b/gcc/store-motion.c
index 03b2c3d4c84..e00cb16d16f 100644
--- a/gcc/store-motion.c
+++ b/gcc/store-motion.c
@@ -395,7 +395,7 @@ store_killed_in_pat (const_rtx x, const_rtx pat, int after)
static bool
store_killed_in_insn (const_rtx x, const_rtx x_regs, const_rtx insn, int after)
{
- const_rtx reg, base, note, pat;
+ const_rtx reg, note, pat;
if (! NONDEBUG_INSN_P (insn))
return false;
@@ -410,14 +410,8 @@ store_killed_in_insn (const_rtx x, const_rtx x_regs, const_rtx insn, int after)
/* But even a const call reads its parameters. Check whether the
base of some of registers used in mem is stack pointer. */
for (reg = x_regs; reg; reg = XEXP (reg, 1))
- {
- base = find_base_term (XEXP (reg, 0));
- if (!base
- || (GET_CODE (base) == ADDRESS
- && GET_MODE (base) == Pmode
- && XEXP (base, 0) == stack_pointer_rtx))
- return true;
- }
+ if (may_be_sp_based_p (XEXP (reg, 0)))
+ return true;
return false;
}