From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from rock.gnat.com (rock.gnat.com [IPv6:2620:20:4000:0:a9e:1ff:fe9b:1d1]) by sourceware.org (Postfix) with ESMTPS id 6BCB83858D33 for ; Wed, 22 Feb 2023 17:31:34 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 6BCB83858D33 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=adacore.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=adacore.com Received: from localhost (localhost.localdomain [127.0.0.1]) by filtered-rock.gnat.com (Postfix) with ESMTP id 290D911610C; Wed, 22 Feb 2023 12:31:34 -0500 (EST) X-Virus-Scanned: Debian amavisd-new at gnat.com Received: from rock.gnat.com ([127.0.0.1]) by localhost (rock.gnat.com [127.0.0.1]) (amavisd-new, port 10024) with LMTP id iChL9SCMbaa3; Wed, 22 Feb 2023 12:31:34 -0500 (EST) Received: from free.home (tron.gnat.com [IPv6:2620:20:4000:0:46a8:42ff:fe0e:e294]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by rock.gnat.com (Postfix) with ESMTPS id EAC2011610B; Wed, 22 Feb 2023 12:31:29 -0500 (EST) Received: from livre (livre.home [172.31.160.2]) by free.home (8.15.2/8.15.2) with ESMTPS id 31MHVFSY296436 (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384 bits=256 verify=NOT); Wed, 22 Feb 2023 14:31:16 -0300 From: Alexandre Oliva To: Kyrylo Tkachov Cc: "gcc-patches\@gcc.gnu.org" , "nickc\@redhat.com" , Richard Earnshaw , "ramana.gcc\@gmail.com" Subject: Re: [PATCH] [arm] disable aes-1742098 mitigation for a72 combine tests Organization: Free thinker, does not speak for AdaCore References: Errors-To: aoliva@lxoliva.fsfla.org Date: Wed, 22 Feb 2023 14:31:15 -0300 In-Reply-To: (Kyrylo Tkachov's message of "Mon, 20 Feb 2023 15:43:18 +0000") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.3 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Scanned-By: MIMEDefang 2.84 X-Spam-Status: No, score=-12.3 required=5.0 tests=BAYES_00,GIT_PATCH_0,KAM_DMARC_STATUS,KAM_SHORT,SPF_HELO_NONE,SPF_PASS,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: Hello, Kyrylo, On Feb 20, 2023, Kyrylo Tkachov wrote: > So rather than overriding this awkward part with > -mno-fix-cortex-a57-aes-1742098 I'd rather just select a different > CPU that enables that fusion and isn't afflicted by this workaround, > such as -mcpu=cortex-a53. Sounds good to me. > Ok with changing the -mcpu option instead. Thanks, here's what I've just retested and am now checking in. [arm] avoid aes-1742098 mitigation in combine tests The expected asm output for aes-fuse-[12].c does not correspond to that which is generated when -mfix-cortex-a57-aes-1742098 is enabled. The mitigation was introduced after the test, and enabled by default for the selected processor, a72. Select a53 instead, where the migitation is not enabled by default, and all the expected fusions can take place. for gcc/testsuite/ChangeLog * gcc.target/arm/aes-fuse-1.c: Switch to -mcpu=cortex-a53. * gcc.target/arm/aes-fuse-2.c: Likewise. --- gcc/testsuite/gcc.target/arm/aes-fuse-1.c | 2 +- gcc/testsuite/gcc.target/arm/aes-fuse-2.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/gcc/testsuite/gcc.target/arm/aes-fuse-1.c b/gcc/testsuite/gcc.target/arm/aes-fuse-1.c index 27b08aeef7ba7..a1bbe054e0a01 100644 --- a/gcc/testsuite/gcc.target/arm/aes-fuse-1.c +++ b/gcc/testsuite/gcc.target/arm/aes-fuse-1.c @@ -1,7 +1,7 @@ /* { dg-do compile } */ /* { dg-require-effective-target arm_crypto_ok } */ /* { dg-add-options arm_crypto } */ -/* { dg-additional-options "-mcpu=cortex-a72 -O3 -dp" } */ +/* { dg-additional-options "-mcpu=cortex-a53 -O3 -dp" } */ #include diff --git a/gcc/testsuite/gcc.target/arm/aes-fuse-2.c b/gcc/testsuite/gcc.target/arm/aes-fuse-2.c index 1266a28753169..ede3237ce2692 100644 --- a/gcc/testsuite/gcc.target/arm/aes-fuse-2.c +++ b/gcc/testsuite/gcc.target/arm/aes-fuse-2.c @@ -1,7 +1,7 @@ /* { dg-do compile } */ /* { dg-require-effective-target arm_crypto_ok } */ /* { dg-add-options arm_crypto } */ -/* { dg-additional-options "-mcpu=cortex-a72 -O3 -dp" } */ +/* { dg-additional-options "-mcpu=cortex-a53 -O3 -dp" } */ #include -- Alexandre Oliva, happy hacker https://FSFLA.org/blogs/lxo/ Free Software Activist GNU Toolchain Engineer Disinformation flourishes because many people care deeply about injustice but very few check the facts. Ask me about