From b32465c97c12cc6049cefcde1beb3e2bfbfa232c Mon Sep 17 00:00:00 2001 From: "Maciej W. Rozycki" Date: Mon, 15 May 2017 13:52:04 +0100 Subject: [PATCH] MIPS16e2: Add new MIPS16e2 relaxation GAS and LD tests Verify MIPS16 PC-relative instruction relaxation using the MIPS16e2 LUI instruction rather than an LI/SLL instruction pair. gas/ * testsuite/gas/mips/mips16-pcrel-1.d: Remove `-mips3' from `as' flags. * testsuite/gas/mips/mips16-pcrel-pic-1.d: Likewise. * testsuite/gas/mips/mips16-pcrel-n32-0.d: Likewise. * testsuite/gas/mips/mips16-pcrel-n32-1.d: Likewise. * testsuite/gas/mips/mips16-pcrel-n64-0.d: Likewise. * testsuite/gas/mips/mips16-pcrel-n64-1.d: Likewise. * testsuite/gas/mips/mips16-pcrel-n64-sym32-0.d: Likewise. * testsuite/gas/mips/mips16-pcrel-n64-sym32-1.d: Likewise. * testsuite/gas/mips/mips16-pcrel-reloc-4.d: Likewise. * testsuite/gas/mips/mips16-pcrel-reloc-5.d: Likewise. * testsuite/gas/mips/mips16-pcrel-reloc-6.d: Likewise. * testsuite/gas/mips/mips16-pcrel-reloc-7.d: Likewise. * testsuite/gas/mips/mips16-pcrel-addend-4.d: Likewise. * testsuite/gas/mips/mips16-pcrel-addend-5.d: Likewise. * testsuite/gas/mips/mips16-pcrel-addend-6.d: Likewise. * testsuite/gas/mips/mips16-pcrel-addend-7.d: Likewise. * testsuite/gas/mips/mips16-pcrel-addend-9.d: Likewise. * testsuite/gas/mips/mips16-pcrel-addend-pic-9.d: Likewise. * testsuite/gas/mips/mips16-pcrel-addend-n32-8.d: Likewise. * testsuite/gas/mips/mips16-pcrel-addend-n32-9.d: Likewise. * testsuite/gas/mips/mips16-pcrel-addend-n64-sym32-8.d: Likewise. * testsuite/gas/mips/mips16-pcrel-addend-n64-sym32-9.d: Likewise. * testsuite/gas/mips/mips16-pcrel-addend-n64-8.d: Likewise. * testsuite/gas/mips/mips16-pcrel-addend-n64-9.d: Likewise. * testsuite/gas/mips/mips16-pcrel-absolute-2.d: Likewise. * testsuite/gas/mips/mips16-pcrel-absolute-3.d: Likewise. * testsuite/gas/mips/mips16-pcrel-absolute-6.d: Likewise. * testsuite/gas/mips/mips16-pcrel-absolute-7.d: Likewise. * testsuite/gas/mips/mips16-pcrel-absolute-pic-6.d: Likewise. * testsuite/gas/mips/mips16-pcrel-absolute-n32-4.d: Likewise. * testsuite/gas/mips/mips16-pcrel-absolute-n32-6.d: Likewise. * testsuite/gas/mips/mips16-pcrel-absolute-n64-4.d: Likewise. * testsuite/gas/mips/mips16-pcrel-absolute-n64-6.d: Likewise. * testsuite/gas/mips/mips16-pcrel-absolute-n64-sym32-4.d: Likewise. * testsuite/gas/mips/mips16-pcrel-absolute-n64-sym32-6.d: Likewise. * testsuite/gas/mips/mips16-pcrel-absolute-pic-n32-4.d: Likewise. * testsuite/gas/mips/mips16-pcrel-absolute-pic-n32-6.d: Likewise. * testsuite/gas/mips/mips16-pcrel-absolute-pic-n64-4.d: Likewise. * testsuite/gas/mips/mips16-pcrel-absolute-pic-n64-6.d: Likewise. * testsuite/gas/mips/mips16-pcrel-absolute-pic-n64-sym32-4.d: Likewise. * testsuite/gas/mips/mips16-pcrel-absolute-pic-n64-sym32-6.d: Likewise. * testsuite/gas/mips/mips16e2@mips16-pcrel-0.d: New test. * testsuite/gas/mips/mips16e2@mips16-pcrel-1.d: New test. * testsuite/gas/mips/mips16e2@mips16-pcrel-2.d: New test. * testsuite/gas/mips/mips16e2@mips16-pcrel-n32-0.d: New test. * testsuite/gas/mips/mips16e2@mips16-pcrel-n32-1.d: New test. * testsuite/gas/mips/mips16e2@mips16-pcrel-n64-sym32-0.d: New test. * testsuite/gas/mips/mips16e2@mips16-pcrel-n64-sym32-1.d: New test. * testsuite/gas/mips/mips16e2@mips16-pcrel-delay-0.d: New test. * testsuite/gas/mips/mips16e2@mips16-pcrel-delay-1.d: New test. * testsuite/gas/mips/mips16e2@mips16-pcrel-reloc-2.d: New test. * testsuite/gas/mips/mips16e2@mips16-pcrel-reloc-3.d: New test. * testsuite/gas/mips/mips16e2@mips16-pcrel-reloc-6.d: New test. * testsuite/gas/mips/mips16e2@mips16-pcrel-reloc-7.d: New test. * testsuite/gas/mips/mips16e2@mips16-pcrel-addend-2.d: New test. * testsuite/gas/mips/mips16e2@mips16-pcrel-addend-3.d: New test. * testsuite/gas/mips/mips16e2@mips16-pcrel-addend-6.d: New test. * testsuite/gas/mips/mips16e2@mips16-pcrel-addend-7.d: New test. * testsuite/gas/mips/mips16e2@mips16-pcrel-addend-8.d: New test. * testsuite/gas/mips/mips16e2@mips16-pcrel-addend-9.d: New test. * testsuite/gas/mips/mips16e2@mips16-pcrel-addend-n32-8.d: New test. * testsuite/gas/mips/mips16e2@mips16-pcrel-addend-n32-9.d: New test. * testsuite/gas/mips/mips16e2@mips16-pcrel-addend-n64-sym32-8.d: New test. * testsuite/gas/mips/mips16e2@mips16-pcrel-addend-n64-sym32-9.d: New test. * testsuite/gas/mips/mips16e2@mips16-pcrel-absolute.d: New test. * testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-1.d: New test. * testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-2.d: New test. * testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-3.d: New test. * testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-4.d: New test. * testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-5.d: New test. * testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-6.d: New test. * testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-7.d: New test. * testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-pic-4.d: New test. * testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-pic-6.d: New test. * testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-n32-4.d: New test. * testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-n32-6.d: New test. * testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-n64-sym32-4.d: New test. * testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-n64-sym32-6.d: New test. * testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-pic-n32-4.d: New test. * testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-pic-n32-6.d: New test. * testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-pic-n64-sym32-4.d: New test. * testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-pic-n64-sym32-6.d: New test. * testsuite/gas/mips/mips16-pcrel-1.l: Adjust line numbers. * testsuite/gas/mips/mips16-pcrel-1.s: Adjust for alignment preservation between MIPS16 and MIPS16e2 code. * testsuite/gas/mips/mips.exp: Run MIPS16 relaxation tests over all MIPS16 architectures. ld/ * testsuite/ld-mips-elf/mips16e2-pcrel-0.d: New test. * testsuite/ld-mips-elf/mips16e2-pcrel-1.d: New test. * testsuite/ld-mips-elf/mips16e2-pcrel-addend-2.d: New test. * testsuite/ld-mips-elf/mips16e2-pcrel-addend-6.d: New test. * testsuite/ld-mips-elf/mips16e2-pcrel-n32-0.d: New test. * testsuite/ld-mips-elf/mips16e2-pcrel-n32-1.d: New test. * testsuite/ld-mips-elf/mips16e2-pcrel-n64-sym32-0.d: New test. * testsuite/ld-mips-elf/mips16e2-pcrel-n64-sym32-1.d: New test. * testsuite/ld-mips-elf/mips-elf.exp: Run the new tests. --- gas/ChangeLog | 124 ++++++++++++ gas/testsuite/gas/mips/mips.exp | 190 ++++++++++++------ gas/testsuite/gas/mips/mips16-pcrel-1.d | 2 +- gas/testsuite/gas/mips/mips16-pcrel-1.l | 6 +- gas/testsuite/gas/mips/mips16-pcrel-1.s | 19 +- .../gas/mips/mips16-pcrel-absolute-2.d | 2 +- .../gas/mips/mips16-pcrel-absolute-3.d | 2 +- .../gas/mips/mips16-pcrel-absolute-6.d | 2 +- .../gas/mips/mips16-pcrel-absolute-7.d | 2 +- .../gas/mips/mips16-pcrel-absolute-n32-4.d | 2 +- .../gas/mips/mips16-pcrel-absolute-n32-6.d | 2 +- .../gas/mips/mips16-pcrel-absolute-n64-4.d | 2 +- .../gas/mips/mips16-pcrel-absolute-n64-6.d | 2 +- .../mips/mips16-pcrel-absolute-n64-sym32-4.d | 2 +- .../mips/mips16-pcrel-absolute-n64-sym32-6.d | 2 +- .../gas/mips/mips16-pcrel-absolute-pic-6.d | 2 +- .../mips/mips16-pcrel-absolute-pic-n32-4.d | 2 +- .../mips/mips16-pcrel-absolute-pic-n32-6.d | 2 +- .../mips/mips16-pcrel-absolute-pic-n64-4.d | 2 +- .../mips/mips16-pcrel-absolute-pic-n64-6.d | 2 +- .../mips16-pcrel-absolute-pic-n64-sym32-4.d | 2 +- .../mips16-pcrel-absolute-pic-n64-sym32-6.d | 2 +- .../gas/mips/mips16-pcrel-addend-4.d | 2 +- .../gas/mips/mips16-pcrel-addend-5.d | 2 +- .../gas/mips/mips16-pcrel-addend-6.d | 2 +- .../gas/mips/mips16-pcrel-addend-7.d | 2 +- .../gas/mips/mips16-pcrel-addend-9.d | 2 +- .../gas/mips/mips16-pcrel-addend-n32-8.d | 2 +- .../gas/mips/mips16-pcrel-addend-n32-9.d | 2 +- .../gas/mips/mips16-pcrel-addend-n64-8.d | 2 +- .../gas/mips/mips16-pcrel-addend-n64-9.d | 2 +- .../mips/mips16-pcrel-addend-n64-sym32-8.d | 2 +- .../mips/mips16-pcrel-addend-n64-sym32-9.d | 2 +- .../gas/mips/mips16-pcrel-addend-pic-9.d | 2 +- gas/testsuite/gas/mips/mips16-pcrel-n32-0.d | 2 +- gas/testsuite/gas/mips/mips16-pcrel-n32-1.d | 2 +- gas/testsuite/gas/mips/mips16-pcrel-n64-0.d | 2 +- gas/testsuite/gas/mips/mips16-pcrel-n64-1.d | 2 +- .../gas/mips/mips16-pcrel-n64-sym32-0.d | 2 +- .../gas/mips/mips16-pcrel-n64-sym32-1.d | 2 +- gas/testsuite/gas/mips/mips16-pcrel-pic-1.d | 2 +- gas/testsuite/gas/mips/mips16-pcrel-reloc-4.d | 2 +- gas/testsuite/gas/mips/mips16-pcrel-reloc-5.d | 2 +- gas/testsuite/gas/mips/mips16-pcrel-reloc-6.d | 2 +- gas/testsuite/gas/mips/mips16-pcrel-reloc-7.d | 2 +- .../gas/mips/mips16e2@mips16-pcrel-0.d | 44 ++++ .../gas/mips/mips16e2@mips16-pcrel-1.d | 52 +++++ .../gas/mips/mips16e2@mips16-pcrel-2.d | 6 + .../mips/mips16e2@mips16-pcrel-absolute-1.d | 5 + .../mips/mips16e2@mips16-pcrel-absolute-2.d | 15 ++ .../mips/mips16e2@mips16-pcrel-absolute-3.d | 5 + .../mips/mips16e2@mips16-pcrel-absolute-4.d | 27 +++ .../mips/mips16e2@mips16-pcrel-absolute-5.d | 5 + .../mips/mips16e2@mips16-pcrel-absolute-6.d | 27 +++ .../mips/mips16e2@mips16-pcrel-absolute-7.d | 5 + .../mips16e2@mips16-pcrel-absolute-n32-4.d | 5 + .../mips16e2@mips16-pcrel-absolute-n32-6.d | 5 + ...ps16e2@mips16-pcrel-absolute-n64-sym32-4.d | 5 + ...ps16e2@mips16-pcrel-absolute-n64-sym32-6.d | 5 + .../mips16e2@mips16-pcrel-absolute-pic-4.d | 5 + .../mips16e2@mips16-pcrel-absolute-pic-6.d | 5 + ...mips16e2@mips16-pcrel-absolute-pic-n32-4.d | 5 + ...mips16e2@mips16-pcrel-absolute-pic-n32-6.d | 5 + ...e2@mips16-pcrel-absolute-pic-n64-sym32-4.d | 5 + ...e2@mips16-pcrel-absolute-pic-n64-sym32-6.d | 5 + .../gas/mips/mips16e2@mips16-pcrel-absolute.d | 15 ++ .../gas/mips/mips16e2@mips16-pcrel-addend-2.d | 20 ++ .../gas/mips/mips16e2@mips16-pcrel-addend-3.d | 19 ++ .../gas/mips/mips16e2@mips16-pcrel-addend-6.d | 20 ++ .../gas/mips/mips16e2@mips16-pcrel-addend-7.d | 19 ++ .../gas/mips/mips16e2@mips16-pcrel-addend-8.d | 43 ++++ .../gas/mips/mips16e2@mips16-pcrel-addend-9.d | 43 ++++ .../mips/mips16e2@mips16-pcrel-addend-n32-8.d | 43 ++++ .../mips/mips16e2@mips16-pcrel-addend-n32-9.d | 43 ++++ ...mips16e2@mips16-pcrel-addend-n64-sym32-8.d | 75 +++++++ ...mips16e2@mips16-pcrel-addend-n64-sym32-9.d | 75 +++++++ .../gas/mips/mips16e2@mips16-pcrel-delay-0.d | 34 ++++ .../gas/mips/mips16e2@mips16-pcrel-delay-1.d | 39 ++++ .../gas/mips/mips16e2@mips16-pcrel-n32-0.d | 44 ++++ .../gas/mips/mips16e2@mips16-pcrel-n32-1.d | 52 +++++ .../mips/mips16e2@mips16-pcrel-n64-sym32-0.d | 60 ++++++ .../mips/mips16e2@mips16-pcrel-n64-sym32-1.d | 68 +++++++ .../gas/mips/mips16e2@mips16-pcrel-reloc-2.d | 20 ++ .../gas/mips/mips16e2@mips16-pcrel-reloc-3.d | 19 ++ .../gas/mips/mips16e2@mips16-pcrel-reloc-6.d | 20 ++ .../gas/mips/mips16e2@mips16-pcrel-reloc-7.d | 19 ++ ld/ChangeLog | 12 ++ ld/testsuite/ld-mips-elf/mips-elf.exp | 10 + ld/testsuite/ld-mips-elf/mips16e2-pcrel-0.d | 37 ++++ ld/testsuite/ld-mips-elf/mips16e2-pcrel-1.d | 45 +++++ .../ld-mips-elf/mips16e2-pcrel-addend-2.d | 17 ++ .../ld-mips-elf/mips16e2-pcrel-addend-6.d | 17 ++ .../ld-mips-elf/mips16e2-pcrel-n32-0.d | 6 + .../ld-mips-elf/mips16e2-pcrel-n32-1.d | 6 + .../ld-mips-elf/mips16e2-pcrel-n64-sym32-0.d | 6 + .../ld-mips-elf/mips16e2-pcrel-n64-sym32-1.d | 6 + 96 files changed, 1500 insertions(+), 114 deletions(-) create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-0.d create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-1.d create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-2.d create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-1.d create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-2.d create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-3.d create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-4.d create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-5.d create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-6.d create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-7.d create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-n32-4.d create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-n32-6.d create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-n64-sym32-4.d create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-n64-sym32-6.d create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-pic-4.d create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-pic-6.d create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-pic-n32-4.d create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-pic-n32-6.d create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-pic-n64-sym32-4.d create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-pic-n64-sym32-6.d create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute.d create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-addend-2.d create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-addend-3.d create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-addend-6.d create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-addend-7.d create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-addend-8.d create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-addend-9.d create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-addend-n32-8.d create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-addend-n32-9.d create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-addend-n64-sym32-8.d create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-addend-n64-sym32-9.d create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-delay-0.d create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-delay-1.d create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-n32-0.d create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-n32-1.d create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-n64-sym32-0.d create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-n64-sym32-1.d create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-reloc-2.d create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-reloc-3.d create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-reloc-6.d create mode 100644 gas/testsuite/gas/mips/mips16e2@mips16-pcrel-reloc-7.d create mode 100644 ld/testsuite/ld-mips-elf/mips16e2-pcrel-0.d create mode 100644 ld/testsuite/ld-mips-elf/mips16e2-pcrel-1.d create mode 100644 ld/testsuite/ld-mips-elf/mips16e2-pcrel-addend-2.d create mode 100644 ld/testsuite/ld-mips-elf/mips16e2-pcrel-addend-6.d create mode 100644 ld/testsuite/ld-mips-elf/mips16e2-pcrel-n32-0.d create mode 100644 ld/testsuite/ld-mips-elf/mips16e2-pcrel-n32-1.d create mode 100644 ld/testsuite/ld-mips-elf/mips16e2-pcrel-n64-sym32-0.d create mode 100644 ld/testsuite/ld-mips-elf/mips16e2-pcrel-n64-sym32-1.d diff --git a/gas/ChangeLog b/gas/ChangeLog index 6cdca286249..293930b280e 100644 --- a/gas/ChangeLog +++ b/gas/ChangeLog @@ -1,3 +1,127 @@ +2017-05-15 Maciej W. Rozycki + + * testsuite/gas/mips/mips16-pcrel-1.d: Remove `-mips3' from `as' + flags. + * testsuite/gas/mips/mips16-pcrel-pic-1.d: Likewise. + * testsuite/gas/mips/mips16-pcrel-n32-0.d: Likewise. + * testsuite/gas/mips/mips16-pcrel-n32-1.d: Likewise. + * testsuite/gas/mips/mips16-pcrel-n64-0.d: Likewise. + * testsuite/gas/mips/mips16-pcrel-n64-1.d: Likewise. + * testsuite/gas/mips/mips16-pcrel-n64-sym32-0.d: Likewise. + * testsuite/gas/mips/mips16-pcrel-n64-sym32-1.d: Likewise. + * testsuite/gas/mips/mips16-pcrel-reloc-4.d: Likewise. + * testsuite/gas/mips/mips16-pcrel-reloc-5.d: Likewise. + * testsuite/gas/mips/mips16-pcrel-reloc-6.d: Likewise. + * testsuite/gas/mips/mips16-pcrel-reloc-7.d: Likewise. + * testsuite/gas/mips/mips16-pcrel-addend-4.d: Likewise. + * testsuite/gas/mips/mips16-pcrel-addend-5.d: Likewise. + * testsuite/gas/mips/mips16-pcrel-addend-6.d: Likewise. + * testsuite/gas/mips/mips16-pcrel-addend-7.d: Likewise. + * testsuite/gas/mips/mips16-pcrel-addend-9.d: Likewise. + * testsuite/gas/mips/mips16-pcrel-addend-pic-9.d: Likewise. + * testsuite/gas/mips/mips16-pcrel-addend-n32-8.d: Likewise. + * testsuite/gas/mips/mips16-pcrel-addend-n32-9.d: Likewise. + * testsuite/gas/mips/mips16-pcrel-addend-n64-sym32-8.d: + Likewise. + * testsuite/gas/mips/mips16-pcrel-addend-n64-sym32-9.d: + Likewise. + * testsuite/gas/mips/mips16-pcrel-addend-n64-8.d: Likewise. + * testsuite/gas/mips/mips16-pcrel-addend-n64-9.d: Likewise. + * testsuite/gas/mips/mips16-pcrel-absolute-2.d: Likewise. + * testsuite/gas/mips/mips16-pcrel-absolute-3.d: Likewise. + * testsuite/gas/mips/mips16-pcrel-absolute-6.d: Likewise. + * testsuite/gas/mips/mips16-pcrel-absolute-7.d: Likewise. + * testsuite/gas/mips/mips16-pcrel-absolute-pic-6.d: Likewise. + * testsuite/gas/mips/mips16-pcrel-absolute-n32-4.d: Likewise. + * testsuite/gas/mips/mips16-pcrel-absolute-n32-6.d: Likewise. + * testsuite/gas/mips/mips16-pcrel-absolute-n64-4.d: Likewise. + * testsuite/gas/mips/mips16-pcrel-absolute-n64-6.d: Likewise. + * testsuite/gas/mips/mips16-pcrel-absolute-n64-sym32-4.d: + Likewise. + * testsuite/gas/mips/mips16-pcrel-absolute-n64-sym32-6.d: + Likewise. + * testsuite/gas/mips/mips16-pcrel-absolute-pic-n32-4.d: + Likewise. + * testsuite/gas/mips/mips16-pcrel-absolute-pic-n32-6.d: + Likewise. + * testsuite/gas/mips/mips16-pcrel-absolute-pic-n64-4.d: + Likewise. + * testsuite/gas/mips/mips16-pcrel-absolute-pic-n64-6.d: + Likewise. + * testsuite/gas/mips/mips16-pcrel-absolute-pic-n64-sym32-4.d: + Likewise. + * testsuite/gas/mips/mips16-pcrel-absolute-pic-n64-sym32-6.d: + Likewise. + * testsuite/gas/mips/mips16e2@mips16-pcrel-0.d: New test. + * testsuite/gas/mips/mips16e2@mips16-pcrel-1.d: New test. + * testsuite/gas/mips/mips16e2@mips16-pcrel-2.d: New test. + * testsuite/gas/mips/mips16e2@mips16-pcrel-n32-0.d: New test. + * testsuite/gas/mips/mips16e2@mips16-pcrel-n32-1.d: New test. + * testsuite/gas/mips/mips16e2@mips16-pcrel-n64-sym32-0.d: New + test. + * testsuite/gas/mips/mips16e2@mips16-pcrel-n64-sym32-1.d: New + test. + * testsuite/gas/mips/mips16e2@mips16-pcrel-delay-0.d: New test. + * testsuite/gas/mips/mips16e2@mips16-pcrel-delay-1.d: New test. + * testsuite/gas/mips/mips16e2@mips16-pcrel-reloc-2.d: New test. + * testsuite/gas/mips/mips16e2@mips16-pcrel-reloc-3.d: New test. + * testsuite/gas/mips/mips16e2@mips16-pcrel-reloc-6.d: New test. + * testsuite/gas/mips/mips16e2@mips16-pcrel-reloc-7.d: New test. + * testsuite/gas/mips/mips16e2@mips16-pcrel-addend-2.d: New test. + * testsuite/gas/mips/mips16e2@mips16-pcrel-addend-3.d: New test. + * testsuite/gas/mips/mips16e2@mips16-pcrel-addend-6.d: New test. + * testsuite/gas/mips/mips16e2@mips16-pcrel-addend-7.d: New test. + * testsuite/gas/mips/mips16e2@mips16-pcrel-addend-8.d: New test. + * testsuite/gas/mips/mips16e2@mips16-pcrel-addend-9.d: New test. + * testsuite/gas/mips/mips16e2@mips16-pcrel-addend-n32-8.d: New + test. + * testsuite/gas/mips/mips16e2@mips16-pcrel-addend-n32-9.d: New + test. + * testsuite/gas/mips/mips16e2@mips16-pcrel-addend-n64-sym32-8.d: + New test. + * testsuite/gas/mips/mips16e2@mips16-pcrel-addend-n64-sym32-9.d: + New test. + * testsuite/gas/mips/mips16e2@mips16-pcrel-absolute.d: New test. + * testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-1.d: New + test. + * testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-2.d: New + test. + * testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-3.d: New + test. + * testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-4.d: New + test. + * testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-5.d: New + test. + * testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-6.d: New + test. + * testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-7.d: New + test. + * testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-pic-4.d: New + test. + * testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-pic-6.d: New + test. + * testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-n32-4.d: New + test. + * testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-n32-6.d: New + test. + * testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-n64-sym32-4.d: + New test. + * testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-n64-sym32-6.d: + New test. + * testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-pic-n32-4.d: + New test. + * testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-pic-n32-6.d: + New test. + * testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-pic-n64-sym32-4.d: + New test. + * testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-pic-n64-sym32-6.d: + New test. + * testsuite/gas/mips/mips16-pcrel-1.l: Adjust line numbers. + * testsuite/gas/mips/mips16-pcrel-1.s: Adjust for alignment + preservation between MIPS16 and MIPS16e2 code. + * testsuite/gas/mips/mips.exp: Run MIPS16 relaxation tests over + all MIPS16 architectures. + 2017-05-15 Maciej W. Rozycki * testsuite/gas/mips/mips16e2.d: New test. diff --git a/gas/testsuite/gas/mips/mips.exp b/gas/testsuite/gas/mips/mips.exp index 7b20b4cb620..40aa95af07d 100644 --- a/gas/testsuite/gas/mips/mips.exp +++ b/gas/testsuite/gas/mips/mips.exp @@ -1567,79 +1567,137 @@ if { [istarget mips*-*-vxworks*] } { run_list_test "pcrel-reloc-6" "-32 --defsym offset=4" \ "MIPS local PC-relative relocations 6b" - run_dump_test "mips16-pcrel-0" - run_dump_test "mips16-pcrel-1" - run_dump_test "mips16-pcrel-2" - run_dump_test "mips16-pcrel-3" - run_dump_test "mips16-pcrel-4" - run_dump_test "mips16-pcrel-5" - run_dump_test "mips16-pcrel-pic-0" - run_dump_test "mips16-pcrel-pic-1" + run_dump_test_arches "mips16-pcrel-0" [mips_arch_list_matching mips16-32] + run_dump_test_arches "mips16-pcrel-1" [mips_arch_list_matching mips16-64] + run_dump_test_arches "mips16-pcrel-2" [mips_arch_list_matching mips16-32] + run_dump_test_arches "mips16-pcrel-3" [mips_arch_list_matching mips16-32] + run_dump_test_arches "mips16-pcrel-4" [mips_arch_list_matching mips16-32] + run_dump_test_arches "mips16-pcrel-5" [mips_arch_list_matching mips16-32] + run_dump_test_arches "mips16-pcrel-pic-0" \ + [mips_arch_list_matching mips16-32] + run_dump_test_arches "mips16-pcrel-pic-1" \ + [mips_arch_list_matching mips16-64] if $has_newabi { - run_dump_test "mips16-pcrel-n32-0" - run_dump_test "mips16-pcrel-n32-1" - run_dump_test "mips16-pcrel-n64-sym32-0" - run_dump_test "mips16-pcrel-n64-sym32-1" - run_dump_test "mips16-pcrel-n64-0" - run_dump_test "mips16-pcrel-n64-1" - } - run_dump_test "mips16-pcrel-delay-0" - run_dump_test "mips16-pcrel-delay-1" + run_dump_test_arches "mips16-pcrel-n32-0" \ + [mips_arch_list_matching mips16-64] + run_dump_test_arches "mips16-pcrel-n32-1" \ + [mips_arch_list_matching mips16-64] + run_dump_test_arches "mips16-pcrel-n64-sym32-0" \ + [mips_arch_list_matching mips16-64] + run_dump_test_arches "mips16-pcrel-n64-sym32-1" \ + [mips_arch_list_matching mips16-64] + run_dump_test_arches "mips16-pcrel-n64-0" \ + [mips_arch_list_matching mips16-64] + run_dump_test_arches "mips16-pcrel-n64-1" \ + [mips_arch_list_matching mips16-64] + } + run_dump_test_arches "mips16-pcrel-delay-0" \ + [mips_arch_list_matching mips16-32] + run_dump_test_arches "mips16-pcrel-delay-1" \ + [mips_arch_list_matching mips16-32] run_dump_test "mips16-pcrel-relax-0" run_dump_test "mips16-pcrel-relax-1" run_dump_test "mips16-pcrel-relax-2" run_dump_test "mips16-pcrel-relax-3" - run_dump_test "mips16-pcrel-reloc-0" - run_dump_test "mips16-pcrel-reloc-1" - run_dump_test "mips16-pcrel-reloc-2" - run_dump_test "mips16-pcrel-reloc-3" - run_dump_test "mips16-pcrel-reloc-4" - run_dump_test "mips16-pcrel-reloc-5" - run_dump_test "mips16-pcrel-reloc-6" - run_dump_test "mips16-pcrel-reloc-7" - run_dump_test "mips16-pcrel-addend-0" - run_dump_test "mips16-pcrel-addend-1" - run_dump_test "mips16-pcrel-addend-2" - run_dump_test "mips16-pcrel-addend-3" - run_dump_test "mips16-pcrel-addend-4" - run_dump_test "mips16-pcrel-addend-5" - run_dump_test "mips16-pcrel-addend-6" - run_dump_test "mips16-pcrel-addend-7" - run_dump_test "mips16-pcrel-addend-8" - run_dump_test "mips16-pcrel-addend-9" - run_dump_test "mips16-pcrel-addend-pic-8" - run_dump_test "mips16-pcrel-addend-pic-9" + run_dump_test_arches "mips16-pcrel-reloc-0" \ + [mips_arch_list_matching mips16-32] + run_dump_test_arches "mips16-pcrel-reloc-1" \ + [mips_arch_list_matching mips16-32] + run_dump_test_arches "mips16-pcrel-reloc-2" \ + [mips_arch_list_matching mips16-32] + run_dump_test_arches "mips16-pcrel-reloc-3" \ + [mips_arch_list_matching mips16-32] + run_dump_test_arches "mips16-pcrel-reloc-4" \ + [mips_arch_list_matching mips16-64] + run_dump_test_arches "mips16-pcrel-reloc-5" \ + [mips_arch_list_matching mips16-64] + run_dump_test_arches "mips16-pcrel-reloc-6" \ + [mips_arch_list_matching mips16-64] + run_dump_test_arches "mips16-pcrel-reloc-7" \ + [mips_arch_list_matching mips16-64] + run_dump_test_arches "mips16-pcrel-addend-0" \ + [mips_arch_list_matching mips16-32] + run_dump_test_arches "mips16-pcrel-addend-1" \ + [mips_arch_list_matching mips16-32] + run_dump_test_arches "mips16-pcrel-addend-2" \ + [mips_arch_list_matching mips16-32] + run_dump_test_arches "mips16-pcrel-addend-3" \ + [mips_arch_list_matching mips16-32] + run_dump_test_arches "mips16-pcrel-addend-4" \ + [mips_arch_list_matching mips16-64] + run_dump_test_arches "mips16-pcrel-addend-5" \ + [mips_arch_list_matching mips16-64] + run_dump_test_arches "mips16-pcrel-addend-6" \ + [mips_arch_list_matching mips16-64] + run_dump_test_arches "mips16-pcrel-addend-7" \ + [mips_arch_list_matching mips16-64] + run_dump_test_arches "mips16-pcrel-addend-8" \ + [mips_arch_list_matching mips16-32] + run_dump_test_arches "mips16-pcrel-addend-9" \ + [mips_arch_list_matching mips16-64] + run_dump_test_arches "mips16-pcrel-addend-pic-8" \ + [mips_arch_list_matching mips16-32] + run_dump_test_arches "mips16-pcrel-addend-pic-9" \ + [mips_arch_list_matching mips16-64] if $has_newabi { - run_dump_test "mips16-pcrel-addend-n32-8" - run_dump_test "mips16-pcrel-addend-n32-9" - run_dump_test "mips16-pcrel-addend-n64-sym32-8" - run_dump_test "mips16-pcrel-addend-n64-sym32-9" - run_dump_test "mips16-pcrel-addend-n64-8" - run_dump_test "mips16-pcrel-addend-n64-9" - } - run_dump_test "mips16-pcrel-absolute" - run_dump_test "mips16-pcrel-absolute-1" - run_dump_test "mips16-pcrel-absolute-2" - run_dump_test "mips16-pcrel-absolute-3" - run_dump_test "mips16-pcrel-absolute-4" - run_dump_test "mips16-pcrel-absolute-5" - run_dump_test "mips16-pcrel-absolute-6" - run_dump_test "mips16-pcrel-absolute-7" - run_dump_test "mips16-pcrel-absolute-pic-4" - run_dump_test "mips16-pcrel-absolute-pic-6" + run_dump_test_arches "mips16-pcrel-addend-n32-8" \ + [mips_arch_list_matching mips16-64] + run_dump_test_arches "mips16-pcrel-addend-n32-9" \ + [mips_arch_list_matching mips16-64] + run_dump_test_arches "mips16-pcrel-addend-n64-sym32-8" \ + [mips_arch_list_matching mips16-64] + run_dump_test_arches "mips16-pcrel-addend-n64-sym32-9" \ + [mips_arch_list_matching mips16-64] + run_dump_test_arches "mips16-pcrel-addend-n64-8" \ + [mips_arch_list_matching mips16-64] + run_dump_test_arches "mips16-pcrel-addend-n64-9" \ + [mips_arch_list_matching mips16-64] + } + run_dump_test_arches "mips16-pcrel-absolute" \ + [mips_arch_list_matching mips16-32] + run_dump_test_arches "mips16-pcrel-absolute-1" \ + [mips_arch_list_matching mips16-32] + run_dump_test_arches "mips16-pcrel-absolute-2" \ + [mips_arch_list_matching mips16-64] + run_dump_test_arches "mips16-pcrel-absolute-3" \ + [mips_arch_list_matching mips16-64] + run_dump_test_arches "mips16-pcrel-absolute-4" \ + [mips_arch_list_matching mips16-32] + run_dump_test_arches "mips16-pcrel-absolute-5" \ + [mips_arch_list_matching mips16-32] + run_dump_test_arches "mips16-pcrel-absolute-6" \ + [mips_arch_list_matching mips16-64] + run_dump_test_arches "mips16-pcrel-absolute-7" \ + [mips_arch_list_matching mips16-64] + run_dump_test_arches "mips16-pcrel-absolute-pic-4" \ + [mips_arch_list_matching mips16-32] + run_dump_test_arches "mips16-pcrel-absolute-pic-6" \ + [mips_arch_list_matching mips16-64] if $has_newabi { - run_dump_test "mips16-pcrel-absolute-n32-4" - run_dump_test "mips16-pcrel-absolute-n32-6" - run_dump_test "mips16-pcrel-absolute-n64-4" - run_dump_test "mips16-pcrel-absolute-n64-6" - run_dump_test "mips16-pcrel-absolute-n64-sym32-4" - run_dump_test "mips16-pcrel-absolute-n64-sym32-6" - run_dump_test "mips16-pcrel-absolute-pic-n32-4" - run_dump_test "mips16-pcrel-absolute-pic-n32-6" - run_dump_test "mips16-pcrel-absolute-pic-n64-4" - run_dump_test "mips16-pcrel-absolute-pic-n64-6" - run_dump_test "mips16-pcrel-absolute-pic-n64-sym32-4" - run_dump_test "mips16-pcrel-absolute-pic-n64-sym32-6" + run_dump_test_arches "mips16-pcrel-absolute-n32-4" \ + [mips_arch_list_matching mips16-64] + run_dump_test_arches "mips16-pcrel-absolute-n32-6" \ + [mips_arch_list_matching mips16-64] + run_dump_test_arches "mips16-pcrel-absolute-n64-4" \ + [mips_arch_list_matching mips16-64] + run_dump_test_arches "mips16-pcrel-absolute-n64-6" \ + [mips_arch_list_matching mips16-64] + run_dump_test_arches "mips16-pcrel-absolute-n64-sym32-4" \ + [mips_arch_list_matching mips16-64] + run_dump_test_arches "mips16-pcrel-absolute-n64-sym32-6" \ + [mips_arch_list_matching mips16-64] + run_dump_test_arches "mips16-pcrel-absolute-pic-n32-4" \ + [mips_arch_list_matching mips16-64] + run_dump_test_arches "mips16-pcrel-absolute-pic-n32-6" \ + [mips_arch_list_matching mips16-64] + run_dump_test_arches "mips16-pcrel-absolute-pic-n64-4" \ + [mips_arch_list_matching mips16-64] + run_dump_test_arches "mips16-pcrel-absolute-pic-n64-6" \ + [mips_arch_list_matching mips16-64] + run_dump_test_arches "mips16-pcrel-absolute-pic-n64-sym32-4" \ + [mips_arch_list_matching mips16-64] + run_dump_test_arches "mips16-pcrel-absolute-pic-n64-sym32-6" \ + [mips_arch_list_matching mips16-64] } run_dump_test "mips16-branch-reloc-0" run_dump_test "mips16-branch-reloc-1" diff --git a/gas/testsuite/gas/mips/mips16-pcrel-1.d b/gas/testsuite/gas/mips/mips16-pcrel-1.d index cad713c71d7..de95cce085d 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-1.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-1.d @@ -1,6 +1,6 @@ #objdump: -dr --prefix-addresses --show-raw-insn #name: MIPS16 PC-relative operations 1 -#as: -32 -mips3 +#as: -32 .*: +file format .*mips.* diff --git a/gas/testsuite/gas/mips/mips16-pcrel-1.l b/gas/testsuite/gas/mips/mips16-pcrel-1.l index 560e1e9c979..c09d692f0e2 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-1.l +++ b/gas/testsuite/gas/mips/mips16-pcrel-1.l @@ -1,5 +1,5 @@ .*: Assembler messages: -.*:25: Error: operand value out of range for instruction -.*:26: Error: operand value out of range for instruction .*:27: Error: operand value out of range for instruction -.*:28: Error: operand value out of range for instruction +.*:30: Error: operand value out of range for instruction +.*:33: Error: operand value out of range for instruction +.*:36: Error: operand value out of range for instruction diff --git a/gas/testsuite/gas/mips/mips16-pcrel-1.s b/gas/testsuite/gas/mips/mips16-pcrel-1.s index a0dfcdbafbf..21043f8a776 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-1.s +++ b/gas/testsuite/gas/mips/mips16-pcrel-1.s @@ -22,10 +22,21 @@ foo: ld $2, . - 5 + 0x7fff dla $2, . - 1 - 0x8000 ld $2, . - 5 - 0x8000 - dla $2, . - 1 + 0x8000 - ld $2, . - 5 + 0x8000 - dla $2, . - 1 - 0x8001 - ld $2, . - 5 - 0x8001 + + # Pad these to retain alignment between MIPS16 and MIPS16e2 code. +0: dla $2, . - 1 + 0x8000 +1: .insn + .fill (12 - (1b - 0b)) / 2, 2, 0x6500 +0: ld $2, . - 5 + 0x8000 +1: .insn + .fill (12 - (1b - 0b)) / 2, 2, 0x6500 +0: dla $2, . - 1 - 0x8001 +1: .insn + .fill (12 - (1b - 0b)) / 2, 2, 0x6500 +0: ld $2, . - 5 - 0x8001 +1: .insn + .fill (12 - (1b - 0b)) / 2, 2, 0x6500 + nop .set nomips16 .end foo diff --git a/gas/testsuite/gas/mips/mips16-pcrel-absolute-2.d b/gas/testsuite/gas/mips/mips16-pcrel-absolute-2.d index b4f568488a9..fac12c05e9b 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-absolute-2.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-absolute-2.d @@ -1,6 +1,6 @@ #objdump: -dr --prefix-addresses --show-raw-insn #name: MIPS16 PC-relative reference to absolute expression 2 -#as: -32 -mips3 +#as: -32 .*: +file format .*mips.* diff --git a/gas/testsuite/gas/mips/mips16-pcrel-absolute-3.d b/gas/testsuite/gas/mips/mips16-pcrel-absolute-3.d index 8ac68fb19ce..72eb4b6bdbb 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-absolute-3.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-absolute-3.d @@ -1,4 +1,4 @@ #objdump: -dr --prefix-addresses --show-raw-insn #name: MIPS16 PC-relative reference to absolute expression 3 -#as: -32 -mips3 +#as: -32 #dump: mips16-pcrel-absolute-2.d diff --git a/gas/testsuite/gas/mips/mips16-pcrel-absolute-6.d b/gas/testsuite/gas/mips/mips16-pcrel-absolute-6.d index bdc73fb25d5..22962fe3647 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-absolute-6.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-absolute-6.d @@ -1,6 +1,6 @@ #objdump: -dr --prefix-addresses --show-raw-insn #name: MIPS16 PC-relative reference to absolute expression 6 -#as: -32 -mips3 +#as: -32 .*: +file format .*mips.* diff --git a/gas/testsuite/gas/mips/mips16-pcrel-absolute-7.d b/gas/testsuite/gas/mips/mips16-pcrel-absolute-7.d index 934767a7627..1bcac1abf1e 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-absolute-7.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-absolute-7.d @@ -1,4 +1,4 @@ #objdump: -dr --prefix-addresses --show-raw-insn #name: MIPS16 PC-relative reference to absolute expression 7 -#as: -32 -mips3 +#as: -32 #dump: mips16-pcrel-absolute-6.d diff --git a/gas/testsuite/gas/mips/mips16-pcrel-absolute-n32-4.d b/gas/testsuite/gas/mips/mips16-pcrel-absolute-n32-4.d index cc5e2e4fe8a..d15fd47f1f1 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-absolute-n32-4.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-absolute-n32-4.d @@ -1,5 +1,5 @@ #objdump: -dr --prefix-addresses --show-raw-insn #name: MIPS16 PC-relative reference to absolute expression 4 (n32) -#as: -n32 -mips3 +#as: -n32 #source: mips16-pcrel-absolute-4.s #dump: mips16-pcrel-absolute-4.d diff --git a/gas/testsuite/gas/mips/mips16-pcrel-absolute-n32-6.d b/gas/testsuite/gas/mips/mips16-pcrel-absolute-n32-6.d index bf49cd516c6..45fb7237c7a 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-absolute-n32-6.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-absolute-n32-6.d @@ -1,5 +1,5 @@ #objdump: -dr --prefix-addresses --show-raw-insn #name: MIPS16 PC-relative reference to absolute expression 6 (n32) -#as: -n32 -mips3 +#as: -n32 #source: mips16-pcrel-absolute-6.s #dump: mips16-pcrel-absolute-6.d diff --git a/gas/testsuite/gas/mips/mips16-pcrel-absolute-n64-4.d b/gas/testsuite/gas/mips/mips16-pcrel-absolute-n64-4.d index 583570e800c..e160527707f 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-absolute-n64-4.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-absolute-n64-4.d @@ -1,4 +1,4 @@ #name: MIPS16 PC-relative reference to absolute expression 4 (n64) -#as: -64 -mips3 +#as: -64 #source: mips16-pcrel-absolute-4.s #error-output: mips16-pcrel-absolute-4.l diff --git a/gas/testsuite/gas/mips/mips16-pcrel-absolute-n64-6.d b/gas/testsuite/gas/mips/mips16-pcrel-absolute-n64-6.d index a618ce9d918..f2e5df2960c 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-absolute-n64-6.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-absolute-n64-6.d @@ -1,4 +1,4 @@ #name: MIPS16 PC-relative reference to absolute expression 6 (n64) -#as: -64 -mips3 +#as: -64 #source: mips16-pcrel-absolute-6.s #error-output: mips16-pcrel-absolute-6.l diff --git a/gas/testsuite/gas/mips/mips16-pcrel-absolute-n64-sym32-4.d b/gas/testsuite/gas/mips/mips16-pcrel-absolute-n64-sym32-4.d index d0e5275d722..fb3c5c3ff69 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-absolute-n64-sym32-4.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-absolute-n64-sym32-4.d @@ -1,5 +1,5 @@ #objdump: -dr --prefix-addresses --show-raw-insn #name: MIPS16 PC-relative reference to absolute expression 4 (n64, sym32) -#as: -64 -msym32 -mips3 +#as: -64 -msym32 #source: mips16-pcrel-absolute-4.s #dump: mips16-pcrel-absolute-4.d diff --git a/gas/testsuite/gas/mips/mips16-pcrel-absolute-n64-sym32-6.d b/gas/testsuite/gas/mips/mips16-pcrel-absolute-n64-sym32-6.d index 6535c5c8174..d354c0cb802 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-absolute-n64-sym32-6.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-absolute-n64-sym32-6.d @@ -1,5 +1,5 @@ #objdump: -dr --prefix-addresses --show-raw-insn #name: MIPS16 PC-relative reference to absolute expression 6 (n64, sym32) -#as: -64 -msym32 -mips3 +#as: -64 -msym32 #source: mips16-pcrel-absolute-6.s #dump: mips16-pcrel-absolute-6.d diff --git a/gas/testsuite/gas/mips/mips16-pcrel-absolute-pic-6.d b/gas/testsuite/gas/mips/mips16-pcrel-absolute-pic-6.d index 01d7313313b..1affdee6642 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-absolute-pic-6.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-absolute-pic-6.d @@ -1,5 +1,5 @@ #objdump: -dr --prefix-addresses --show-raw-insn #name: MIPS16 PC-relative reference to absolute expression 6 (PIC) -#as: -32 -mips3 -call_shared +#as: -32 -call_shared #source: mips16-pcrel-absolute-6.s #dump: mips16-pcrel-absolute-6.d diff --git a/gas/testsuite/gas/mips/mips16-pcrel-absolute-pic-n32-4.d b/gas/testsuite/gas/mips/mips16-pcrel-absolute-pic-n32-4.d index e4aa54cad8a..07ebf7c3e8b 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-absolute-pic-n32-4.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-absolute-pic-n32-4.d @@ -1,5 +1,5 @@ #objdump: -dr --prefix-addresses --show-raw-insn #name: MIPS16 PC-relative reference to absolute expression 4 (PIC, n32) -#as: -n32 -call_shared -mips3 +#as: -n32 -call_shared #source: mips16-pcrel-absolute-4.s #dump: mips16-pcrel-absolute-4.d diff --git a/gas/testsuite/gas/mips/mips16-pcrel-absolute-pic-n32-6.d b/gas/testsuite/gas/mips/mips16-pcrel-absolute-pic-n32-6.d index d8e82086e2b..0305ef245e6 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-absolute-pic-n32-6.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-absolute-pic-n32-6.d @@ -1,5 +1,5 @@ #objdump: -dr --prefix-addresses --show-raw-insn #name: MIPS16 PC-relative reference to absolute expression 6 (PIC, n32) -#as: -n32 -call_shared -mips3 +#as: -n32 -call_shared #source: mips16-pcrel-absolute-6.s #dump: mips16-pcrel-absolute-6.d diff --git a/gas/testsuite/gas/mips/mips16-pcrel-absolute-pic-n64-4.d b/gas/testsuite/gas/mips/mips16-pcrel-absolute-pic-n64-4.d index 679d08252fd..97ebf7d8efe 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-absolute-pic-n64-4.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-absolute-pic-n64-4.d @@ -1,4 +1,4 @@ #name: MIPS16 PC-relative reference to absolute expression 4 (PIC, n64) -#as: -64 -call_shared -mips3 +#as: -64 -call_shared #source: mips16-pcrel-absolute-4.s #error-output: mips16-pcrel-absolute-4.l diff --git a/gas/testsuite/gas/mips/mips16-pcrel-absolute-pic-n64-6.d b/gas/testsuite/gas/mips/mips16-pcrel-absolute-pic-n64-6.d index 6ac2f843617..2d29b1dc44a 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-absolute-pic-n64-6.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-absolute-pic-n64-6.d @@ -1,4 +1,4 @@ #name: MIPS16 PC-relative reference to absolute expression 6 (PIC, n64) -#as: -64 -call_shared -mips3 +#as: -64 -call_shared #source: mips16-pcrel-absolute-6.s #error-output: mips16-pcrel-absolute-6.l diff --git a/gas/testsuite/gas/mips/mips16-pcrel-absolute-pic-n64-sym32-4.d b/gas/testsuite/gas/mips/mips16-pcrel-absolute-pic-n64-sym32-4.d index e60c8ff9328..d1d64bef645 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-absolute-pic-n64-sym32-4.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-absolute-pic-n64-sym32-4.d @@ -1,5 +1,5 @@ #objdump: -dr --prefix-addresses --show-raw-insn #name: MIPS16 PC-relative reference to absolute expression 4 (PIC, n64, sym32) -#as: -64 -msym32 -call_shared -mips3 +#as: -64 -msym32 -call_shared #source: mips16-pcrel-absolute-4.s #dump: mips16-pcrel-absolute-4.d diff --git a/gas/testsuite/gas/mips/mips16-pcrel-absolute-pic-n64-sym32-6.d b/gas/testsuite/gas/mips/mips16-pcrel-absolute-pic-n64-sym32-6.d index 2414bb8aa4c..f223a36c911 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-absolute-pic-n64-sym32-6.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-absolute-pic-n64-sym32-6.d @@ -1,5 +1,5 @@ #objdump: -dr --prefix-addresses --show-raw-insn #name: MIPS16 PC-relative reference to absolute expression 6 (PIC, n64, sym32) -#as: -64 -msym32 -call_shared -mips3 +#as: -64 -msym32 -call_shared #source: mips16-pcrel-absolute-6.s #dump: mips16-pcrel-absolute-6.d diff --git a/gas/testsuite/gas/mips/mips16-pcrel-addend-4.d b/gas/testsuite/gas/mips/mips16-pcrel-addend-4.d index 38ee8f05ec2..e55d0c4ba34 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-addend-4.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-addend-4.d @@ -1,6 +1,6 @@ #objdump: -dr --prefix-addresses --show-raw-insn #name: MIPS16 PC-relative relocation with addend 4 -#as: -32 -mips3 +#as: -32 .*: +file format .*mips.* diff --git a/gas/testsuite/gas/mips/mips16-pcrel-addend-5.d b/gas/testsuite/gas/mips/mips16-pcrel-addend-5.d index 8d6571ae20f..092b2987694 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-addend-5.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-addend-5.d @@ -1,6 +1,6 @@ #objdump: -dr --prefix-addresses --show-raw-insn #name: MIPS16 PC-relative relocation with addend 5 -#as: -32 -mips3 +#as: -32 .*: +file format .*mips.* diff --git a/gas/testsuite/gas/mips/mips16-pcrel-addend-6.d b/gas/testsuite/gas/mips/mips16-pcrel-addend-6.d index 8c03fc183cf..1091e439172 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-addend-6.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-addend-6.d @@ -1,6 +1,6 @@ #objdump: -dr --prefix-addresses --show-raw-insn #name: MIPS16 PC-relative relocation with addend 6 -#as: -32 -mips3 +#as: -32 .*: +file format .*mips.* diff --git a/gas/testsuite/gas/mips/mips16-pcrel-addend-7.d b/gas/testsuite/gas/mips/mips16-pcrel-addend-7.d index 3a753e0c7bf..dabffebb514 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-addend-7.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-addend-7.d @@ -1,6 +1,6 @@ #objdump: -dr --prefix-addresses --show-raw-insn #name: MIPS16 PC-relative relocation with addend 7 -#as: -32 -mips3 +#as: -32 .*: +file format .*mips.* diff --git a/gas/testsuite/gas/mips/mips16-pcrel-addend-9.d b/gas/testsuite/gas/mips/mips16-pcrel-addend-9.d index 646c39d4ded..c6be745ea98 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-addend-9.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-addend-9.d @@ -1,6 +1,6 @@ #objdump: -dr --prefix-addresses --show-raw-insn #name: MIPS16 PC-relative relocation with addend 9 -#as: -32 -mips3 +#as: -32 .*: +file format .*mips.* diff --git a/gas/testsuite/gas/mips/mips16-pcrel-addend-n32-8.d b/gas/testsuite/gas/mips/mips16-pcrel-addend-n32-8.d index 5b2abe9ca96..a85b3de7eea 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-addend-n32-8.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-addend-n32-8.d @@ -1,6 +1,6 @@ #objdump: -dr --prefix-addresses --show-raw-insn #name: MIPS16 PC-relative relocation with addend 8 (n32) -#as: -n32 -mips3 +#as: -n32 #source: mips16-pcrel-addend-8.s .*: +file format .*mips.* diff --git a/gas/testsuite/gas/mips/mips16-pcrel-addend-n32-9.d b/gas/testsuite/gas/mips/mips16-pcrel-addend-n32-9.d index b4931d53421..c7debd3ff93 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-addend-n32-9.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-addend-n32-9.d @@ -1,6 +1,6 @@ #objdump: -dr --prefix-addresses --show-raw-insn #name: MIPS16 PC-relative relocation with addend 9 (n32) -#as: -n32 -mips3 +#as: -n32 #source: mips16-pcrel-addend-9.s .*: +file format .*mips.* diff --git a/gas/testsuite/gas/mips/mips16-pcrel-addend-n64-8.d b/gas/testsuite/gas/mips/mips16-pcrel-addend-n64-8.d index eec9bd2be0e..d43e8f14114 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-addend-n64-8.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-addend-n64-8.d @@ -1,4 +1,4 @@ #name: MIPS16 PC-relative relocation with addend 8 (n64) -#as: -64 -mips3 +#as: -64 #source: mips16-pcrel-addend-8.s #error-output: mips16-pcrel-addend-8.l diff --git a/gas/testsuite/gas/mips/mips16-pcrel-addend-n64-9.d b/gas/testsuite/gas/mips/mips16-pcrel-addend-n64-9.d index 9c8277b725c..11f7257f9d6 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-addend-n64-9.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-addend-n64-9.d @@ -1,4 +1,4 @@ #name: MIPS16 PC-relative relocation with addend 9 (n64) -#as: -64 -mips3 +#as: -64 #source: mips16-pcrel-addend-9.s #error-output: mips16-pcrel-addend-9.l diff --git a/gas/testsuite/gas/mips/mips16-pcrel-addend-n64-sym32-8.d b/gas/testsuite/gas/mips/mips16-pcrel-addend-n64-sym32-8.d index 26e8c3de2b2..f7f7f680505 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-addend-n64-sym32-8.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-addend-n64-sym32-8.d @@ -1,6 +1,6 @@ #objdump: -dr --prefix-addresses --show-raw-insn #name: MIPS16 PC-relative relocation with addend 8 (n64, sym32) -#as: -64 -msym32 -mips3 +#as: -64 -msym32 #source: mips16-pcrel-addend-8.s .*: +file format .*mips.* diff --git a/gas/testsuite/gas/mips/mips16-pcrel-addend-n64-sym32-9.d b/gas/testsuite/gas/mips/mips16-pcrel-addend-n64-sym32-9.d index c8ccbb21c4a..61c191a2384 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-addend-n64-sym32-9.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-addend-n64-sym32-9.d @@ -1,6 +1,6 @@ #objdump: -dr --prefix-addresses --show-raw-insn #name: MIPS16 PC-relative relocation with addend 9 (n64, sym32) -#as: -64 -msym32 -mips3 +#as: -64 -msym32 #source: mips16-pcrel-addend-9.s .*: +file format .*mips.* diff --git a/gas/testsuite/gas/mips/mips16-pcrel-addend-pic-9.d b/gas/testsuite/gas/mips/mips16-pcrel-addend-pic-9.d index cc12b2c2264..53711f0241d 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-addend-pic-9.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-addend-pic-9.d @@ -1,4 +1,4 @@ #name: MIPS16 PC-relative relocation with addend 9 (PIC) -#as: -32 -mips3 -call_shared +#as: -32 -call_shared #source: mips16-pcrel-addend-9.s #error-output: mips16-pcrel-addend-9.l diff --git a/gas/testsuite/gas/mips/mips16-pcrel-n32-0.d b/gas/testsuite/gas/mips/mips16-pcrel-n32-0.d index b009ecfcf62..55e276a7eba 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-n32-0.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-n32-0.d @@ -1,6 +1,6 @@ #objdump: -dr --prefix-addresses --show-raw-insn #name: MIPS16 PC-relative operations 0 (n32) -#as: -n32 -mips3 +#as: -n32 #source: mips16-pcrel-0.s .*: +file format .*mips.* diff --git a/gas/testsuite/gas/mips/mips16-pcrel-n32-1.d b/gas/testsuite/gas/mips/mips16-pcrel-n32-1.d index fcd5a2b0986..8dfb1bcc1cf 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-n32-1.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-n32-1.d @@ -1,6 +1,6 @@ #objdump: -dr --prefix-addresses --show-raw-insn #name: MIPS16 PC-relative operations 1 (n32) -#as: -n32 -mips3 +#as: -n32 #source: mips16-pcrel-1.s .*: +file format .*mips.* diff --git a/gas/testsuite/gas/mips/mips16-pcrel-n64-0.d b/gas/testsuite/gas/mips/mips16-pcrel-n64-0.d index 4ece48f52ef..a45a493ab1f 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-n64-0.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-n64-0.d @@ -1,4 +1,4 @@ #name: MIPS16 PC-relative operations 0 (n64) -#as: -64 -mips3 +#as: -64 #source: mips16-pcrel-0.s #error-output: mips16-pcrel-0.l diff --git a/gas/testsuite/gas/mips/mips16-pcrel-n64-1.d b/gas/testsuite/gas/mips/mips16-pcrel-n64-1.d index 1943362fd92..8ca70a1085e 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-n64-1.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-n64-1.d @@ -1,4 +1,4 @@ #name: MIPS16 PC-relative operations 1 (n64) -#as: -64 -mips3 +#as: -64 #source: mips16-pcrel-1.s #error-output: mips16-pcrel-1.l diff --git a/gas/testsuite/gas/mips/mips16-pcrel-n64-sym32-0.d b/gas/testsuite/gas/mips/mips16-pcrel-n64-sym32-0.d index 9cb2e069157..64c53476156 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-n64-sym32-0.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-n64-sym32-0.d @@ -1,6 +1,6 @@ #objdump: -dr --prefix-addresses --show-raw-insn #name: MIPS16 PC-relative operations 0 (n64, sym32) -#as: -64 -msym32 -mips3 +#as: -64 -msym32 #source: mips16-pcrel-0.s .*: +file format .*mips.* diff --git a/gas/testsuite/gas/mips/mips16-pcrel-n64-sym32-1.d b/gas/testsuite/gas/mips/mips16-pcrel-n64-sym32-1.d index 458ca50e0ea..4832e89669b 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-n64-sym32-1.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-n64-sym32-1.d @@ -1,6 +1,6 @@ #objdump: -dr --prefix-addresses --show-raw-insn #name: MIPS16 PC-relative operations 1 (n64, sym32) -#as: -64 -msym32 -mips3 +#as: -64 -msym32 #source: mips16-pcrel-1.s .*: +file format .*mips.* diff --git a/gas/testsuite/gas/mips/mips16-pcrel-pic-1.d b/gas/testsuite/gas/mips/mips16-pcrel-pic-1.d index b062e3024ec..a4cf559114f 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-pic-1.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-pic-1.d @@ -1,4 +1,4 @@ #name: MIPS16 PC-relative operations 1 (PIC) -#as: -32 -mips3 -call_shared +#as: -32 -call_shared #source: mips16-pcrel-1.s #error-output: mips16-pcrel-1.l diff --git a/gas/testsuite/gas/mips/mips16-pcrel-reloc-4.d b/gas/testsuite/gas/mips/mips16-pcrel-reloc-4.d index 265b1511c11..9d4ba468a14 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-reloc-4.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-reloc-4.d @@ -1,6 +1,6 @@ #objdump: -dr --prefix-addresses --show-raw-insn #name: MIPS16 PC-relative relocation 4 -#as: -32 -mips3 +#as: -32 .*: +file format .*mips.* diff --git a/gas/testsuite/gas/mips/mips16-pcrel-reloc-5.d b/gas/testsuite/gas/mips/mips16-pcrel-reloc-5.d index 9ca33027353..6567b57e056 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-reloc-5.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-reloc-5.d @@ -1,6 +1,6 @@ #objdump: -dr --prefix-addresses --show-raw-insn #name: MIPS16 PC-relative relocation 5 -#as: -32 -mips3 +#as: -32 .*: +file format .*mips.* diff --git a/gas/testsuite/gas/mips/mips16-pcrel-reloc-6.d b/gas/testsuite/gas/mips/mips16-pcrel-reloc-6.d index 3a28f3cd02c..3ebc270f54a 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-reloc-6.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-reloc-6.d @@ -1,6 +1,6 @@ #objdump: -dr --prefix-addresses --show-raw-insn #name: MIPS16 PC-relative relocation 6 -#as: -32 -mips3 +#as: -32 .*: +file format .*mips.* diff --git a/gas/testsuite/gas/mips/mips16-pcrel-reloc-7.d b/gas/testsuite/gas/mips/mips16-pcrel-reloc-7.d index 0564be10cf4..ef266d23fa8 100644 --- a/gas/testsuite/gas/mips/mips16-pcrel-reloc-7.d +++ b/gas/testsuite/gas/mips/mips16-pcrel-reloc-7.d @@ -1,6 +1,6 @@ #objdump: -dr --prefix-addresses --show-raw-insn #name: MIPS16 PC-relative relocation 7 -#as: -32 -mips3 +#as: -32 .*: +file format .*mips.* diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-0.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-0.d new file mode 100644 index 00000000000..1b43d4ce1b6 --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-0.d @@ -0,0 +1,44 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative operations 0 +#as: -32 +#source: mips16-pcrel-0.s + +.*: +file format .*mips.* + +Disassembly of section \.text: + \.\.\. +[0-9a-f]+ <[^>]*> 0a00 la v0,00010000 +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> b200 lw v0,00010004 +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> 0aff la v0,00010404 +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> b2ff lw v0,00010408 +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> f400 0a00 la v0,00010410 +[0-9a-f]+ <[^>]*> f400 b200 lw v0,00010414 +[0-9a-f]+ <[^>]*> f7ff 0a1c la v0,00010014 +[0-9a-f]+ <[^>]*> f7ff b21c lw v0,00010018 +[0-9a-f]+ <[^>]*> f7ef 0a1f la v0,0001801f +[0-9a-f]+ <[^>]*> f7ef b21f lw v0,00018023 +[0-9a-f]+ <[^>]*> f010 0a00 la v0,00008028 +[0-9a-f]+ <[^>]*> f010 b200 lw v0,0000802c +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 L0\001 +[0-9a-f]+ <[^>]*> f7ef 4a1f addiu v0,32767 +[ ]*[0-9a-f]+: R_MIPS16_LO16 L0\001 +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 L0\001 +[0-9a-f]+ <[^>]*> f7ef 9a5f lw v0,32767\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 L0\001 +[0-9a-f]+ <[^>]*> f7ff 6a3f lui v0,0xffff +[ ]*[0-9a-f]+: R_MIPS16_HI16 L0\001 +[0-9a-f]+ <[^>]*> f7ef 4a1e addiu v0,32766 +[ ]*[0-9a-f]+: R_MIPS16_LO16 L0\001 +[0-9a-f]+ <[^>]*> f7ff 6a3f lui v0,0xffff +[ ]*[0-9a-f]+: R_MIPS16_HI16 L0\001 +[0-9a-f]+ <[^>]*> f7ef 9a5e lw v0,32766\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 L0\001 +[0-9a-f]+ <[^>]*> 6500 nop + \.\.\. + \.\.\. diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-1.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-1.d new file mode 100644 index 00000000000..c1d100c410c --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-1.d @@ -0,0 +1,52 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative operations 1 +#as: -32 +#source: mips16-pcrel-1.s + +.*: +file format .*mips.* + +Disassembly of section \.text: + \.\.\. +[0-9a-f]+ <[^>]*> fe40 dla v0,00010000 +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> fc40 ld v0,00010000 +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> fe5f dla v0,00010084 +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> fc5f ld v0,00010100 +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> f080 fe40 dla v0,00010090 +[0-9a-f]+ <[^>]*> f100 fc40 ld v0,00010110 +[0-9a-f]+ <[^>]*> f7ff fe5c dla v0,00010014 +[0-9a-f]+ <[^>]*> f7ff fc5c ld v0,00010014 +[0-9a-f]+ <[^>]*> f7ef fe5f dla v0,0001801f +[0-9a-f]+ <[^>]*> f7ef fc5f ld v0,0001801f +[0-9a-f]+ <[^>]*> f010 fe40 dla v0,00008028 +[0-9a-f]+ <[^>]*> f010 fc40 ld v0,00008028 +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 L0\001 +[0-9a-f]+ <[^>]*> f7ef fd5f daddiu v0,32767 +[ ]*[0-9a-f]+: R_MIPS16_LO16 L0\001 +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 L0\001 +[0-9a-f]+ <[^>]*> f7ef 3a5b ld v0,32763\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 L0\001 +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> f7ff 6a3f lui v0,0xffff +[ ]*[0-9a-f]+: R_MIPS16_HI16 L0\001 +[0-9a-f]+ <[^>]*> f7ef fd5e daddiu v0,32766 +[ ]*[0-9a-f]+: R_MIPS16_LO16 L0\001 +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> f7ff 6a3f lui v0,0xffff +[ ]*[0-9a-f]+: R_MIPS16_HI16 L0\001 +[0-9a-f]+ <[^>]*> f7ef 3a5a ld v0,32762\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 L0\001 +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> 6500 nop + \.\.\. + \.\.\. diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-2.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-2.d new file mode 100644 index 00000000000..c8840da86f6 --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-2.d @@ -0,0 +1,6 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative operations 2 +#as: -32 +#stderr: mips16-pcrel-2.l +#source: mips16-pcrel-2.s +#dump: mips16e2@mips16-pcrel-0.d diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-1.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-1.d new file mode 100644 index 00000000000..725ff14eb27 --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-1.d @@ -0,0 +1,5 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative reference to absolute expression 1 +#as: -32 +#source: mips16-pcrel-absolute.s +#dump: mips16e2@mips16-pcrel-absolute.d diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-2.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-2.d new file mode 100644 index 00000000000..fadd93fa8fd --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-2.d @@ -0,0 +1,15 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative reference to absolute expression 2 +#as: -32 +#source: mips16-pcrel-absolute-2.s + +.*: +file format .*mips.* + +Disassembly of section \.text: + \.\.\. +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[0-9a-f]+ <[^>]*> f222 fd54 daddiu v0,4660 +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[0-9a-f]+ <[^>]*> f222 3a54 ld v0,4660\(v0\) +[0-9a-f]+ <[^>]*> 6500 nop + \.\.\. diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-3.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-3.d new file mode 100644 index 00000000000..0328f12b5ac --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-3.d @@ -0,0 +1,5 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative reference to absolute expression 3 +#as: -32 +#source: mips16-pcrel-absolute-3.s +#dump: mips16e2@mips16-pcrel-absolute-2.d diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-4.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-4.d new file mode 100644 index 00000000000..172069761f8 --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-4.d @@ -0,0 +1,27 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative reference to absolute expression 4 +#as: -32 +#source: mips16-pcrel-absolute-4.s + +.*: +file format .*mips.* + +Disassembly of section \.text: + \.\.\. +[0-9a-f]+ <[^>]*> f222 6a34 lui v0,0x1234 +[0-9a-f]+ <[^>]*> f66a 4a18 addiu v0,22136 +[0-9a-f]+ <[^>]*> f222 6a34 lui v0,0x1234 +[0-9a-f]+ <[^>]*> f66a 9a58 lw v0,22136\(v0\) +[0-9a-f]+ <[^>]*> f222 6a34 lui v0,0x1234 +[0-9a-f]+ <[^>]*> f66a 4a18 addiu v0,22136 +[0-9a-f]+ <[^>]*> f222 6a34 lui v0,0x1234 +[0-9a-f]+ <[^>]*> f66a 9a58 lw v0,22136\(v0\) +[0-9a-f]+ <[^>]*> f222 6a34 lui v0,0x1234 +[0-9a-f]+ <[^>]*> f2ef 4a00 addiu v0,31456 +[0-9a-f]+ <[^>]*> f222 6a34 lui v0,0x1234 +[0-9a-f]+ <[^>]*> f2ef 9a40 lw v0,31456\(v0\) +[0-9a-f]+ <[^>]*> f464 6a29 lui v0,0x2469 +[0-9a-f]+ <[^>]*> f4f5 4a00 addiu v0,-21280 +[0-9a-f]+ <[^>]*> f464 6a29 lui v0,0x2469 +[0-9a-f]+ <[^>]*> f4f5 9a40 lw v0,-21280\(v0\) +[0-9a-f]+ <[^>]*> 6500 nop + \.\.\. diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-5.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-5.d new file mode 100644 index 00000000000..099ae75e8f9 --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-5.d @@ -0,0 +1,5 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative reference to absolute expression 5 +#as: -32 +#source: mips16-pcrel-absolute-5.s +#dump: mips16e2@mips16-pcrel-absolute-4.d diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-6.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-6.d new file mode 100644 index 00000000000..30e6aabd94c --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-6.d @@ -0,0 +1,27 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative reference to absolute expression 6 +#as: -32 +#source: mips16-pcrel-absolute-6.s + +.*: +file format .*mips.* + +Disassembly of section \.text: + \.\.\. +[0-9a-f]+ <[^>]*> f222 6a34 lui v0,0x1234 +[0-9a-f]+ <[^>]*> f66a fd58 daddiu v0,22136 +[0-9a-f]+ <[^>]*> f222 6a34 lui v0,0x1234 +[0-9a-f]+ <[^>]*> f66a 3a58 ld v0,22136\(v0\) +[0-9a-f]+ <[^>]*> f222 6a34 lui v0,0x1234 +[0-9a-f]+ <[^>]*> f66a fd58 daddiu v0,22136 +[0-9a-f]+ <[^>]*> f222 6a34 lui v0,0x1234 +[0-9a-f]+ <[^>]*> f66a 3a58 ld v0,22136\(v0\) +[0-9a-f]+ <[^>]*> f222 6a34 lui v0,0x1234 +[0-9a-f]+ <[^>]*> f2ef fd40 daddiu v0,31456 +[0-9a-f]+ <[^>]*> f222 6a34 lui v0,0x1234 +[0-9a-f]+ <[^>]*> f2ef 3a40 ld v0,31456\(v0\) +[0-9a-f]+ <[^>]*> f464 6a29 lui v0,0x2469 +[0-9a-f]+ <[^>]*> f4f5 fd40 daddiu v0,-21280 +[0-9a-f]+ <[^>]*> f464 6a29 lui v0,0x2469 +[0-9a-f]+ <[^>]*> f4f5 3a40 ld v0,-21280\(v0\) +[0-9a-f]+ <[^>]*> 6500 nop + \.\.\. diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-7.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-7.d new file mode 100644 index 00000000000..560c28e4810 --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-7.d @@ -0,0 +1,5 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative reference to absolute expression 7 +#as: -32 +#source: mips16-pcrel-absolute-7.s +#dump: mips16e2@mips16-pcrel-absolute-6.d diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-n32-4.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-n32-4.d new file mode 100644 index 00000000000..cafacd0a672 --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-n32-4.d @@ -0,0 +1,5 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative reference to absolute expression 4 (n32) +#as: -n32 +#source: mips16-pcrel-absolute-4.s +#dump: mips16e2@mips16-pcrel-absolute-4.d diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-n32-6.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-n32-6.d new file mode 100644 index 00000000000..5182d5d996e --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-n32-6.d @@ -0,0 +1,5 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative reference to absolute expression 6 (n32) +#as: -n32 +#source: mips16-pcrel-absolute-6.s +#dump: mips16e2@mips16-pcrel-absolute-6.d diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-n64-sym32-4.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-n64-sym32-4.d new file mode 100644 index 00000000000..8554c6c300e --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-n64-sym32-4.d @@ -0,0 +1,5 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative reference to absolute expression 4 (n64, sym32) +#as: -64 -msym32 +#source: mips16-pcrel-absolute-4.s +#dump: mips16e2@mips16-pcrel-absolute-4.d diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-n64-sym32-6.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-n64-sym32-6.d new file mode 100644 index 00000000000..8058cd4b2aa --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-n64-sym32-6.d @@ -0,0 +1,5 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative reference to absolute expression 6 (n64, sym32) +#as: -64 -msym32 +#source: mips16-pcrel-absolute-6.s +#dump: mips16e2@mips16-pcrel-absolute-6.d diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-pic-4.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-pic-4.d new file mode 100644 index 00000000000..8f74eb444c5 --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-pic-4.d @@ -0,0 +1,5 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative reference to absolute expression 4 (PIC) +#as: -32 -call_shared +#source: mips16-pcrel-absolute-4.s +#dump: mips16e2@mips16-pcrel-absolute-4.d diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-pic-6.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-pic-6.d new file mode 100644 index 00000000000..4d05540edac --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-pic-6.d @@ -0,0 +1,5 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative reference to absolute expression 6 (PIC) +#as: -32 -call_shared +#source: mips16-pcrel-absolute-6.s +#dump: mips16e2@mips16-pcrel-absolute-6.d diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-pic-n32-4.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-pic-n32-4.d new file mode 100644 index 00000000000..338435fef9f --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-pic-n32-4.d @@ -0,0 +1,5 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative reference to absolute expression 4 (PIC, n32) +#as: -n32 -call_shared +#source: mips16-pcrel-absolute-4.s +#dump: mips16e2@mips16-pcrel-absolute-4.d diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-pic-n32-6.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-pic-n32-6.d new file mode 100644 index 00000000000..b958ce28035 --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-pic-n32-6.d @@ -0,0 +1,5 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative reference to absolute expression 6 (PIC, n32) +#as: -n32 -call_shared +#source: mips16-pcrel-absolute-6.s +#dump: mips16e2@mips16-pcrel-absolute-6.d diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-pic-n64-sym32-4.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-pic-n64-sym32-4.d new file mode 100644 index 00000000000..17dcab5db57 --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-pic-n64-sym32-4.d @@ -0,0 +1,5 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative reference to absolute expression 4 (PIC, n64, sym32) +#as: -64 -msym32 -call_shared +#source: mips16-pcrel-absolute-4.s +#dump: mips16e2@mips16-pcrel-absolute-4.d diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-pic-n64-sym32-6.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-pic-n64-sym32-6.d new file mode 100644 index 00000000000..ebf56f54534 --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute-pic-n64-sym32-6.d @@ -0,0 +1,5 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative reference to absolute expression 6 (PIC, n64, sym32) +#as: -64 -msym32 -call_shared +#source: mips16-pcrel-absolute-6.s +#dump: mips16e2@mips16-pcrel-absolute-6.d diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute.d new file mode 100644 index 00000000000..9ec4eb41545 --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-absolute.d @@ -0,0 +1,15 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative reference to absolute expression +#as: -32 +#source: mips16-pcrel-absolute.s + +.*: +file format .*mips.* + +Disassembly of section \.text: + \.\.\. +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[0-9a-f]+ <[^>]*> f222 4a14 addiu v0,4660 +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[0-9a-f]+ <[^>]*> f222 9a54 lw v0,4660\(v0\) +[0-9a-f]+ <[^>]*> 6500 nop + \.\.\. diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-addend-2.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-addend-2.d new file mode 100644 index 00000000000..43a035fe04e --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-addend-2.d @@ -0,0 +1,20 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative relocation with addend 2 +#as: -32 +#source: mips16-pcrel-addend-2.s + +.*: +file format .*mips.* + +Disassembly of section \.text: + \.\.\. +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar +[0-9a-f]+ <[^>]*> f222 4a14 addiu v0,4660 +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar +[0-9a-f]+ <[^>]*> f222 9a54 lw v0,4660\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar +[0-9a-f]+ <[^>]*> 6500 nop + \.\.\. + \.\.\. diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-addend-3.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-addend-3.d new file mode 100644 index 00000000000..cf18f41a061 --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-addend-3.d @@ -0,0 +1,19 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative relocation with addend 3 +#as: -32 +#source: mips16-pcrel-addend-3.s + +.*: +file format .*mips.* + +Disassembly of section \.text: + \.\.\. +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar +[0-9a-f]+ <[^>]*> f222 4a14 addiu v0,4660 +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar +[0-9a-f]+ <[^>]*> f222 9a54 lw v0,4660\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar +[0-9a-f]+ <[^>]*> 6500 nop + \.\.\. diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-addend-6.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-addend-6.d new file mode 100644 index 00000000000..bf4f8f64640 --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-addend-6.d @@ -0,0 +1,20 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative relocation with addend 6 +#as: -32 +#source: mips16-pcrel-addend-6.s + +.*: +file format .*mips.* + +Disassembly of section \.text: + \.\.\. +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar +[0-9a-f]+ <[^>]*> f222 fd54 daddiu v0,4660 +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar +[0-9a-f]+ <[^>]*> f222 3a54 ld v0,4660\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar +[0-9a-f]+ <[^>]*> 6500 nop + \.\.\. + \.\.\. diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-addend-7.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-addend-7.d new file mode 100644 index 00000000000..c41ec3ecfac --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-addend-7.d @@ -0,0 +1,19 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative relocation with addend 7 +#as: -32 +#source: mips16-pcrel-addend-7.s + +.*: +file format .*mips.* + +Disassembly of section \.text: + \.\.\. +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar +[0-9a-f]+ <[^>]*> f222 fd54 daddiu v0,4660 +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar +[0-9a-f]+ <[^>]*> f222 3a54 ld v0,4660\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar +[0-9a-f]+ <[^>]*> 6500 nop + \.\.\. diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-addend-8.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-addend-8.d new file mode 100644 index 00000000000..cd397a0d8e3 --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-addend-8.d @@ -0,0 +1,43 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative relocation with addend 8 +#as: -32 +#source: mips16-pcrel-addend-8.s + +.*: +file format .*mips.* + +Disassembly of section \.text: + \.\.\. +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar +[0-9a-f]+ <[^>]*> f000 4a00 addiu v0,0 +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar +[0-9a-f]+ <[^>]*> f000 9a40 lw v0,0\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar +[0-9a-f]+ <[^>]*> f464 4a08 addiu v0,9320 +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar +[0-9a-f]+ <[^>]*> f464 9a48 lw v0,9320\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar +[0-9a-f]+ <[^>]*> f222 6a34 lui v0,0x1234 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar +[0-9a-f]+ <[^>]*> f66a 4a18 addiu v0,22136 +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar +[0-9a-f]+ <[^>]*> f222 6a34 lui v0,0x1234 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar +[0-9a-f]+ <[^>]*> f66a 9a58 lw v0,22136\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar +[0-9a-f]+ <[^>]*> f464 6a29 lui v0,0x2469 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar +[0-9a-f]+ <[^>]*> f4f5 4a00 addiu v0,-21280 +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar +[0-9a-f]+ <[^>]*> f464 6a29 lui v0,0x2469 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar +[0-9a-f]+ <[^>]*> f4f5 9a40 lw v0,-21280\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar +[0-9a-f]+ <[^>]*> 6500 nop + \.\.\. diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-addend-9.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-addend-9.d new file mode 100644 index 00000000000..10247cb8e66 --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-addend-9.d @@ -0,0 +1,43 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative relocation with addend 9 +#as: -32 +#source: mips16-pcrel-addend-9.s + +.*: +file format .*mips.* + +Disassembly of section \.text: + \.\.\. +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar +[0-9a-f]+ <[^>]*> f000 fd40 daddiu v0,0 +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar +[0-9a-f]+ <[^>]*> f000 3a40 ld v0,0\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar +[0-9a-f]+ <[^>]*> f464 fd48 daddiu v0,9320 +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar +[0-9a-f]+ <[^>]*> f464 3a48 ld v0,9320\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar +[0-9a-f]+ <[^>]*> f222 6a34 lui v0,0x1234 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar +[0-9a-f]+ <[^>]*> f66a fd58 daddiu v0,22136 +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar +[0-9a-f]+ <[^>]*> f222 6a34 lui v0,0x1234 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar +[0-9a-f]+ <[^>]*> f66a 3a58 ld v0,22136\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar +[0-9a-f]+ <[^>]*> f464 6a29 lui v0,0x2469 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar +[0-9a-f]+ <[^>]*> f4f5 fd40 daddiu v0,-21280 +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar +[0-9a-f]+ <[^>]*> f464 6a29 lui v0,0x2469 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar +[0-9a-f]+ <[^>]*> f4f5 3a40 ld v0,-21280\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar +[0-9a-f]+ <[^>]*> 6500 nop + \.\.\. diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-addend-n32-8.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-addend-n32-8.d new file mode 100644 index 00000000000..6efebba6393 --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-addend-n32-8.d @@ -0,0 +1,43 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative relocation with addend 8 (n32) +#as: -n32 +#source: mips16-pcrel-addend-8.s + +.*: +file format .*mips.* + +Disassembly of section \.text: + \.\.\. +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar +[0-9a-f]+ <[^>]*> f000 4a00 addiu v0,0 +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar +[0-9a-f]+ <[^>]*> f000 9a40 lw v0,0\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar\+0x2468 +[0-9a-f]+ <[^>]*> f000 4a00 addiu v0,0 +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar\+0x2468 +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar\+0x2468 +[0-9a-f]+ <[^>]*> f000 9a40 lw v0,0\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar\+0x2468 +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar\+0x12345678 +[0-9a-f]+ <[^>]*> f000 4a00 addiu v0,0 +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar\+0x12345678 +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar\+0x12345678 +[0-9a-f]+ <[^>]*> f000 9a40 lw v0,0\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar\+0x12345678 +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar\+0x2468ace0 +[0-9a-f]+ <[^>]*> f000 4a00 addiu v0,0 +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar\+0x2468ace0 +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar\+0x2468ace0 +[0-9a-f]+ <[^>]*> f000 9a40 lw v0,0\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar\+0x2468ace0 +[0-9a-f]+ <[^>]*> 6500 nop + \.\.\. diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-addend-n32-9.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-addend-n32-9.d new file mode 100644 index 00000000000..7754501e922 --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-addend-n32-9.d @@ -0,0 +1,43 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative relocation with addend 9 (n32) +#as: -n32 +#source: mips16-pcrel-addend-9.s + +.*: +file format .*mips.* + +Disassembly of section \.text: + \.\.\. +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar +[0-9a-f]+ <[^>]*> f000 fd40 daddiu v0,0 +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar +[0-9a-f]+ <[^>]*> f000 3a40 ld v0,0\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar\+0x2468 +[0-9a-f]+ <[^>]*> f000 fd40 daddiu v0,0 +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar\+0x2468 +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar\+0x2468 +[0-9a-f]+ <[^>]*> f000 3a40 ld v0,0\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar\+0x2468 +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar\+0x12345678 +[0-9a-f]+ <[^>]*> f000 fd40 daddiu v0,0 +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar\+0x12345678 +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar\+0x12345678 +[0-9a-f]+ <[^>]*> f000 3a40 ld v0,0\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar\+0x12345678 +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar\+0x2468ace0 +[0-9a-f]+ <[^>]*> f000 fd40 daddiu v0,0 +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar\+0x2468ace0 +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar\+0x2468ace0 +[0-9a-f]+ <[^>]*> f000 3a40 ld v0,0\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar\+0x2468ace0 +[0-9a-f]+ <[^>]*> 6500 nop + \.\.\. diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-addend-n64-sym32-8.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-addend-n64-sym32-8.d new file mode 100644 index 00000000000..c5dd5def80d --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-addend-n64-sym32-8.d @@ -0,0 +1,75 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative relocation with addend 8 (n64, sym32) +#as: -64 -msym32 +#source: mips16-pcrel-addend-8.s + +.*: +file format .*mips.* + +Disassembly of section \.text: + \.\.\. +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\* +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\* +[0-9a-f]+ <[^>]*> f000 4a00 addiu v0,0 +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\* +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\* +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\* +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\* +[0-9a-f]+ <[^>]*> f000 9a40 lw v0,0\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\* +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\* +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar\+0x2468 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x2468 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x2468 +[0-9a-f]+ <[^>]*> f000 4a00 addiu v0,0 +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar\+0x2468 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x2468 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x2468 +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar\+0x2468 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x2468 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x2468 +[0-9a-f]+ <[^>]*> f000 9a40 lw v0,0\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar\+0x2468 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x2468 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x2468 +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar\+0x12345678 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x12345678 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x12345678 +[0-9a-f]+ <[^>]*> f000 4a00 addiu v0,0 +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar\+0x12345678 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x12345678 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x12345678 +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar\+0x12345678 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x12345678 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x12345678 +[0-9a-f]+ <[^>]*> f000 9a40 lw v0,0\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar\+0x12345678 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x12345678 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x12345678 +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar\+0x2468ace0 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x2468ace0 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x2468ace0 +[0-9a-f]+ <[^>]*> f000 4a00 addiu v0,0 +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar\+0x2468ace0 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x2468ace0 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x2468ace0 +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar\+0x2468ace0 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x2468ace0 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x2468ace0 +[0-9a-f]+ <[^>]*> f000 9a40 lw v0,0\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar\+0x2468ace0 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x2468ace0 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x2468ace0 +[0-9a-f]+ <[^>]*> 6500 nop + \.\.\. diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-addend-n64-sym32-9.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-addend-n64-sym32-9.d new file mode 100644 index 00000000000..a506745f282 --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-addend-n64-sym32-9.d @@ -0,0 +1,75 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative relocation with addend 9 (n64, sym32) +#as: -64 -msym32 +#source: mips16-pcrel-addend-9.s + +.*: +file format .*mips.* + +Disassembly of section \.text: + \.\.\. +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\* +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\* +[0-9a-f]+ <[^>]*> f000 fd40 daddiu v0,0 +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\* +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\* +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\* +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\* +[0-9a-f]+ <[^>]*> f000 3a40 ld v0,0\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\* +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\* +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar\+0x2468 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x2468 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x2468 +[0-9a-f]+ <[^>]*> f000 fd40 daddiu v0,0 +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar\+0x2468 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x2468 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x2468 +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar\+0x2468 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x2468 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x2468 +[0-9a-f]+ <[^>]*> f000 3a40 ld v0,0\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar\+0x2468 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x2468 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x2468 +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar\+0x12345678 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x12345678 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x12345678 +[0-9a-f]+ <[^>]*> f000 fd40 daddiu v0,0 +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar\+0x12345678 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x12345678 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x12345678 +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar\+0x12345678 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x12345678 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x12345678 +[0-9a-f]+ <[^>]*> f000 3a40 ld v0,0\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar\+0x12345678 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x12345678 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x12345678 +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar\+0x2468ace0 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x2468ace0 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x2468ace0 +[0-9a-f]+ <[^>]*> f000 fd40 daddiu v0,0 +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar\+0x2468ace0 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x2468ace0 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x2468ace0 +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar\+0x2468ace0 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x2468ace0 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x2468ace0 +[0-9a-f]+ <[^>]*> f000 3a40 ld v0,0\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar\+0x2468ace0 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x2468ace0 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x2468ace0 +[0-9a-f]+ <[^>]*> 6500 nop + \.\.\. diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-delay-0.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-delay-0.d new file mode 100644 index 00000000000..3acce263248 --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-delay-0.d @@ -0,0 +1,34 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative operation in delay slot 0 +#as: -32 +#stderr: mips16-pcrel-delay-0.l +#source: mips16-pcrel-delay-0.s + +.*: +file format .*mips.* + +Disassembly of section \.text: + \.\.\. +[0-9a-f]+ <[^>]*> ec00 jr a0 +[0-9a-f]+ <[^>]*> 0aff la v0,000103fc +[0-9a-f]+ <[^>]*> e820 jr ra +[0-9a-f]+ <[^>]*> b2ff lw v0,00010400 +[0-9a-f]+ <[^>]*> ec00 jr a0 +[0-9a-f]+ <[^>]*> f7ef 0a1f la v0,00018007 +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> e820 jr ra +[0-9a-f]+ <[^>]*> f7ef b21f lw v0,0001800f +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> ec00 jr a0 +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 L0\001 +[0-9a-f]+ <[^>]*> f7ef 4a1d addiu v0,32765 +[ ]*[0-9a-f]+: R_MIPS16_LO16 L0\001 +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> e820 jr ra +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 L0\001 +[0-9a-f]+ <[^>]*> f7ef 9a5d lw v0,32765\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 L0\001 +[0-9a-f]+ <[^>]*> 6500 nop + \.\.\. + \.\.\. diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-delay-1.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-delay-1.d new file mode 100644 index 00000000000..5c66a379d85 --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-delay-1.d @@ -0,0 +1,39 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative operation in delay slot 1 +#as: -32 +#stderr: mips16-pcrel-delay-1.l +#source: mips16-pcrel-delay-1.s + +.*: +file format .*mips.* + +Disassembly of section \.text: + \.\.\. +[0-9a-f]+ <[^>]*> 1800 0000 jal 00000000 +[ ]*[0-9a-f]+: R_MIPS16_26 bat +[0-9a-f]+ <[^>]*> 0aff la v0,000103fc +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> 1c00 0000 jalx 00000000 +[ ]*[0-9a-f]+: R_MIPS16_26 bax +[0-9a-f]+ <[^>]*> b2ff lw v0,00010404 +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> 1800 0000 jal 00000000 +[ ]*[0-9a-f]+: R_MIPS16_26 bat +[0-9a-f]+ <[^>]*> f7ef 0a1f la v0,00018013 +[0-9a-f]+ <[^>]*> 1c00 0000 jalx 00000000 +[ ]*[0-9a-f]+: R_MIPS16_26 bax +[0-9a-f]+ <[^>]*> f7ef b21f lw v0,0001801b +[0-9a-f]+ <[^>]*> 1800 0000 jal 00000000 +[ ]*[0-9a-f]+: R_MIPS16_26 bat +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 L0\001 +[0-9a-f]+ <[^>]*> f7ef 4a1b addiu v0,32763 +[ ]*[0-9a-f]+: R_MIPS16_LO16 L0\001 +[0-9a-f]+ <[^>]*> 1c00 0000 jalx 00000000 +[ ]*[0-9a-f]+: R_MIPS16_26 bax +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 L0\001 +[0-9a-f]+ <[^>]*> f7ef 9a5b lw v0,32763\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 L0\001 +[0-9a-f]+ <[^>]*> 6500 nop + \.\.\. + \.\.\. diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-n32-0.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-n32-0.d new file mode 100644 index 00000000000..90fafafc924 --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-n32-0.d @@ -0,0 +1,44 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative operations 0 (n32) +#as: -n32 +#source: mips16-pcrel-0.s + +.*: +file format .*mips.* + +Disassembly of section \.text: + \.\.\. +[0-9a-f]+ <[^>]*> 0a00 la v0,00010000 +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> b200 lw v0,00010004 +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> 0aff la v0,00010404 +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> b2ff lw v0,00010408 +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> f400 0a00 la v0,00010410 +[0-9a-f]+ <[^>]*> f400 b200 lw v0,00010414 +[0-9a-f]+ <[^>]*> f7ff 0a1c la v0,00010014 +[0-9a-f]+ <[^>]*> f7ff b21c lw v0,00010018 +[0-9a-f]+ <[^>]*> f7ef 0a1f la v0,0001801f +[0-9a-f]+ <[^>]*> f7ef b21f lw v0,00018023 +[0-9a-f]+ <[^>]*> f010 0a00 la v0,00008028 +[0-9a-f]+ <[^>]*> f010 b200 lw v0,0000802c +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 L0\001\+0x7fff +[0-9a-f]+ <[^>]*> f000 4a00 addiu v0,0 +[ ]*[0-9a-f]+: R_MIPS16_LO16 L0\001\+0x7fff +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 L0\001\+0x7fff +[0-9a-f]+ <[^>]*> f000 9a40 lw v0,0\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 L0\001\+0x7fff +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 L0\001-0x8002 +[0-9a-f]+ <[^>]*> f000 4a00 addiu v0,0 +[ ]*[0-9a-f]+: R_MIPS16_LO16 L0\001-0x8002 +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 L0\001-0x8002 +[0-9a-f]+ <[^>]*> f000 9a40 lw v0,0\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 L0\001-0x8002 +[0-9a-f]+ <[^>]*> 6500 nop + \.\.\. + \.\.\. diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-n32-1.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-n32-1.d new file mode 100644 index 00000000000..18def726e84 --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-n32-1.d @@ -0,0 +1,52 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative operations 1 (n32) +#as: -n32 +#source: mips16-pcrel-1.s + +.*: +file format .*mips.* + +Disassembly of section \.text: + \.\.\. +[0-9a-f]+ <[^>]*> fe40 dla v0,00010000 +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> fc40 ld v0,00010000 +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> fe5f dla v0,00010084 +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> fc5f ld v0,00010100 +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> f080 fe40 dla v0,00010090 +[0-9a-f]+ <[^>]*> f100 fc40 ld v0,00010110 +[0-9a-f]+ <[^>]*> f7ff fe5c dla v0,00010014 +[0-9a-f]+ <[^>]*> f7ff fc5c ld v0,00010014 +[0-9a-f]+ <[^>]*> f7ef fe5f dla v0,0001801f +[0-9a-f]+ <[^>]*> f7ef fc5f ld v0,0001801f +[0-9a-f]+ <[^>]*> f010 fe40 dla v0,00008028 +[0-9a-f]+ <[^>]*> f010 fc40 ld v0,00008028 +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 L0\001\+0x7fff +[0-9a-f]+ <[^>]*> f000 fd40 daddiu v0,0 +[ ]*[0-9a-f]+: R_MIPS16_LO16 L0\001\+0x7fff +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 L0\001\+0x7ffb +[0-9a-f]+ <[^>]*> f000 3a40 ld v0,0\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 L0\001\+0x7ffb +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 L0\001-0x8002 +[0-9a-f]+ <[^>]*> f000 fd40 daddiu v0,0 +[ ]*[0-9a-f]+: R_MIPS16_LO16 L0\001-0x8002 +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 L0\001-0x8006 +[0-9a-f]+ <[^>]*> f000 3a40 ld v0,0\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 L0\001-0x8006 +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> 6500 nop + \.\.\. + \.\.\. diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-n64-sym32-0.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-n64-sym32-0.d new file mode 100644 index 00000000000..4de150ca318 --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-n64-sym32-0.d @@ -0,0 +1,60 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative operations 0 (n64, sym32) +#as: -64 -msym32 +#source: mips16-pcrel-0.s + +.*: +file format .*mips.* + +Disassembly of section \.text: + \.\.\. +[0-9a-f]+ <[^>]*> 0a00 la v0,0000000000010000 +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> b200 lw v0,0000000000010004 +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> 0aff la v0,0000000000010404 +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> b2ff lw v0,0000000000010408 +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> f400 0a00 la v0,0000000000010410 +[0-9a-f]+ <[^>]*> f400 b200 lw v0,0000000000010414 +[0-9a-f]+ <[^>]*> f7ff 0a1c la v0,0000000000010014 +[0-9a-f]+ <[^>]*> f7ff b21c lw v0,0000000000010018 +[0-9a-f]+ <[^>]*> f7ef 0a1f la v0,000000000001801f +[0-9a-f]+ <[^>]*> f7ef b21f lw v0,0000000000018023 +[0-9a-f]+ <[^>]*> f010 0a00 la v0,0000000000008028 +[0-9a-f]+ <[^>]*> f010 b200 lw v0,000000000000802c +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 L0\001\+0x7fff +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x7fff +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x7fff +[0-9a-f]+ <[^>]*> f000 4a00 addiu v0,0 +[ ]*[0-9a-f]+: R_MIPS16_LO16 L0\001\+0x7fff +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x7fff +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x7fff +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 L0\001\+0x7fff +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x7fff +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x7fff +[0-9a-f]+ <[^>]*> f000 9a40 lw v0,0\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 L0\001\+0x7fff +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x7fff +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x7fff +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 L0\001-0x8002 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*-0x8002 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*-0x8002 +[0-9a-f]+ <[^>]*> f000 4a00 addiu v0,0 +[ ]*[0-9a-f]+: R_MIPS16_LO16 L0\001-0x8002 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*-0x8002 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*-0x8002 +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 L0\001-0x8002 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*-0x8002 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*-0x8002 +[0-9a-f]+ <[^>]*> f000 9a40 lw v0,0\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 L0\001-0x8002 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*-0x8002 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*-0x8002 +[0-9a-f]+ <[^>]*> 6500 nop + \.\.\. + \.\.\. diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-n64-sym32-1.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-n64-sym32-1.d new file mode 100644 index 00000000000..76f5e838ec1 --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-n64-sym32-1.d @@ -0,0 +1,68 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative operations 1 (n64, sym32) +#as: -64 -msym32 +#source: mips16-pcrel-1.s + +.*: +file format .*mips.* + +Disassembly of section \.text: + \.\.\. +[0-9a-f]+ <[^>]*> fe40 dla v0,0000000000010000 +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> fc40 ld v0,0000000000010000 +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> fe5f dla v0,0000000000010084 +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> fc5f ld v0,0000000000010100 +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> f080 fe40 dla v0,0000000000010090 +[0-9a-f]+ <[^>]*> f100 fc40 ld v0,0000000000010110 +[0-9a-f]+ <[^>]*> f7ff fe5c dla v0,0000000000010014 +[0-9a-f]+ <[^>]*> f7ff fc5c ld v0,0000000000010014 +[0-9a-f]+ <[^>]*> f7ef fe5f dla v0,000000000001801f +[0-9a-f]+ <[^>]*> f7ef fc5f ld v0,000000000001801f +[0-9a-f]+ <[^>]*> f010 fe40 dla v0,0000000000008028 +[0-9a-f]+ <[^>]*> f010 fc40 ld v0,0000000000008028 +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 L0\001\+0x7fff +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x7fff +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x7fff +[0-9a-f]+ <[^>]*> f000 fd40 daddiu v0,0 +[ ]*[0-9a-f]+: R_MIPS16_LO16 L0\001\+0x7fff +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x7fff +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x7fff +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 L0\001\+0x7ffb +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x7ffb +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x7ffb +[0-9a-f]+ <[^>]*> f000 3a40 ld v0,0\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 L0\001\+0x7ffb +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x7ffb +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*\+0x7ffb +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 L0\001-0x8002 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*-0x8002 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*-0x8002 +[0-9a-f]+ <[^>]*> f000 fd40 daddiu v0,0 +[ ]*[0-9a-f]+: R_MIPS16_LO16 L0\001-0x8002 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*-0x8002 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*-0x8002 +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 L0\001-0x8006 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*-0x8006 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*-0x8006 +[0-9a-f]+ <[^>]*> f000 3a40 ld v0,0\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 L0\001-0x8006 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*-0x8006 +[ ]*[0-9a-f]+: R_MIPS_NONE \*ABS\*-0x8006 +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> 6500 nop + \.\.\. + \.\.\. diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-reloc-2.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-reloc-2.d new file mode 100644 index 00000000000..e0d7050968a --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-reloc-2.d @@ -0,0 +1,20 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative relocation 2 +#as: -32 +#source: mips16-pcrel-reloc-2.s + +.*: +file format .*mips.* + +Disassembly of section \.text: + \.\.\. +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar +[0-9a-f]+ <[^>]*> f000 4a00 addiu v0,0 +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar +[0-9a-f]+ <[^>]*> f000 9a40 lw v0,0\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar +[0-9a-f]+ <[^>]*> 6500 nop + \.\.\. + \.\.\. diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-reloc-3.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-reloc-3.d new file mode 100644 index 00000000000..794e4d77bbb --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-reloc-3.d @@ -0,0 +1,19 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative relocation 3 +#as: -32 +#source: mips16-pcrel-reloc-3.s + +.*: +file format .*mips.* + +Disassembly of section \.text: + \.\.\. +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar +[0-9a-f]+ <[^>]*> f000 4a00 addiu v0,0 +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar +[0-9a-f]+ <[^>]*> f000 9a40 lw v0,0\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar +[0-9a-f]+ <[^>]*> 6500 nop + \.\.\. diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-reloc-6.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-reloc-6.d new file mode 100644 index 00000000000..f994881759b --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-reloc-6.d @@ -0,0 +1,20 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative relocation 6 +#as: -32 +#source: mips16-pcrel-reloc-6.s + +.*: +file format .*mips.* + +Disassembly of section \.text: + \.\.\. +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar +[0-9a-f]+ <[^>]*> f000 fd40 daddiu v0,0 +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar +[0-9a-f]+ <[^>]*> f000 3a40 ld v0,0\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar +[0-9a-f]+ <[^>]*> 6500 nop + \.\.\. + \.\.\. diff --git a/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-reloc-7.d b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-reloc-7.d new file mode 100644 index 00000000000..f6b94bd4aa2 --- /dev/null +++ b/gas/testsuite/gas/mips/mips16e2@mips16-pcrel-reloc-7.d @@ -0,0 +1,19 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16 PC-relative relocation 7 +#as: -32 +#source: mips16-pcrel-reloc-7.s + +.*: +file format .*mips.* + +Disassembly of section \.text: + \.\.\. +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar +[0-9a-f]+ <[^>]*> f000 fd40 daddiu v0,0 +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar +[0-9a-f]+ <[^>]*> f000 6a20 lui v0,0x0 +[ ]*[0-9a-f]+: R_MIPS16_HI16 bar +[0-9a-f]+ <[^>]*> f000 3a40 ld v0,0\(v0\) +[ ]*[0-9a-f]+: R_MIPS16_LO16 bar +[0-9a-f]+ <[^>]*> 6500 nop + \.\.\. diff --git a/ld/ChangeLog b/ld/ChangeLog index 8e31ca80acd..a8dad5ca1c2 100644 --- a/ld/ChangeLog +++ b/ld/ChangeLog @@ -1,3 +1,15 @@ +2017-05-15 Maciej W. Rozycki + + * testsuite/ld-mips-elf/mips16e2-pcrel-0.d: New test. + * testsuite/ld-mips-elf/mips16e2-pcrel-1.d: New test. + * testsuite/ld-mips-elf/mips16e2-pcrel-addend-2.d: New test. + * testsuite/ld-mips-elf/mips16e2-pcrel-addend-6.d: New test. + * testsuite/ld-mips-elf/mips16e2-pcrel-n32-0.d: New test. + * testsuite/ld-mips-elf/mips16e2-pcrel-n32-1.d: New test. + * testsuite/ld-mips-elf/mips16e2-pcrel-n64-sym32-0.d: New test. + * testsuite/ld-mips-elf/mips16e2-pcrel-n64-sym32-1.d: New test. + * testsuite/ld-mips-elf/mips-elf.exp: Run the new tests. + 2017-05-15 Nick Clifton PR ld/21459 diff --git a/ld/testsuite/ld-mips-elf/mips-elf.exp b/ld/testsuite/ld-mips-elf/mips-elf.exp index 13d962b0177..e24c32cd80b 100644 --- a/ld/testsuite/ld-mips-elf/mips-elf.exp +++ b/ld/testsuite/ld-mips-elf/mips-elf.exp @@ -156,13 +156,23 @@ if $has_newabi { run_dump_test "mips16-pcrel-0" [list [list ld $abi_ldflags(o32)]] run_dump_test "mips16-pcrel-1" [list [list ld $abi_ldflags(o32)]] +run_dump_test "mips16e2-pcrel-0" [list [list ld $abi_ldflags(o32)]] +run_dump_test "mips16e2-pcrel-1" [list [list ld $abi_ldflags(o32)]] run_dump_test "mips16-pcrel-addend-2" [list [list ld $abi_ldflags(o32)]] run_dump_test "mips16-pcrel-addend-6" [list [list ld $abi_ldflags(o32)]] +run_dump_test "mips16e2-pcrel-addend-2" [list [list ld $abi_ldflags(o32)]] +run_dump_test "mips16e2-pcrel-addend-6" [list [list ld $abi_ldflags(o32)]] if $has_newabi { run_dump_test "mips16-pcrel-n32-0" [list [list ld $abi_ldflags(n32)]] run_dump_test "mips16-pcrel-n32-1" [list [list ld $abi_ldflags(n32)]] run_dump_test "mips16-pcrel-n64-sym32-0" [list [list ld $abi_ldflags(n64)]] run_dump_test "mips16-pcrel-n64-sym32-1" [list [list ld $abi_ldflags(n64)]] + run_dump_test "mips16e2-pcrel-n32-0" [list [list ld $abi_ldflags(n32)]] + run_dump_test "mips16e2-pcrel-n32-1" [list [list ld $abi_ldflags(n32)]] + run_dump_test "mips16e2-pcrel-n64-sym32-0" \ + [list [list ld $abi_ldflags(n64)]] + run_dump_test "mips16e2-pcrel-n64-sym32-1" \ + [list [list ld $abi_ldflags(n64)]] } run_dump_test "mips16-branch-2" [list [list ld $abi_ldflags(o32)]] diff --git a/ld/testsuite/ld-mips-elf/mips16e2-pcrel-0.d b/ld/testsuite/ld-mips-elf/mips16e2-pcrel-0.d new file mode 100644 index 00000000000..a6add470ce8 --- /dev/null +++ b/ld/testsuite/ld-mips-elf/mips16e2-pcrel-0.d @@ -0,0 +1,37 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16e2 link PC-relative operations 0 +#source: ../../../gas/testsuite/gas/mips/mips16-pcrel-0.s +#as: -EB -32 -mips32r2 -mmips16e2 +#ld: -EB -Ttext 0 -e 0 + +.*: +file format .*mips.* + +Disassembly of section \.text: + \.\.\. +[0-9a-f]+ <[^>]*> 0a00 la v0,0+010000 <.*> +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> b200 lw v0,0+010004 <.*> +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> 0aff la v0,0+010404 <.*> +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> b2ff lw v0,0+010408 <.*> +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> f400 0a00 la v0,0+010410 <.*> +[0-9a-f]+ <[^>]*> f400 b200 lw v0,0+010414 <.*> +[0-9a-f]+ <[^>]*> f7ff 0a1c la v0,0+010014 <.*> +[0-9a-f]+ <[^>]*> f7ff b21c lw v0,0+010018 <.*> +[0-9a-f]+ <[^>]*> f7ef 0a1f la v0,0+01801f <.*> +[0-9a-f]+ <[^>]*> f7ef b21f lw v0,0+018023 <.*> +[0-9a-f]+ <[^>]*> f010 0a00 la v0,0+008028 <.*> +[0-9a-f]+ <[^>]*> f010 b200 lw v0,0+00802c <.*> +[0-9a-f]+ <[^>]*> f000 6a22 lui v0,0x2 +[0-9a-f]+ <[^>]*> f030 4a10 addiu v0,-32720 +[0-9a-f]+ <[^>]*> f000 6a22 lui v0,0x2 +[0-9a-f]+ <[^>]*> f030 9a58 lw v0,-32712\(v0\) +[0-9a-f]+ <[^>]*> f000 6a21 lui v0,0x1 +[0-9a-f]+ <[^>]*> f030 4a1f addiu v0,-32705 +[0-9a-f]+ <[^>]*> f000 6a21 lui v0,0x1 +[0-9a-f]+ <[^>]*> f050 9a47 lw v0,-32697\(v0\) +[0-9a-f]+ <[^>]*> 6500 nop + \.\.\. + \.\.\. diff --git a/ld/testsuite/ld-mips-elf/mips16e2-pcrel-1.d b/ld/testsuite/ld-mips-elf/mips16e2-pcrel-1.d new file mode 100644 index 00000000000..487ce16bcb3 --- /dev/null +++ b/ld/testsuite/ld-mips-elf/mips16e2-pcrel-1.d @@ -0,0 +1,45 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16e2 link PC-relative operations 1 +#source: ../../../gas/testsuite/gas/mips/mips16-pcrel-1.s +#as: -EB -32 -mips64r2 -mmips16e2 +#ld: -EB -Ttext 0 -e 0 + +.*: +file format .*mips.* + +Disassembly of section \.text: + \.\.\. +[0-9a-f]+ <[^>]*> fe40 dla v0,0+010000 <.*> +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> fc40 ld v0,0+010000 <.*> +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> fe5f dla v0,0+010084 <.*> +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> fc5f ld v0,0+010100 <.*> +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> f080 fe40 dla v0,0+010090 <.*> +[0-9a-f]+ <[^>]*> f100 fc40 ld v0,0+010110 <.*> +[0-9a-f]+ <[^>]*> f7ff fe5c dla v0,0+010014 <.*> +[0-9a-f]+ <[^>]*> f7ff fc5c ld v0,0+010014 <.*> +[0-9a-f]+ <[^>]*> f7ef fe5f dla v0,0+01801f <.*> +[0-9a-f]+ <[^>]*> f7ef fc5f ld v0,0+01801f <.*> +[0-9a-f]+ <[^>]*> f010 fe40 dla v0,0+008028 <.*> +[0-9a-f]+ <[^>]*> f010 fc40 ld v0,0+008028 <.*> +[0-9a-f]+ <[^>]*> f000 6a22 lui v0,0x2 +[0-9a-f]+ <[^>]*> f030 fd50 daddiu v0,-32720 +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> f000 6a22 lui v0,0x2 +[0-9a-f]+ <[^>]*> f030 3a58 ld v0,-32712\(v0\) +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> f000 6a21 lui v0,0x1 +[0-9a-f]+ <[^>]*> f050 fd47 daddiu v0,-32697 +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> f000 6a21 lui v0,0x1 +[0-9a-f]+ <[^>]*> f050 3a4f ld v0,-32689\(v0\) +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> 6500 nop +[0-9a-f]+ <[^>]*> 6500 nop + \.\.\. + \.\.\. diff --git a/ld/testsuite/ld-mips-elf/mips16e2-pcrel-addend-2.d b/ld/testsuite/ld-mips-elf/mips16e2-pcrel-addend-2.d new file mode 100644 index 00000000000..1b0cb37e5d4 --- /dev/null +++ b/ld/testsuite/ld-mips-elf/mips16e2-pcrel-addend-2.d @@ -0,0 +1,17 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16e2 link PC-relative relocation with addend 2 +#source: ../../../gas/testsuite/gas/mips/mips16-pcrel-addend-2.s +#as: -EB -32 -mips32r2 -mmips16e2 +#ld: -EB -Ttext 0x43210000 -e 0 + +.*: +file format .*mips.* + +Disassembly of section \.text: + \.\.\. +[0-9a-f]+ <[^>]*> f328 6a21 lui v0,0x4321 +[0-9a-f]+ <[^>]*> f264 4a04 addiu v0,8804 +[0-9a-f]+ <[^>]*> f328 6a21 lui v0,0x4321 +[0-9a-f]+ <[^>]*> f264 9a44 lw v0,8804\(v0\) +[0-9a-f]+ <[^>]*> 6500 nop + \.\.\. + \.\.\. diff --git a/ld/testsuite/ld-mips-elf/mips16e2-pcrel-addend-6.d b/ld/testsuite/ld-mips-elf/mips16e2-pcrel-addend-6.d new file mode 100644 index 00000000000..b680a5f17f2 --- /dev/null +++ b/ld/testsuite/ld-mips-elf/mips16e2-pcrel-addend-6.d @@ -0,0 +1,17 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16e2 link PC-relative relocation with addend 6 +#source: ../../../gas/testsuite/gas/mips/mips16-pcrel-addend-6.s +#as: -EB -32 -mips64r2 -mmips16e2 +#ld: -EB -Ttext 0x43210000 -e 0 + +.*: +file format .*mips.* + +Disassembly of section \.text: + \.\.\. +[0-9a-f]+ <[^>]*> f328 6a21 lui v0,0x4321 +[0-9a-f]+ <[^>]*> f264 fd44 daddiu v0,8804 +[0-9a-f]+ <[^>]*> f328 6a21 lui v0,0x4321 +[0-9a-f]+ <[^>]*> f264 3a44 ld v0,8804\(v0\) +[0-9a-f]+ <[^>]*> 6500 nop + \.\.\. + \.\.\. diff --git a/ld/testsuite/ld-mips-elf/mips16e2-pcrel-n32-0.d b/ld/testsuite/ld-mips-elf/mips16e2-pcrel-n32-0.d new file mode 100644 index 00000000000..d7d5e9dfc49 --- /dev/null +++ b/ld/testsuite/ld-mips-elf/mips16e2-pcrel-n32-0.d @@ -0,0 +1,6 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16e2 link PC-relative operations 0 (n32) +#source: ../../../gas/testsuite/gas/mips/mips16-pcrel-0.s +#as: -EB -n32 -mips64r2 -mmips16e2 +#ld: -EB -Ttext 0 -e 0 +#dump: mips16e2-pcrel-0.d diff --git a/ld/testsuite/ld-mips-elf/mips16e2-pcrel-n32-1.d b/ld/testsuite/ld-mips-elf/mips16e2-pcrel-n32-1.d new file mode 100644 index 00000000000..92bd3baa8a2 --- /dev/null +++ b/ld/testsuite/ld-mips-elf/mips16e2-pcrel-n32-1.d @@ -0,0 +1,6 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16e2 link PC-relative operations 1 (n32) +#source: ../../../gas/testsuite/gas/mips/mips16-pcrel-1.s +#as: -EB -n32 -mips64r2 -mmips16e2 +#ld: -EB -Ttext 0 -e 0 +#dump: mips16e2-pcrel-1.d diff --git a/ld/testsuite/ld-mips-elf/mips16e2-pcrel-n64-sym32-0.d b/ld/testsuite/ld-mips-elf/mips16e2-pcrel-n64-sym32-0.d new file mode 100644 index 00000000000..5ad20016210 --- /dev/null +++ b/ld/testsuite/ld-mips-elf/mips16e2-pcrel-n64-sym32-0.d @@ -0,0 +1,6 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16e2 link PC-relative operations 0 (n64, sym32) +#source: ../../../gas/testsuite/gas/mips/mips16-pcrel-0.s +#as: -EB -64 -msym32 -mips64r2 -mmips16e2 +#ld: -EB -Ttext 0 -e 0 +#dump: mips16e2-pcrel-0.d diff --git a/ld/testsuite/ld-mips-elf/mips16e2-pcrel-n64-sym32-1.d b/ld/testsuite/ld-mips-elf/mips16e2-pcrel-n64-sym32-1.d new file mode 100644 index 00000000000..ea33b8efb16 --- /dev/null +++ b/ld/testsuite/ld-mips-elf/mips16e2-pcrel-n64-sym32-1.d @@ -0,0 +1,6 @@ +#objdump: -dr --prefix-addresses --show-raw-insn +#name: MIPS16e2 link PC-relative operations 1 (n64, sym32) +#source: ../../../gas/testsuite/gas/mips/mips16-pcrel-1.s +#as: -EB -64 -msym32 -mips64r2 -mmips16e2 +#ld: -EB -Ttext 0 -e 0 +#dump: mips16e2-pcrel-1.d -- 2.30.2