summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYamaArashi <shadow962@live.com>2016-05-12 20:03:02 -0700
committerYamaArashi <shadow962@live.com>2016-05-12 20:03:02 -0700
commit62c7784608102386af4a91798096866fdaa476e5 (patch)
treea57fed8ff2cbd465a043a922e8d3aef124e16d63
parenteb6255a9114c5b746a1f5921b0c88546c098ef86 (diff)
don't use current_function_has_far_jump in old compiler
-rwxr-xr-xgcc/thumb.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/gcc/thumb.c b/gcc/thumb.c
index a513436..954812c 100755
--- a/gcc/thumb.c
+++ b/gcc/thumb.c
@@ -37,7 +37,10 @@
#include "recog.h"
int current_function_anonymous_args = 0;
+
+#ifndef OLD_COMPILER
static int current_function_has_far_jump = 0;
+#endif
/* Used to parse -mstructure_size_boundary command line option. */
char *structure_size_string = NULL;
@@ -713,8 +716,10 @@ far_jump_used_p()
{
rtx insn;
+#ifndef OLD_COMPILER
if (current_function_has_far_jump)
return 1;
+#endif
for (insn = get_insns(); insn; insn = NEXT_INSN(insn))
{
@@ -724,7 +729,9 @@ far_jump_used_p()
&& GET_CODE(PATTERN(insn)) != ADDR_DIFF_VEC
&& get_attr_far_jump(insn) == FAR_JUMP_YES)
{
+#ifndef OLD_COMPILER
current_function_has_far_jump = 1;
+#endif
return 1;
}
}
@@ -934,7 +941,11 @@ thumb_function_epilogue(FILE *f, int frame_size)
function will be emitted as assembly immediately after we generate
RTL for it. This does not happen for inline functions. */
return_used_this_function = 0;
+
+#ifndef OLD_COMPILER
current_function_has_far_jump = 0;
+#endif
+
#if 0 /* TODO : comment not really needed */
fprintf(f, "%s THUMB Epilogue\n", ASM_COMMENT_START);
#endif