public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: chenxiaolong <chenxiaolong@loongson.cn>
To: gcc-patches@gcc.gnu.org
Cc: xry111@xry111.site, i@xen0n.name, xuchenghua@loongson.cn,
	chenglulu@loongson.cn, chenxiaolong <chenxiaolong@loongson.cn>
Subject: [PATCH v2 4/7] LoongArch: testsuite:Fix FAIL in file bind_c_array_params_2.f90.
Date: Fri,  5 Jan 2024 11:43:26 +0800	[thread overview]
Message-ID: <20240105034329.21117-5-chenxiaolong@loongson.cn> (raw)
In-Reply-To: <20240105034329.21117-1-chenxiaolong@loongson.cn>

On the LoongArch architecture, an error was found in the
bind_c_array_params_2.f90 file because there was no proper assembly code
for the regular expression detection function call, such as bl %plt(myBindC).

gcc/testsuite/ChangeLog:

	* gfortran.dg/bind_c_array_params_2.f90: Add code test rules to
	support testing of the loongArch architecture.
---
 gcc/testsuite/gfortran.dg/bind_c_array_params_2.f90 | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/gcc/testsuite/gfortran.dg/bind_c_array_params_2.f90 b/gcc/testsuite/gfortran.dg/bind_c_array_params_2.f90
index 0825efc7a2f..aa6a37b4850 100644
--- a/gcc/testsuite/gfortran.dg/bind_c_array_params_2.f90
+++ b/gcc/testsuite/gfortran.dg/bind_c_array_params_2.f90
@@ -2,6 +2,7 @@
 ! { dg-options "-std=f2008ts -fdump-tree-original" }
 ! { dg-additional-options "-mno-explicit-relocs" { target alpha*-*-* } }
 ! { dg-additional-options "-mno-relax-pic-calls" { target mips*-*-* } }
+! { dg-additional-options "-fplt -mcmodel=normal" { target loongarch*-*-* } }
 !
 ! Check that assumed-shape variables are correctly passed to BIND(C)
 ! as defined in TS 29913
@@ -16,7 +17,8 @@ integer :: aa(4,4)
 call test(aa)
 end
 
-! { dg-final { scan-assembler-times "\[ \t\]\[$,_0-9\]*myBindC" 1 { target { ! { hppa*-*-* s390*-*-* *-*-cygwin* amdgcn*-*-* powerpc-ibm-aix* *-*-ming* } } } } }
+! { dg-final { scan-assembler-times "\[ \t\]\[$,_0-9\]*myBindC" 1 { target { ! { hppa*-*-* s390*-*-* *-*-cygwin* amdgcn*-*-* powerpc-ibm-aix* *-*-ming* loongarch*-*-* } } } } }
+! { dg-final { scan-assembler-times "bl\t%plt\\(myBindC\\)" 1 { target loongarch*-*-* } } }
 ! { dg-final { scan-assembler-times "myBindC,%r2" 1 { target { hppa*-*-* } } } }
 ! { dg-final { scan-assembler-times "call\tmyBindC" 1 { target { *-*-cygwin* *-*-ming* } } } }
 ! { dg-final { scan-assembler-times "brasl\t%r\[0-9\]*,myBindC" 1 { target { s390*-*-* } } } }
-- 
2.20.1


  parent reply	other threads:[~2024-01-05  3:44 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-01-05  3:43 [PATCH v2 0/7] LoongArch:Enable testing for common chenxiaolong
2024-01-05  3:43 ` [PATCH v2 1/7] LoongArch: testsuite:Added support for vector object detection chenxiaolong
2024-01-05  3:43 ` [PATCH v2 2/7] LoongArch: testsuite:Modify the test behavior of the vect-bic-bitmask-{12,23}.c file chenxiaolong
2024-01-05  3:43 ` [PATCH v2 3/7] LoongArch: testsuite:Added detection support for LoongArch architecture in vect-{82,83}.c chenxiaolong
2024-01-05  3:43 ` chenxiaolong [this message]
2024-01-05  3:43 ` [PATCH v2 5/7] LoongArch: testsuite:Delete the default run behavior in pr60510.f chenxiaolong
2024-01-05  3:43 ` [PATCH v2 6/7] LoongArch: testsuite:Added additional vectorization "-mlasx" compilation option chenxiaolong
2024-01-05  3:43 ` [PATCH v2 7/7] LoongArch: testsuite:Give up the detection of the gcc.dg/fma-{3,4,6,7}.c file chenxiaolong
2024-01-05 12:29 ` [pushed][PATCH v2 0/7] LoongArch:Enable testing for common chenglulu

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=20240105034329.21117-5-chenxiaolong@loongson.cn \
    --to=chenxiaolong@loongson.cn \
    --cc=chenglulu@loongson.cn \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=i@xen0n.name \
    --cc=xry111@xry111.site \
    --cc=xuchenghua@loongson.cn \
    /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).