Message ID | orjzqsi68k.fsf@lxoliva.fsfla.org |
---|---|
State | Accepted |
Headers |
Return-Path: <gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:aa0b:0:b0:403:3b70:6f57 with SMTP id k11csp1009399vqo; Wed, 8 Nov 2023 08:02:26 -0800 (PST) X-Google-Smtp-Source: AGHT+IH++Igz6w0hVuW2bqEXekeAqRfscxVITy2x2gz2ubM4lnQ8TDybDMdW/XsVdl5PP3qziMs3 X-Received: by 2002:a67:e09b:0:b0:45f:8b65:28f0 with SMTP id f27-20020a67e09b000000b0045f8b6528f0mr1989106vsl.12.1699459345795; Wed, 08 Nov 2023 08:02:25 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1699459345; cv=pass; d=google.com; s=arc-20160816; b=WlMe4JZcECx1o6qYs8tveOGO+AmVN18pdhFPTKfZSPNSKR+RE72xcHo4BX4bIY4uNh xjAmXPCaPmRRSAKU/yzWDTNS1fOUq8iAO3BP2lh+3P5yzrNOcCEUIuAQL+88nugHhkau vUNiEbaVWoem/67T9Be1ZmcHb+TlItGhe60jZDuJa9IO/DZdgra66Rt1VDZ2sZSfZAZR 7XcsyRGQEL1alPuKK8ubHzd0aKHg2GgmGDgHrP6VHorU8fJP9IB8tIv10oh0f8/wL6e+ V4QQ3Z4I0LwqUeWL5tk3rHu7IdcD79tiQlmRwoyrf5pIW+WovfUJPCPCH0t7DVbs0KeS mcqA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:mime-version:user-agent :message-id:date:organization:subject:cc:to:from:dkim-signature :arc-filter:dmarc-filter:delivered-to; bh=XZA2LyIfWzwRoG8PrL2KNA+epM5k6n28CO4d0HfiPlE=; fh=kSg1CLfgBj+L9aA9Iz5eHQ6XiMUmUx82S98PNH9ySxM=; b=w+VUWQ2HqEqCrOZHrB8C+iStOckj/+1ju+loyAPlm+LRca2TQ7B+KLWsJWLPzSi57J YoTYkvRZrtxAZ5ibO78S4BnFc4IzU9MKzDGTZEvv/FrBk7QKdTa0Qmb3KI0i+lxcQv8E ODDoqrxUaB0VKb3JLnp6VHw62XjBtuy+e4PhBT/CShSghMlHJeAdTQk9QvIgScGtjZ97 a80wDqNymU5grT65NqH3lCSOgEdoMyGVXSb3hx0Mcm2y/ZouAOO6OH7LsOFXnaP0DLNs 2qgywvRnI05BT9q5aBWcRI4ZOWL5NU2/SXvnpOMJDG8kxB5nkUEQYjiNPXgVjDgs6Rjp O9+w== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@adacore.com header.s=google header.b=Z7ShDQdG; arc=pass (i=1); spf=pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 2620:52:3:1:0:246e:9693:128c as permitted sender) smtp.mailfrom="gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=adacore.com Received: from server2.sourceware.org (server2.sourceware.org. [2620:52:3:1:0:246e:9693:128c]) by mx.google.com with ESMTPS id t8-20020a05610210c800b004528416a78fsi1203751vsr.328.2023.11.08.08.02.25 for <ouuuleilei@gmail.com> (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 08 Nov 2023 08:02:25 -0800 (PST) Received-SPF: pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 2620:52:3:1:0:246e:9693:128c as permitted sender) client-ip=2620:52:3:1:0:246e:9693:128c; Authentication-Results: mx.google.com; dkim=pass header.i=@adacore.com header.s=google header.b=Z7ShDQdG; arc=pass (i=1); spf=pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 2620:52:3:1:0:246e:9693:128c as permitted sender) smtp.mailfrom="gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=adacore.com Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 81CC038768A5 for <ouuuleilei@gmail.com>; Wed, 8 Nov 2023 16:02:25 +0000 (GMT) X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from mail-qv1-xf2a.google.com (mail-qv1-xf2a.google.com [IPv6:2607:f8b0:4864:20::f2a]) by sourceware.org (Postfix) with ESMTPS id 599E73857BB3 for <gcc-patches@gcc.gnu.org>; Wed, 8 Nov 2023 16:02:00 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 599E73857BB3 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=adacore.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=adacore.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 599E73857BB3 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::f2a ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1699459323; cv=none; b=YvMIKvZuMkRCifJEm684lJBKeM64eBvjAownQabTWTCkPRNUuOKA4ZvkTFe46njg8fu247WROX18o/3Hrj6MS+hagGBySEwobzLQ6HkXBLnZaIwKxh59enlsxA9SCC4fCrPNLVNlXEetyplqcE1tqCa27FSCLHJjJ4ufsqhpeDQ= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1699459323; c=relaxed/simple; bh=rQ0u6aBKNwZszSsy7o3k6JfU/u/ODalKevp0TYVR1mg=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=IhvX3XaL5pBeju4WXmNkLawmg+nXpDewA5vzdo7JzE11utcELL2jhAlETP5wmSZZzLRuBUaDLpO1gIZGBh7mvaS8dRUareFNlW9ycuLpcHlyBbsV2bca/0RaUlhnv8IqK/pOpw4tB2j5ZDULZ4RCaxdVYHGG0nTW9io5WDI0pkI= ARC-Authentication-Results: i=1; server2.sourceware.org Received: by mail-qv1-xf2a.google.com with SMTP id 6a1803df08f44-66fa16092c0so47882326d6.0 for <gcc-patches@gcc.gnu.org>; Wed, 08 Nov 2023 08:02:00 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=adacore.com; s=google; t=1699459319; x=1700064119; darn=gcc.gnu.org; h=mime-version:user-agent:message-id:date:organization:subject:cc:to :from:from:to:cc:subject:date:message-id:reply-to; bh=XZA2LyIfWzwRoG8PrL2KNA+epM5k6n28CO4d0HfiPlE=; b=Z7ShDQdGXvkVdoh2fCBUutiTwyMEVFrL6kJUqZRSrHod6YGpBItVzQAN4V7aEhxhfA LtCbVrlVfxZ8iqOE/pMu3kc1TxJn++dKtneFYlGRZ+Wvxbrlom7dragD6pi+J1HISlkD Mwf3q+YM1V0I+IrA4kw3JDXBIFI5xjglwYspsMrAiFl5PyHv4+p4jUq2dkIevAD3bTCo sdtCVkGqslLIVtz7p5Pkkol6yCfJuGrrjzQ6TeChjokssXI1Sj5jNzS4A1Vq6XylV9F/ 0Tng4kNV2MaafOjBwy8+EV1+VS/HdvuU1otRNcOIrozT87+os/DpHbvkyhiacrbZxJOT tLMA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1699459319; x=1700064119; h=mime-version:user-agent:message-id:date:organization:subject:cc:to :from:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=XZA2LyIfWzwRoG8PrL2KNA+epM5k6n28CO4d0HfiPlE=; b=D3MzTSTVUGtBdW659s+yUQgWVYrAYKThD3bAM9KX4JeROYYY6miVzyd8vOChfR8O4D fYz/bdFk62PcqaPp5OXvBgOEECw2OfTYo9z8UEAN1fl8DLyCuhKXq08TkjI+vb5h0Zee GeMBvmuNZB1D+Xk1GKkZjmgKKVMJ7sj4536kdo7SBOkJM1COPlKljF0KZ0VuascQ2qsl qmZcXvfR0+SCuotJVKXQ2QF/GT0nhWtYNJSAtBRa6uhC53IvnDSezt3uLVlePinLmKf7 b+BL+rgsbV4EgyXybgPWeXq069ixTvJSHF9Th3Aye9ZTCG4f0VAr+W/VG7fM6lcbkIOI B0tg== X-Gm-Message-State: AOJu0YzjymRar2AXb8VgNHiDChPZSrfrm3S2hvB4NSBSXeVAp2p/OpbR wZ/O1nBFkHBv+5YboLf6g5Y/dR8m1+gtOafAH6wAEQ== X-Received: by 2002:a05:6214:2343:b0:670:63bc:a2ca with SMTP id hu3-20020a056214234300b0067063bca2camr2346721qvb.28.1699459319752; Wed, 08 Nov 2023 08:01:59 -0800 (PST) Received: from free.home ([2804:7f1:2080:e9c8:ff5e:88e8:a900:d7b4]) by smtp.gmail.com with ESMTPSA id i2-20020a056214020200b0067101efa98asm1191442qvt.69.2023.11.08.08.01.58 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 08 Nov 2023 08:01:59 -0800 (PST) Received: from livre (livre.home [172.31.160.2]) by free.home (8.15.2/8.15.2) with ESMTPS id 3A8G1l8B2215050 (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384 bits=256 verify=NOT); Wed, 8 Nov 2023 13:01:47 -0300 From: Alexandre Oliva <oliva@adacore.com> To: gcc-patches@gcc.gnu.org Cc: Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>, Mike Stump <mikestump@comcast.net>, Richard Biener <rguenther@suse.de> Subject: [PATCH] testsuite: xfail scev-[35].c on ia32 Organization: Free thinker, does not speak for AdaCore Date: Wed, 08 Nov 2023 13:01:47 -0300 Message-ID: <orjzqsi68k.fsf@lxoliva.fsfla.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Scanned-By: MIMEDefang 2.84 X-Spam-Status: No, score=-11.4 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, KAM_NUMSUBJECT, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP, T_SCC_BODY_TEXT_LINE, WEIRD_QUOTING autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: gcc-patches@gcc.gnu.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Gcc-patches mailing list <gcc-patches.gcc.gnu.org> List-Unsubscribe: <https://gcc.gnu.org/mailman/options/gcc-patches>, <mailto:gcc-patches-request@gcc.gnu.org?subject=unsubscribe> List-Archive: <https://gcc.gnu.org/pipermail/gcc-patches/> List-Post: <mailto:gcc-patches@gcc.gnu.org> List-Help: <mailto:gcc-patches-request@gcc.gnu.org?subject=help> List-Subscribe: <https://gcc.gnu.org/mailman/listinfo/gcc-patches>, <mailto:gcc-patches-request@gcc.gnu.org?subject=subscribe> Errors-To: gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1782012282716212415 X-GMAIL-MSGID: 1782012282716212415 |
Series |
testsuite: xfail scev-[35].c on ia32
|
|
Checks
Context | Check | Description |
---|---|---|
snail/gcc-patch-check | success | Github commit url |
Commit Message
Alexandre Oliva
Nov. 8, 2023, 4:01 p.m. UTC
These gimplefe tests never got the desired optimization on ia32, but they only started visibly failing when the representation of MEMs in dumps changed from printing 'symbol: a' to '&a'. The transformation is not considered profitable on ia32, that's why it doesn't take place. Maybe that's a bug in itself, but it's not a regression, and not something to be noisy about. Regstrapped on x86_64-linux-gnu, also tested with gcc-13 on i686- and x86_64-. Ok to install? (Richi, is the non-optimization choice on ia32 something unexpected that ought to be looked into? I could file a PR, and maybe even look into it a bit further.) for gcc/testsuite/ChangeLog * gcc.dg/tree-ssa/scev-3.c: xfail on ia32. * gcc.dg/tree-ssa/scev-5.c: Likewise. Issue: gcc#155 TN: W517-007 --- gcc/testsuite/gcc.dg/tree-ssa/scev-3.c | 2 +- gcc/testsuite/gcc.dg/tree-ssa/scev-5.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)
Comments
On Wed, 8 Nov 2023, Alexandre Oliva wrote: > > These gimplefe tests never got the desired optimization on ia32, but > they only started visibly failing when the representation of MEMs in > dumps changed from printing 'symbol: a' to '&a'. > > The transformation is not considered profitable on ia32, that's why it > doesn't take place. Maybe that's a bug in itself, but it's not a > regression, and not something to be noisy about. > > Regstrapped on x86_64-linux-gnu, also tested with gcc-13 on i686- and > x86_64-. Ok to install? OK. > (Richi, is the non-optimization choice on ia32 something unexpected that > ought to be looked into? I could file a PR, and maybe even look into it > a bit further.) There might be even a PR already. The testcase expects that IVOPTs chooses an IV that satisfies both a_p = &a[i_12]; and *&a[i_12] = 100; basically code-generating a LEA, a store of the address and an register indirect memory access. That's what happens for 64bit (and presumably on all other archs). For some reason (I can only guess costing), on ia32 we choose to prioritize using a single induction variable (we need the original GIV for the exit test) and so we get an obfuscated LEA for the address store and a base with scaled index access for the store. Note the testcase is a bit "bad" because we later sink the store to a_p, so the generated assembly for the ia32 looks actually better. Richard. > > for gcc/testsuite/ChangeLog > > * gcc.dg/tree-ssa/scev-3.c: xfail on ia32. > * gcc.dg/tree-ssa/scev-5.c: Likewise. > > Issue: gcc#155 > TN: W517-007 > --- > gcc/testsuite/gcc.dg/tree-ssa/scev-3.c | 2 +- > gcc/testsuite/gcc.dg/tree-ssa/scev-5.c | 2 +- > 2 files changed, 2 insertions(+), 2 deletions(-) > > diff --git a/gcc/testsuite/gcc.dg/tree-ssa/scev-3.c b/gcc/testsuite/gcc.dg/tree-ssa/scev-3.c > index 4babd33f5c062..ac8c8d4519e30 100644 > --- a/gcc/testsuite/gcc.dg/tree-ssa/scev-3.c > +++ b/gcc/testsuite/gcc.dg/tree-ssa/scev-3.c > @@ -40,4 +40,4 @@ __BB(6): > > } > > -/* { dg-final { scan-tree-dump-times "&a" 1 "ivopts" } } */ > +/* { dg-final { scan-tree-dump-times "&a" 1 "ivopts" { xfail ia32 } } } */ > diff --git a/gcc/testsuite/gcc.dg/tree-ssa/scev-5.c b/gcc/testsuite/gcc.dg/tree-ssa/scev-5.c > index c2feebdfc2489..c911a9298866f 100644 > --- a/gcc/testsuite/gcc.dg/tree-ssa/scev-5.c > +++ b/gcc/testsuite/gcc.dg/tree-ssa/scev-5.c > @@ -40,4 +40,4 @@ __BB(6): > > } > > -/* { dg-final { scan-tree-dump-times "&a" 1 "ivopts" } } */ > +/* { dg-final { scan-tree-dump-times "&a" 1 "ivopts" { xfail ia32 } } } */ > >
Hi! On 2023-11-08T13:01:47-0300, Alexandre Oliva <oliva@adacore.com> wrote: > These gimplefe tests never got the desired optimization on ia32, but > they only started visibly failing when the representation of MEMs in > dumps changed from printing 'symbol: a' to '&a'. ACK -- but why not likewise "fix" the 'gcc.dg/tree-ssa/scev-4.c' FAIL? PASS: gcc.dg/tree-ssa/scev-3.c (test for excess errors) [-FAIL:-]{+XFAIL:+} gcc.dg/tree-ssa/scev-3.c scan-tree-dump-times ivopts "&a" 1 PASS: gcc.dg/tree-ssa/scev-4.c (test for excess errors) FAIL: gcc.dg/tree-ssa/scev-4.c scan-tree-dump-times ivopts "&a" 1 PASS: gcc.dg/tree-ssa/scev-5.c (test for excess errors) [-FAIL:-]{+XFAIL:+} gcc.dg/tree-ssa/scev-5.c scan-tree-dump-times ivopts "&a" 1 Grüße Thomas > The transformation is not considered profitable on ia32, that's why it > doesn't take place. Maybe that's a bug in itself, but it's not a > regression, and not something to be noisy about. > > Regstrapped on x86_64-linux-gnu, also tested with gcc-13 on i686- and > x86_64-. Ok to install? > > (Richi, is the non-optimization choice on ia32 something unexpected that > ought to be looked into? I could file a PR, and maybe even look into it > a bit further.) > > > for gcc/testsuite/ChangeLog > > * gcc.dg/tree-ssa/scev-3.c: xfail on ia32. > * gcc.dg/tree-ssa/scev-5.c: Likewise. > > Issue: gcc#155 > TN: W517-007 > --- > gcc/testsuite/gcc.dg/tree-ssa/scev-3.c | 2 +- > gcc/testsuite/gcc.dg/tree-ssa/scev-5.c | 2 +- > 2 files changed, 2 insertions(+), 2 deletions(-) > > diff --git a/gcc/testsuite/gcc.dg/tree-ssa/scev-3.c b/gcc/testsuite/gcc.dg/tree-ssa/scev-3.c > index 4babd33f5c062..ac8c8d4519e30 100644 > --- a/gcc/testsuite/gcc.dg/tree-ssa/scev-3.c > +++ b/gcc/testsuite/gcc.dg/tree-ssa/scev-3.c > @@ -40,4 +40,4 @@ __BB(6): > > } > > -/* { dg-final { scan-tree-dump-times "&a" 1 "ivopts" } } */ > +/* { dg-final { scan-tree-dump-times "&a" 1 "ivopts" { xfail ia32 } } } */ > diff --git a/gcc/testsuite/gcc.dg/tree-ssa/scev-5.c b/gcc/testsuite/gcc.dg/tree-ssa/scev-5.c > index c2feebdfc2489..c911a9298866f 100644 > --- a/gcc/testsuite/gcc.dg/tree-ssa/scev-5.c > +++ b/gcc/testsuite/gcc.dg/tree-ssa/scev-5.c > @@ -40,4 +40,4 @@ __BB(6): > > } > > -/* { dg-final { scan-tree-dump-times "&a" 1 "ivopts" } } */ > +/* { dg-final { scan-tree-dump-times "&a" 1 "ivopts" { xfail ia32 } } } */ > > -- > Alexandre Oliva, happy hacker https://FSFLA.org/blogs/lxo/ > Free Software Activist GNU Toolchain Engineer > More tolerance and less prejudice are key for inclusion and diversity > Excluding neuro-others for not behaving ""normal"" is *not* inclusive ----------------- Siemens Electronic Design Automation GmbH; Anschrift: Arnulfstraße 201, 80634 München; Gesellschaft mit beschränkter Haftung; Geschäftsführer: Thomas Heurung, Frank Thürauf; Sitz der Gesellschaft: München; Registergericht München, HRB 106955
On Nov 11, 2023, Thomas Schwinge <thomas@codesourcery.com> wrote:
> ACK -- but why not likewise "fix" the 'gcc.dg/tree-ssa/scev-4.c' FAIL?
I have evidence from earlier compiler version bumps that there's some
correlation and that scev-4.c also failed in the past, but it wasn't
failing for me this time.
diff --git a/gcc/testsuite/gcc.dg/tree-ssa/scev-3.c b/gcc/testsuite/gcc.dg/tree-ssa/scev-3.c index 4babd33f5c062..ac8c8d4519e30 100644 --- a/gcc/testsuite/gcc.dg/tree-ssa/scev-3.c +++ b/gcc/testsuite/gcc.dg/tree-ssa/scev-3.c @@ -40,4 +40,4 @@ __BB(6): } -/* { dg-final { scan-tree-dump-times "&a" 1 "ivopts" } } */ +/* { dg-final { scan-tree-dump-times "&a" 1 "ivopts" { xfail ia32 } } } */ diff --git a/gcc/testsuite/gcc.dg/tree-ssa/scev-5.c b/gcc/testsuite/gcc.dg/tree-ssa/scev-5.c index c2feebdfc2489..c911a9298866f 100644 --- a/gcc/testsuite/gcc.dg/tree-ssa/scev-5.c +++ b/gcc/testsuite/gcc.dg/tree-ssa/scev-5.c @@ -40,4 +40,4 @@ __BB(6): } -/* { dg-final { scan-tree-dump-times "&a" 1 "ivopts" } } */ +/* { dg-final { scan-tree-dump-times "&a" 1 "ivopts" { xfail ia32 } } } */