From fa30c84f626e82e0e65204a51309aded401d9a10 Mon Sep 17 00:00:00 2001 From: Jan Beulich Date: Wed, 25 May 2005 06:59:36 +0000 Subject: [PATCH] gas/ 2005-05-25 Jan Beulich * config/tc-ia64.c (dot_radix): Rewrite. gas/testsuite/ 2005-05-25 Jan Beulich * gas/ia64/radix.s: New. * gas/ia64/radix.l: New. * gas/ia64/ia64.exp: Run new test. --- gas/ChangeLog | 4 ++++ gas/config/tc-ia64.c | 19 +++++++++++-------- gas/testsuite/ChangeLog | 6 ++++++ gas/testsuite/gas/ia64/ia64.exp | 1 + gas/testsuite/gas/ia64/radix.l | 4 ++++ gas/testsuite/gas/ia64/radix.s | 5 +++++ 6 files changed, 31 insertions(+), 8 deletions(-) create mode 100644 gas/testsuite/gas/ia64/radix.l create mode 100644 gas/testsuite/gas/ia64/radix.s diff --git a/gas/ChangeLog b/gas/ChangeLog index d22323a237..a350c8a04a 100644 --- a/gas/ChangeLog +++ b/gas/ChangeLog @@ -1,3 +1,7 @@ +2005-05-25 Jan Beulich + + * config/tc-ia64.c (dot_radix): Rewrite. + 2005-05-25 Jan Beulich * config/tc-ia64.c (struct unw_rec_list): Remove next_slot_number diff --git a/gas/config/tc-ia64.c b/gas/config/tc-ia64.c index 455c2582c3..ce392b1745 100644 --- a/gas/config/tc-ia64.c +++ b/gas/config/tc-ia64.c @@ -3070,17 +3070,20 @@ static void dot_radix (dummy) int dummy ATTRIBUTE_UNUSED; { - int radix; + char *radix; + int ch; SKIP_WHITESPACE (); - radix = *input_line_pointer++; - if (radix != 'C' && !is_end_of_line[(unsigned char) radix]) - { - as_bad ("Radix `%c' unsupported", *input_line_pointer); - ignore_rest_of_line (); - return; - } + if (is_it_end_of_statement ()) + return; + radix = input_line_pointer; + ch = get_symbol_end (); + ia64_canonicalize_symbol_name (radix); + if (strcasecmp (radix, "C")) + as_bad ("Radix `%s' unsupported or invalid", radix); + *input_line_pointer = ch; + demand_empty_rest_of_line (); } /* Helper function for .loc directives. If the assembler is not generating diff --git a/gas/testsuite/ChangeLog b/gas/testsuite/ChangeLog index 14a58c3af2..84521f84cb 100644 --- a/gas/testsuite/ChangeLog +++ b/gas/testsuite/ChangeLog @@ -1,3 +1,9 @@ +2005-05-25 Jan Beulich + + * gas/ia64/radix.s: New. + * gas/ia64/radix.l: New. + * gas/ia64/ia64.exp: Run new test. + 2005-05-25 Jan Beulich * gas/i386/intelok.d: Account for 32-bit displacements being shown diff --git a/gas/testsuite/gas/ia64/ia64.exp b/gas/testsuite/gas/ia64/ia64.exp index dd3e539c24..6199b24c82 100644 --- a/gas/testsuite/gas/ia64/ia64.exp +++ b/gas/testsuite/gas/ia64/ia64.exp @@ -82,6 +82,7 @@ if [istarget "ia64-*"] then { run_list_test "no-fit" "" run_list_test "pound" "-al" run_list_test "proc" "-munwind-check=error" + run_list_test "radix" "" run_list_test "slot2" "" run_list_test "unwind-err" "-munwind-check=error" run_dump_test "operand-or" diff --git a/gas/testsuite/gas/ia64/radix.l b/gas/testsuite/gas/ia64/radix.l new file mode 100644 index 0000000000..92d9e7cda1 --- /dev/null +++ b/gas/testsuite/gas/ia64/radix.l @@ -0,0 +1,4 @@ +.*: Assembler messages: +.*:1: Error: Radix .a. .*invalid +.*:4: Error: Radix .cc. .*invalid +.*:5: Error: Radix .Z. .*invalid diff --git a/gas/testsuite/gas/ia64/radix.s b/gas/testsuite/gas/ia64/radix.s new file mode 100644 index 0000000000..75dcf7bc86 --- /dev/null +++ b/gas/testsuite/gas/ia64/radix.s @@ -0,0 +1,5 @@ + .radix a + .radix c + .radix C# + .radix cc + .radix Z