Patchwork [testsuite] : Fix scan-tree-dump-times argument order in gcc.dg/tree-ssa/vrp68.c.

login
register
mail settings
Submitter Uros Bizjak
Date June 17, 2012, 8:41 a.m.
Message ID <CAFULd4YGSDgrW_3vFJOqLCSkkf1WdKCRF+s15BrjBvBQFd8X7Q@mail.gmail.com>
Download mbox | patch
Permalink /patch/165329/
State New
Headers show

Comments

Uros Bizjak - June 17, 2012, 8:41 a.m.
Hello!

The testcase still fails on x86_64-pc-linux-gnu with:

FAIL: gcc.dg/tree-ssa/vrp68.c scan-tree-dump-times vrp1 "link_error" 1

since there are two calls to link_error.

2012-06-17  Uros Bizjak  <ubizjak@gmail.com>

	* gcc.dg/tree-ssa/vrp68.c: Fix scan-tree-dump-times argument order.

Committed to mainline SVN.

Uros.
Richard Guenther - June 17, 2012, 12:03 p.m.
On Sun, Jun 17, 2012 at 10:41 AM, Uros Bizjak <ubizjak@gmail.com> wrote:
> Hello!
>
> The testcase still fails on x86_64-pc-linux-gnu with:
>
> FAIL: gcc.dg/tree-ssa/vrp68.c scan-tree-dump-times vrp1 "link_error" 1
>
> since there are two calls to link_error.

Oops.  I wonder how I did not see those failures myself ...

Richard.

> 2012-06-17  Uros Bizjak  <ubizjak@gmail.com>
>
>        * gcc.dg/tree-ssa/vrp68.c: Fix scan-tree-dump-times argument order.
>
> Committed to mainline SVN.
>
> Uros.
Janis Johnson - June 18, 2012, 8:01 p.m.
On 06/17/2012 05:03 AM, Richard Guenther wrote:
> On Sun, Jun 17, 2012 at 10:41 AM, Uros Bizjak <ubizjak@gmail.com> wrote:
>> Hello!
>>
>> The testcase still fails on x86_64-pc-linux-gnu with:
>>
>> FAIL: gcc.dg/tree-ssa/vrp68.c scan-tree-dump-times vrp1 "link_error" 1
>>
>> since there are two calls to link_error.
> 
> Oops.  I wonder how I did not see those failures myself ...
> 
> Richard.

I'm confused about what this test is supposed to do.  It uses
"dg-do link" which means the compile (test for excess errors) will
fail if there is a reference to link_error.  There are two uses of
scan-tree-dump-times for the same string in the same file, so one
of those is guaranteed to fail.  It looks like the scans aren't
needed, and "dg-do link" is the thing that needs the xfail.

Janis
Richard Guenther - June 19, 2012, 8:56 a.m.
On Mon, Jun 18, 2012 at 10:01 PM, Janis Johnson
<janis_johnson@mentor.com> wrote:
> On 06/17/2012 05:03 AM, Richard Guenther wrote:
>> On Sun, Jun 17, 2012 at 10:41 AM, Uros Bizjak <ubizjak@gmail.com> wrote:
>>> Hello!
>>>
>>> The testcase still fails on x86_64-pc-linux-gnu with:
>>>
>>> FAIL: gcc.dg/tree-ssa/vrp68.c scan-tree-dump-times vrp1 "link_error" 1
>>>
>>> since there are two calls to link_error.
>>
>> Oops.  I wonder how I did not see those failures myself ...
>>
>> Richard.
>
> I'm confused about what this test is supposed to do.  It uses
> "dg-do link" which means the compile (test for excess errors) will
> fail if there is a reference to link_error.  There are two uses of
> scan-tree-dump-times for the same string in the same file, so one
> of those is guaranteed to fail.  It looks like the scans aren't
> needed, and "dg-do link" is the thing that needs the xfail.

No, the scan-tree-dump-times are supposed to catch that already
VRP1 has done the optimization - it does not so fully, which is
why I added the XFAILed scan-tree-dump-times.  But we still catch
that XFAILed case with subsequent optimizations so the link succeeds
nevertheless.

The testcase fails now, I must have broken the optimization somehow
and I am looking into it.

Richard.

> Janis

Patch

Index: gcc.dg/tree-ssa/vrp68.c
===================================================================
--- gcc.dg/tree-ssa/vrp68.c	(revision 188702)
+++ gcc.dg/tree-ssa/vrp68.c	(working copy)
@@ -19,6 +19,6 @@ 
    merging [1, 5] with ~[0, 6] so the first VRP pass can only eliminate
    the ~[0, 0] check as redundant.  */
 
-/* { dg-final { scan-tree-dump-times "vrp1" 0 "link_error" { xfail *-*-* } } } */
-/* { dg-final { scan-tree-dump-times "vrp1" 1 "link_error" } } */
+/* { dg-final { scan-tree-dump-times "link_error" 0 "vrp1" { xfail *-*-* } } } */
+/* { dg-final { scan-tree-dump-times "link_error" 1 "vrp1" } } */
 /* { dg-final { cleanup-tree-dump "vrp1" } } */