public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Richard Biener <richard.guenther@gmail.com>
To: Jakub Jelinek <jakub@redhat.com>
Cc: Rainer Orth <ro@cebitec.uni-bielefeld.de>,
	Martin Sebor <msebor@gmail.com>,
		gcc-patches <gcc-patches@gcc.gnu.org>
Subject: Re: [PATCH] include MEM_REF type in tree dumps (PR 90676)
Date: Thu, 13 Jun 2019 11:18:00 -0000	[thread overview]
Message-ID: <CAFiYyc2oHwRaN3fOrZvehmFW+90Jq9H1PPu_TaDRhdo2RqcRcw@mail.gmail.com> (raw)
In-Reply-To: <20190613104454.GB19695@tucnak>

On Thu, Jun 13, 2019 at 12:45 PM Jakub Jelinek <jakub@redhat.com> wrote:
>
> On Thu, Jun 13, 2019 at 10:53:55AM +0200, Rainer Orth wrote:
> > >> Even with that fixed, I see many failures:
> > >>
> > >> +FAIL: g++.dg/tree-ssa/pr31146.C  -std=gnu++14  scan-tree-dump forwprop1 "MEM\\\\[.*&i\\\\]\\\\[j.*\\\\] =.* 1;"
> > >> +FAIL: g++.dg/tree-ssa/pr31146.C  -std=gnu++17  scan-tree-dump forwprop1 "MEM\\\\[.*&i\\\\]\\\\[j.*\\\\] =.* 1;"
> > >> +FAIL: g++.dg/tree-ssa/pr31146.C  -std=gnu++98  scan-tree-dump forwprop1 "MEM\\\\[.*&i\\\\]\\\\[j.*\\\\] =.* 1;"
> > >> +FAIL: g++.dg/tree-ssa/ssa-dse-1.C   scan-tree-dump-times dse1 "MEM <char\\\\[176]> \\\\[\\\\(struct FixBuf \\\\*\\\\)&<retval> \\\\+ [0-9]+B\\\\] = {}" 1
> > >>
> > >> on 32 and 64-bit i386-pc-solaris2.11 (and i686-pc-linux-gnu),
> >
> > these failures remain...
>
> On i686-linux I can reproduce just the above ones.
> The following should fix it.  As we don't match exact offset on the MEM
> because it varries between different architectures (24 bytes on with -m64,
> 28 bytes with -m32), we shouldn't match the store size either, as it is
> 200 - that offset, so 176 or 172 etc.
>
> Tested on x86_64-linux, -m32/-m64, ok for trunk?

OK.

Richard.

> 2019-06-13  Jakub Jelinek  <jakub@redhat.com>
>
>         * g++.dg/tree-ssa/ssa-dse-1.C: Don't match exact number of chars of
>         = {} store.
>         * g++.dg/tree-ssa/pr31146.C: Change -fdump-tree-forwprop to
>         -fdump-tree-forwprop1 in dg-options.  Expect <int[5]> in MEM.
>
> --- gcc/testsuite/g++.dg/tree-ssa/ssa-dse-1.C.jj        2019-06-13 00:35:49.654840275 +0200
> +++ gcc/testsuite/g++.dg/tree-ssa/ssa-dse-1.C   2019-06-13 12:40:14.492568336 +0200
> @@ -98,4 +98,4 @@ int main()
>
>
>  /* { dg-final { scan-tree-dump-times "MEM\\\[\\(struct FixBuf \\*\\)&<retval> \\+ \[0-9\]+B\\\] = {}" 1 "dse1" { target { ! store_merge } } } }
> -   { dg-final { scan-tree-dump-times "MEM <char\\\[176]> \\\[\\(struct FixBuf \\*\\)&<retval> \\+ \[0-9\]+B\\\] = {}" 1 "dse1" { target { store_merge } } } } */
> +   { dg-final { scan-tree-dump-times "MEM <char\\\[\[0-9\]+]> \\\[\\(struct FixBuf \\*\\)&<retval> \\+ \[0-9\]+B\\\] = {}" 1 "dse1" { target { store_merge } } } } */
> --- gcc/testsuite/g++.dg/tree-ssa/pr31146.C.jj  2015-05-29 15:04:33.039803414 +0200
> +++ gcc/testsuite/g++.dg/tree-ssa/pr31146.C     2019-06-13 12:24:15.895576933 +0200
> @@ -1,5 +1,5 @@
>  /* { dg-do compile } */
> -/* { dg-options "-O -fdump-tree-forwprop" } */
> +/* { dg-options "-O -fdump-tree-forwprop1" } */
>
>  /* We should be able to optimize this to i[j] = 1 during
>     early optimizations.  */
> @@ -12,4 +12,4 @@ void foo (int j)
>    *q = 1;
>  }
>
> -/* { dg-final { scan-tree-dump "MEM\\\[.*&i\\\]\\\[j.*\\\] =.* 1;" "forwprop1" } } */
> +/* { dg-final { scan-tree-dump "MEM <int\\\[5\\\]> \\\[.*&i\\\]\\\[j.*\\\] =.* 1;" "forwprop1" } } */
>
>
>         Jakub

  parent reply	other threads:[~2019-06-13 11:18 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-06-01 15:53 Martin Sebor
2019-06-01 16:16 ` Martin Sebor
2019-06-03  8:36 ` Richard Biener
2019-06-03  8:57   ` Jakub Jelinek
2019-06-03 10:35     ` Richard Biener
2019-06-03 15:13       ` Martin Sebor
2019-06-04 10:58         ` Richard Biener
2019-06-10 19:23           ` Martin Sebor
2019-06-10 19:29             ` Jakub Jelinek
2019-06-10 20:37               ` Martin Sebor
2019-06-11 10:43                 ` Richard Biener
2019-06-12 21:34                   ` Rainer Orth
2019-06-12 21:47                     ` Martin Sebor
2019-06-13  9:04                       ` Rainer Orth
2019-06-13 10:45                         ` Jakub Jelinek
2019-06-13 11:18                           ` Rainer Orth
2019-06-13 11:18                           ` Richard Biener [this message]
2019-06-13 15:30                           ` Martin Sebor
2019-06-13 15:34                             ` Jakub Jelinek
2019-06-13 15:50                               ` Martin Sebor
2019-06-13 15:54                                 ` Jakub Jelinek
2019-06-14  7:44                                   ` Richard Biener
2019-06-14  8:51                                     ` Jan Hubicka

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=CAFiYyc2oHwRaN3fOrZvehmFW+90Jq9H1PPu_TaDRhdo2RqcRcw@mail.gmail.com \
    --to=richard.guenther@gmail.com \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=jakub@redhat.com \
    --cc=msebor@gmail.com \
    --cc=ro@cebitec.uni-bielefeld.de \
    /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).