summaryrefslogtreecommitdiff
path: root/gcc/recog.c
diff options
context:
space:
mode:
authoraesok <aesok@138bc75d-0d04-0410-961f-82ee72b054a4>2010-05-12 19:08:31 +0000
committeraesok <aesok@138bc75d-0d04-0410-961f-82ee72b054a4>2010-05-12 19:08:31 +0000
commit98e22cb6f77a438ee9a469b45de2b1727218536f (patch)
treeab0664b99a156d91a202d107ee413a933ccb1249 /gcc/recog.c
parent2be0e5431bcecf5fb4f0ac75b8be808c903e0cc5 (diff)
downloadgcc-98e22cb6f77a438ee9a469b45de2b1727218536f.tar.gz
* target.h (struct gcc_target): Add mode_dependent_address_p field.
* target-def.h (TARGET_MODE_DEPENDENT_ADDRESS_P): New. (TARGET_INITIALIZER): Use TARGET_MODE_DEPENDENT_ADDRESS_P. * targhooks.c (default_mode_dependent_address_p): New function. * targhooks.h (default_mode_dependent_address_p): Declare function. * doc/tm.texi (TARGET_MODE_DEPENDENT_ADDRESS_P): New. (GO_IF_MODE_DEPENDENT_ADDRESS): Update. * recog.c: (mode_dependent_address_p): Call mode_dependent_address_p target hook. Change return type to bool. * recog.h: (mode_dependent_address_p): Change return type to bool. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@159339 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/recog.c')
-rw-r--r--gcc/recog.c10
1 files changed, 3 insertions, 7 deletions
diff --git a/gcc/recog.c b/gcc/recog.c
index 0dea35fb3d7..e8f918c7102 100644
--- a/gcc/recog.c
+++ b/gcc/recog.c
@@ -1978,7 +1978,7 @@ offsettable_address_addr_space_p (int strictp, enum machine_mode mode, rtx y,
Autoincrement addressing is a typical example of mode-dependence
because the amount of the increment depends on the mode. */
-int
+bool
mode_dependent_address_p (rtx addr)
{
/* Auto-increment addressing with anything other than post_modify
@@ -1988,13 +1988,9 @@ mode_dependent_address_p (rtx addr)
|| GET_CODE (addr) == POST_INC
|| GET_CODE (addr) == PRE_DEC
|| GET_CODE (addr) == POST_DEC)
- return 1;
+ return true;
- GO_IF_MODE_DEPENDENT_ADDRESS (addr, win);
- return 0;
- /* Label `win' might (not) be used via GO_IF_MODE_DEPENDENT_ADDRESS. */
- win: ATTRIBUTE_UNUSED_LABEL
- return 1;
+ return targetm.mode_dependent_address_p (addr);
}
/* Like extract_insn, but save insn extracted and don't extract again, when