public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
From: "Maciej W. Rozycki" <macro@orcam.me.uk>
To: Nick Clifton <nickc@redhat.com>
Cc: YunQiang Su <yunqiang.su@cipunited.com>, binutils@sourceware.org
Subject: [committed 10/16] MIPS/LD/testsuite: Fix MIPS16 interlinking test n64 regressions
Date: Fri, 28 Jul 2023 06:07:16 +0100 (BST)	[thread overview]
Message-ID: <alpine.DEB.2.21.2307272309500.10240@angie.orcam.me.uk> (raw)
In-Reply-To: <alpine.DEB.2.21.2307271457290.10240@angie.orcam.me.uk>

From: YunQiang Su <yunqiang.su@cipunited.com>

The MIPS16 interlinking test for local functions expects to be assembled 
with 32-bit addressing, otherwise causing assembly warnings:

.../ld/testsuite/ld-mips-elf/mips16-local-stubs-1.s: Assembler messages:
.../ld/testsuite/ld-mips-elf/mips16-local-stubs-1.s:16: Warning: la used to load 64-bit address; recommend using dla instead

Use the per-ABI framework then to run the test explicitly for o32 and 
n32 ABIs only, replacing the `-mips4' option from the `as' tag with 
`.module mips4' pseudo-op within the source itself so as to avoid 
assembly errors:

Assembler messages:
Error: -mips4 conflicts with the other architecture options, which imply -mips3

with n32 testing for some targets, and ultimately removing these 
regressions:

mips64-openbsd  -FAIL: MIPS16 interlinking for local functions 1
mips64el-openbsd  -FAIL: MIPS16 interlinking for local functions 1

Co-Authored-By: Maciej W. Rozycki <macro@orcam.me.uk>

	ld/
	* testsuite/ld-mips-elf/mips16-local-stubs-1.d: Remove `-mips4' 
	from the `as' tag.
	* testsuite/ld-mips-elf/mips16-local-stubs-1.s: Add `.module 
	mips4'.
	* testsuite/ld-mips-elf/mips-elf.exp: Run `mips16-local-stubs-1'
	for o32 and n32 ABIs only.
---
 ld/testsuite/ld-mips-elf/mips-elf.exp           |    3 ++-
 ld/testsuite/ld-mips-elf/mips16-local-stubs-1.d |    1 -
 ld/testsuite/ld-mips-elf/mips16-local-stubs-1.s |    2 ++
 3 files changed, 4 insertions(+), 2 deletions(-)

binutils-yunqiang-ld-test-mips16-local-stubs-1-n64.diff
Index: binutils-gdb/ld/testsuite/ld-mips-elf/mips-elf.exp
===================================================================
--- binutils-gdb.orig/ld/testsuite/ld-mips-elf/mips-elf.exp
+++ binutils-gdb/ld/testsuite/ld-mips-elf/mips-elf.exp
@@ -1047,7 +1047,8 @@ if { $has_abi(o32) } {
     run_ld_link_tests $mips16_intermix_test
 }
 
-run_dump_test "mips16-local-stubs-1"
+run_dump_test_o32 "mips16-local-stubs-1"
+run_dump_test_n32 "mips16-local-stubs-1" [list [list name (n32)]]
 
 set mips16_fp_stub_test [list \
     [list "Floating-point stub for mips16 functions" \
Index: binutils-gdb/ld/testsuite/ld-mips-elf/mips16-local-stubs-1.d
===================================================================
--- binutils-gdb.orig/ld/testsuite/ld-mips-elf/mips16-local-stubs-1.d
+++ binutils-gdb/ld/testsuite/ld-mips-elf/mips16-local-stubs-1.d
@@ -1,6 +1,5 @@
 #name: MIPS16 interlinking for local functions 1
 #source: mips16-local-stubs-1.s
-#as: -mips4
 #ld: -Ttext 0x20000000 -e caller1
 #objdump: -dr
 #...
Index: binutils-gdb/ld/testsuite/ld-mips-elf/mips16-local-stubs-1.s
===================================================================
--- binutils-gdb.orig/ld/testsuite/ld-mips-elf/mips16-local-stubs-1.s
+++ binutils-gdb/ld/testsuite/ld-mips-elf/mips16-local-stubs-1.s
@@ -1,3 +1,5 @@
+	.module	mips4
+
 	.macro	makestub,type,func,section
 	.text
 	.set	\type

  parent reply	other threads:[~2023-07-28  5:07 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-07-28  5:06 [committed 00/16] MIPS: Revert the change of `mipsisa64*-*-linux*' semantics Maciej W. Rozycki
2023-07-28  5:06 ` [committed 01/16] Revert "MIPS: support mips*64 as CPU and gnuabi64 as ABI" Maciej W. Rozycki
2023-07-28  5:06 ` [committed 02/16] MIPS/LD: Include n64 `.interp' with INITIAL_READONLY_SECTIONS Maciej W. Rozycki
2023-07-28  5:06 ` [committed 03/16] MIPS/GAS/testsuite: Disable compact EH #7 tests with OpenBSD targets Maciej W. Rozycki
2023-07-28  5:06 ` [committed 04/16] MIPS/LD/testsuite: Fix unaligned JALX failures " Maciej W. Rozycki
2023-07-28  5:06 ` [committed 05/16] MIPS/LD/testsuite: Fix JALR relaxation test failure with IRIX 6 Maciej W. Rozycki
2023-07-28  5:06 ` [committed 06/16] MIPS/LD/testsuite: Fix `attr-gnu-4-10' failures with IRIX targets Maciej W. Rozycki
2023-07-28  5:07 ` [committed 07/16] MIPS/LD/testsuite: Fix `attr-gnu-4-10' failures with OpenBSD targets Maciej W. Rozycki
2023-07-28  5:07 ` [committed 08/16] MIPS/LD/testsuite: Run `got-dump-1' for o32/n32 ABIs Maciej W. Rozycki
2023-07-28  5:07 ` [committed 09/16] MIPS/GAS/testsuite: Force o32 for tests expecting 32-bit addressing Maciej W. Rozycki
2023-07-28  5:07 ` Maciej W. Rozycki [this message]
2023-07-28  5:07 ` [committed 11/16] MIPS/LD/testsuite: Fix MIPS16 interlinking test IRIX 6 regressions Maciej W. Rozycki
2023-07-28  5:07 ` [committed 12/16] testsuite: Also discard the `.MIPS.options' section Maciej W. Rozycki
2023-07-28  5:07 ` [committed 13/16] MIPS/testsuite: Handle 64-bit addresses Maciej W. Rozycki
2023-07-28  5:07 ` [committed 14/16] testsuite: Handle composed R_MIPS_NONE relocations Maciej W. Rozycki
2023-07-28  5:07 ` [committed 15/16] MIPS/GAS/testsuite: Fix n64 compact EH failures Maciej W. Rozycki
2023-07-28  5:07 ` [committed 16/16] MIPS: Support `-gnuabi64' target triplet suffix for 64-bit Linux targets Maciej W. Rozycki

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=alpine.DEB.2.21.2307272309500.10240@angie.orcam.me.uk \
    --to=macro@orcam.me.uk \
    --cc=binutils@sourceware.org \
    --cc=nickc@redhat.com \
    --cc=yunqiang.su@cipunited.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).