public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Segher Boessenkool <segher@kernel.crashing.org>
To: "Kewen.Lin" <linkw@linux.ibm.com>
Cc: Peter Bergner <bergner@linux.ibm.com>,
	David Edelsohn <dje.gcc@gmail.com>,
	GCC Patches <gcc-patches@gcc.gnu.org>
Subject: Re: [PATCH] rs6000/test: Fix bswap64-4.c with has_arch_ppc64 [PR106680]
Date: Fri, 2 Sep 2022 12:36:04 -0500	[thread overview]
Message-ID: <20220902173604.GW25951@gate.crashing.org> (raw)
In-Reply-To: <9b27e429-9f34-dc97-7ab6-4e5f6b02324e@linux.ibm.com>

On Fri, Sep 02, 2022 at 08:50:52AM +0800, Kewen.Lin wrote:
> on 2022/9/1 22:57, Segher Boessenkool wrote:
> > These two are independent, but apparently we have a bug here, which will
> > make what you did malfunction in some cases -- the test will not run for
> > ilp32 if you have RUNTESTFLAGS {-m32,-m64}.
> 
> Yeah, because of the bug (or call it surprised behavior),

No, I call it a bug.  Because that is what it is!

> the test case can
> fail for some dejaGnu version like 1.5.1 (how it places the dg-options matters).

Yes, but that is only one way to expose the problem.

The bug just should be fixed.

> But to be clarified, the order of 
> 
>   /* { dg-options "-O2 -mpowerpc64" } */
> 
> and 
>   
>   /* { dg-require-effective-target has_arch_ppc64 } */
> 
> matters in this proposed fix, not for the line with ilp32.

Of course :-)

> has_arch_ppc64 uses current_compiler_flags which only incorporates dg-options
> which is placed before the dg-require-effective-target.  I guess it's related
> to how dejaGnu parses lines and sets global variables, for this kind of case,
> we have to put the expected order for now.

Even just to avoid having to uselessly edit hundreds of testcases, it
would be better to just fix the bug!


Segher

  reply	other threads:[~2022-09-02 17:37 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-08-31  9:33 Kewen.Lin
2022-08-31 14:13 ` Peter Bergner
2022-09-01  8:57   ` Kewen.Lin
2022-09-01 14:57     ` Segher Boessenkool
2022-09-02  0:50       ` Kewen.Lin
2022-09-02 17:36         ` Segher Boessenkool [this message]
2022-09-05  2:25           ` Kewen.Lin
2022-08-31 15:24 ` Segher Boessenkool
2022-08-31 15:48   ` Peter Bergner
2022-08-31 16:05     ` Segher Boessenkool
2022-08-31 17:00       ` Peter Bergner
2022-08-31 19:28         ` Segher Boessenkool
2022-08-31 19:53           ` Peter Bergner
2022-08-31 21:07             ` Segher Boessenkool
2022-08-31 21:38               ` Peter Bergner
2022-08-31 21:49                 ` Segher Boessenkool
2022-08-31 22:17                   ` Peter Bergner
2022-09-01  9:05   ` Kewen.Lin
2022-09-01 15:04     ` Segher Boessenkool
2022-09-02  0:51       ` Kewen.Lin
2022-09-02 17:44         ` Segher Boessenkool
2022-09-05  2:35           ` Kewen.Lin

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=20220902173604.GW25951@gate.crashing.org \
    --to=segher@kernel.crashing.org \
    --cc=bergner@linux.ibm.com \
    --cc=dje.gcc@gmail.com \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=linkw@linux.ibm.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).