summaryrefslogtreecommitdiff
path: root/gcc/lra-constraints.c
diff options
context:
space:
mode:
authorkkojima <kkojima@138bc75d-0d04-0410-961f-82ee72b054a4>2014-12-19 04:40:11 +0000
committerkkojima <kkojima@138bc75d-0d04-0410-961f-82ee72b054a4>2014-12-19 04:40:11 +0000
commitf44473298ed13aea41ff7dfe0d172e1fbba23c5c (patch)
treefd00faa99d4eef198022a52515e9b805f18b3d04 /gcc/lra-constraints.c
parent382efce605068205efb52dab858c95e2caa90a6c (diff)
downloadgcc-f44473298ed13aea41ff7dfe0d172e1fbba23c5c.tar.gz
* Add TARGET_CANNOT_SUBSTITUTE_MEM_EQUIV target macro.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@218886 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/lra-constraints.c')
-rw-r--r--gcc/lra-constraints.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/gcc/lra-constraints.c b/gcc/lra-constraints.c
index 8fc2cb77a5d..9e9539c1a84 100644
--- a/gcc/lra-constraints.c
+++ b/gcc/lra-constraints.c
@@ -488,7 +488,11 @@ get_equiv (rtx x)
|| lra_get_regno_hard_regno (regno) >= 0)
return x;
if ((res = ira_reg_equiv[regno].memory) != NULL_RTX)
- return res;
+ {
+ if (targetm.cannot_substitute_mem_equiv_p (res))
+ return x;
+ return res;
+ }
if ((res = ira_reg_equiv[regno].constant) != NULL_RTX)
return res;
if ((res = ira_reg_equiv[regno].invariant) != NULL_RTX)