diff options
author | Nick Clifton <nickc@redhat.com> | 2007-07-14 16:19:18 +0000 |
---|---|---|
committer | Nick Clifton <nickc@redhat.com> | 2007-07-14 16:19:18 +0000 |
commit | d929913e77af0f9b6bc262610af204bf4e7fffba (patch) | |
tree | 0ff133f2b65d8994eb7f44cebc62925a398aa339 /gas/testsuite | |
parent | f219aedc69cffe0b3ef3d455d7c2f4ed6c141d8d (diff) | |
download | binutils-d929913e77af0f9b6bc262610af204bf4e7fffba.zip binutils-d929913e77af0f9b6bc262610af204bf4e7fffba.tar.gz binutils-d929913e77af0f9b6bc262610af204bf4e7fffba.tar.bz2 |
* config/tc-arm.c (create_register_alias): Return a boolean rather than an integer.
Check the return value of insert_reg_alias and do not continue to create aliases once an insertion has failed.
(s_unreq): Delete the all-upper-case and all-lower-case alternatives as well.
* testsuite/gas/arm/arm.s: Add tests for re-aliasing a previously removed alias.
* testsuite/gas/arm/arm.l: Add new expected warning message.
Diffstat (limited to 'gas/testsuite')
-rw-r--r-- | gas/testsuite/ChangeLog | 6 | ||||
-rw-r--r-- | gas/testsuite/gas/arm/req.l | 1 | ||||
-rw-r--r-- | gas/testsuite/gas/arm/req.s | 20 |
3 files changed, 25 insertions, 2 deletions
diff --git a/gas/testsuite/ChangeLog b/gas/testsuite/ChangeLog index b165e57..210e5f6 100644 --- a/gas/testsuite/ChangeLog +++ b/gas/testsuite/ChangeLog @@ -1,3 +1,9 @@ +2007-07-14 Nick Clifton <nickc@redhat.com> + + * gas/arm/arm.s: Add tests for re-aliasing a previously removed + alias. + * gas/arm/arm.l: Add new expected warning message. + 2007-07-04 H.J. Lu <hongjiu.lu@intel.com> * gas/i386/ssemmx2.d: Ignore padding. diff --git a/gas/testsuite/gas/arm/req.l b/gas/testsuite/gas/arm/req.l index 165d1d8..293db4d 100644 --- a/gas/testsuite/gas/arm/req.l +++ b/gas/testsuite/gas/arm/req.l @@ -1,3 +1,4 @@ [^:]*: Assembler messages: [^:]*:18: Error: ARM register expected -- `add foo,foo,foo' [^:]*:21: Warning: ignoring attempt to undefine built-in register 'r0' +[^:]*:41: Warning: ignoring redefinition of register alias 'FOO' diff --git a/gas/testsuite/gas/arm/req.s b/gas/testsuite/gas/arm/req.s index 341f66d..1330e75 100644 --- a/gas/testsuite/gas/arm/req.s +++ b/gas/testsuite/gas/arm/req.s @@ -19,7 +19,23 @@ test_dot_req_and_unreq: # Attempt to remove the builtin alias for r0. .unreq r0 - + # That is ignored, so this should still work. add r0, r0, r0 - + + # Now attempt to re-alias foo. There used to be a bug whereby the + # first creation of an alias called foo would also create an alias + # called FOO, but the .unreq of foo would not delete FOO. Thus a + # second attempt at aliasing foo (to something different than + # before) would fail because the assembler would complain that FOO + # already existed. + foo .req r1 + + add foo, foo, foo + + # Check that the upper case alias was also recreated. + add FOO, FOO, FOO + + # Check that a second attempt to alias foo, using a mixed case + # verison of the name, will fail. + Foo .req r2 |