aboutsummaryrefslogtreecommitdiff
path: root/gas/config/tc-xtensa.c
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2019-05-08 09:26:36 +0930
committerAlan Modra <amodra@gmail.com>2019-05-08 09:40:08 +0930
commit9632a526cae4cb10276e39d8c4bd1f649d13f8e8 (patch)
tree6805b5a868ee9cf61df3c1776cb3cf893bc1d0fb /gas/config/tc-xtensa.c
parent9420801e573e77f0dd522150932eb27199052a04 (diff)
downloadgdb-9632a526cae4cb10276e39d8c4bd1f649d13f8e8.zip
gdb-9632a526cae4cb10276e39d8c4bd1f649d13f8e8.tar.gz
gdb-9632a526cae4cb10276e39d8c4bd1f649d13f8e8.tar.bz2
xtensa ignores option --no-link-relax
md_begin happens after md_parse_option. * config/tc-xtensa.c (opt_linkrelax): New variable. (md_parse_option): Set it here. (md_begin): Copy opt_linkrelax to linkrelax.
Diffstat (limited to 'gas/config/tc-xtensa.c')
-rw-r--r--gas/config/tc-xtensa.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/gas/config/tc-xtensa.c b/gas/config/tc-xtensa.c
index 9350beb..320e7af 100644
--- a/gas/config/tc-xtensa.c
+++ b/gas/config/tc-xtensa.c
@@ -628,6 +628,7 @@ static bfd_boolean maybe_has_short_loop = FALSE;
static bfd_boolean workaround_close_loop_end = FALSE;
static bfd_boolean maybe_has_close_loop_end = FALSE;
static bfd_boolean enforce_three_byte_loop_align = FALSE;
+static bfd_boolean opt_linkrelax = TRUE;
/* When workaround_short_loops is TRUE, all loops with early exits must
have at least 3 instructions. workaround_all_short_loops is a modifier
@@ -827,10 +828,10 @@ md_parse_option (int c, const char *arg)
as_warn (_("--no-density option is ignored"));
return 1;
case option_link_relax:
- linkrelax = 1;
+ opt_linkrelax = TRUE;
return 1;
case option_no_link_relax:
- linkrelax = 0;
+ opt_linkrelax = FALSE;
return 1;
case option_flix:
produce_flix = FLIX_ALL;
@@ -5258,7 +5259,7 @@ md_begin (void)
xtensa_default_isa = xtensa_isa_init (0, 0);
isa = xtensa_default_isa;
- linkrelax = 1;
+ linkrelax = opt_linkrelax;
/* Set up the literal sections. */
memset (&default_lit_sections, 0, sizeof (default_lit_sections));