diff options
-rw-r--r-- | gas/ChangeLog | 9 | ||||
-rw-r--r-- | gas/config/tc-msp430.c | 8 | ||||
-rw-r--r-- | gas/testsuite/gas/msp430/empty.s | 4 | ||||
-rw-r--r-- | gas/testsuite/gas/msp430/ignore-md.d | 8 | ||||
-rw-r--r-- | gas/testsuite/gas/msp430/msp430.exp | 1 |
5 files changed, 30 insertions, 0 deletions
diff --git a/gas/ChangeLog b/gas/ChangeLog index f412f9d..8976025 100644 --- a/gas/ChangeLog +++ b/gas/ChangeLog @@ -1,3 +1,12 @@ +2020-11-12 Jozef Lawrynowicz <jozef.l@mittosystems.com> + + * config/tc-msp430.c (OPTION_MOVE_DATA): Define. + (md_parse_option): Ignore OPTION_MOVE_DATA. + (md_longopts): Handle -md option. + * testsuite/gas/msp430/msp430.exp: Run new test. + * testsuite/gas/msp430/empty.s: New test. + * testsuite/gas/msp430/ignore-md.d: New test. + 2020-11-12 Nick Clifton <nickc@redhat.com> PR 26850 diff --git a/gas/config/tc-msp430.c b/gas/config/tc-msp430.c index 6d18032..322ad7c 100644 --- a/gas/config/tc-msp430.c +++ b/gas/config/tc-msp430.c @@ -690,6 +690,9 @@ static bfd_boolean upper_data_region_in_use = FALSE; /* The default is to use the lower region only. */ static bfd_boolean lower_data_region_only = TRUE; +/* Deprecated option, silently ignore it for compatibility with GCC <= 10. */ +#define OPTION_MOVE_DATA 'd' + enum { OPTION_SILICON_ERRATA = OPTION_MD_BASE, @@ -1465,6 +1468,10 @@ md_parse_option (int c, const char * arg) do_unknown_interrupt_nops = FALSE; return 1; + case OPTION_MOVE_DATA: + /* Silently ignored. */ + return 1; + case OPTION_DATA_REGION: if (strcmp (arg, "upper") == 0 || strcmp (arg, "either") == 0) @@ -1750,6 +1757,7 @@ struct option md_longopts[] = {"my", no_argument, NULL, OPTION_WARN_INTR_NOPS}, {"mu", no_argument, NULL, OPTION_UNKNOWN_INTR_NOPS}, {"mU", no_argument, NULL, OPTION_NO_UNKNOWN_INTR_NOPS}, + {"md", no_argument, NULL, OPTION_MOVE_DATA}, {"mdata-region", required_argument, NULL, OPTION_DATA_REGION}, {NULL, no_argument, NULL, 0} }; diff --git a/gas/testsuite/gas/msp430/empty.s b/gas/testsuite/gas/msp430/empty.s new file mode 100644 index 0000000..910559d --- /dev/null +++ b/gas/testsuite/gas/msp430/empty.s @@ -0,0 +1,4 @@ +.text +.global foo +foo: +.word 0 diff --git a/gas/testsuite/gas/msp430/ignore-md.d b/gas/testsuite/gas/msp430/ignore-md.d new file mode 100644 index 0000000..2e55f22 --- /dev/null +++ b/gas/testsuite/gas/msp430/ignore-md.d @@ -0,0 +1,8 @@ +#name: Silently Ignore -md Option +#source: empty.s +#as: -md --fatal-warnings +#DUMPPROG: nm + +#... +.*foo.* +#pass diff --git a/gas/testsuite/gas/msp430/msp430.exp b/gas/testsuite/gas/msp430/msp430.exp index 624867f..ae9499c 100644 --- a/gas/testsuite/gas/msp430/msp430.exp +++ b/gas/testsuite/gas/msp430/msp430.exp @@ -53,4 +53,5 @@ if [expr [istarget "msp430-*-*"]] then { run_dump_test "attr-430x-large-any-bad" run_dump_test "attr-430x-large-any-good" run_dump_test "reloc-lo-430x" + run_dump_test "ignore-md" } |