From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 1923) id 3BCE43858D32; Tue, 5 Sep 2023 08:50:03 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 3BCE43858D32 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1693903803; bh=Q6ZH/nXgY1UURG9AlcsOx6yqNUwzU6U/knId/Bd3q8s=; h=From:To:Subject:Date:From; b=IgJXKlbIgyO4ihMDLFMn6WJNFxSgUxzEEvt09qt2XZwIkt0mQxQ+qiWFdaBcrgBuU 67yzNyzw5JzEcT6CRP7ZrZMrKvqSMQRtWSjluQhQ8yApQk55xVSfmLxAuv1WDxsT1X cyVSYl/porwCC9FznlDCHuWXCj89A0OCBv0WzJoc= MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset="utf-8" From: Philipp Tomsich To: gcc-cvs@gcc.gnu.org Subject: [gcc r14-3673] riscv: xtheadcondmov: Don't run tests with -Oz X-Act-Checkin: gcc X-Git-Author: =?utf-8?q?Christoph_M=C3=BCllner?= X-Git-Refname: refs/heads/master X-Git-Oldrev: 1cf57a14d7de4d150a59191973085a93050bcc9a X-Git-Newrev: 8451fbd56871267e8c1cd781db6d8f02e826f66c Message-Id: <20230905085003.3BCE43858D32@sourceware.org> Date: Tue, 5 Sep 2023 08:50:03 +0000 (GMT) List-Id: https://gcc.gnu.org/g:8451fbd56871267e8c1cd781db6d8f02e826f66c commit r14-3673-g8451fbd56871267e8c1cd781db6d8f02e826f66c Author: Christoph Müllner Date: Fri Sep 1 11:56:20 2023 +0200 riscv: xtheadcondmov: Don't run tests with -Oz Recently, these xtheadcondmov tests regressed with -Oz: * FAIL: gcc.target/riscv/xtheadcondmov-mveqz-imm-eqz.c * FAIL: gcc.target/riscv/xtheadcondmov-mveqz-imm-not.c * FAIL: gcc.target/riscv/xtheadcondmov-mvnez-imm-cond.c * FAIL: gcc.target/riscv/xtheadcondmov-mvnez-imm-nez.c As -Oz stands for "Optimize aggressively for size rather than speed.", we need to inspect the generated code, which looks like this: -Oz 0000000000000000 : 0: e199 bnez a1,6 <.L2> 2: 40100513 li a0,1025 0000000000000006 <.L2>: 6: 8082 ret -O2: 0000000000000000 : 0: 40100793 li a5,1025 4: 40b7950b th.mveqz a0,a5,a1 8: 8082 ret As the generated code with -Oz consumes less size, there is nothing wrong in the code generation. Instead, let's not run the xtheadcondmov tests with -Oz. gcc/testsuite/ChangeLog: * gcc.target/riscv/xtheadcondmov-mveqz-imm-eqz.c: Disable for -Oz. * gcc.target/riscv/xtheadcondmov-mveqz-imm-not.c: Likewise. * gcc.target/riscv/xtheadcondmov-mveqz-reg-eqz.c: Likewise. * gcc.target/riscv/xtheadcondmov-mveqz-reg-not.c: Likewise. * gcc.target/riscv/xtheadcondmov-mvnez-imm-cond.c: Likewise. * gcc.target/riscv/xtheadcondmov-mvnez-imm-nez.c: Likewise. * gcc.target/riscv/xtheadcondmov-mvnez-reg-cond.c: Likewise. * gcc.target/riscv/xtheadcondmov-mvnez-reg-nez.c: Likewise. Signed-off-by: Christoph Müllner Diff: --- gcc/testsuite/gcc.target/riscv/xtheadcondmov-mveqz-imm-eqz.c | 2 +- gcc/testsuite/gcc.target/riscv/xtheadcondmov-mveqz-imm-not.c | 2 +- gcc/testsuite/gcc.target/riscv/xtheadcondmov-mveqz-reg-eqz.c | 2 +- gcc/testsuite/gcc.target/riscv/xtheadcondmov-mveqz-reg-not.c | 2 +- gcc/testsuite/gcc.target/riscv/xtheadcondmov-mvnez-imm-cond.c | 2 +- gcc/testsuite/gcc.target/riscv/xtheadcondmov-mvnez-imm-nez.c | 2 +- gcc/testsuite/gcc.target/riscv/xtheadcondmov-mvnez-reg-cond.c | 2 +- gcc/testsuite/gcc.target/riscv/xtheadcondmov-mvnez-reg-nez.c | 2 +- 8 files changed, 8 insertions(+), 8 deletions(-) diff --git a/gcc/testsuite/gcc.target/riscv/xtheadcondmov-mveqz-imm-eqz.c b/gcc/testsuite/gcc.target/riscv/xtheadcondmov-mveqz-imm-eqz.c index 913ae43f21b5..9cc9ec1d0c78 100644 --- a/gcc/testsuite/gcc.target/riscv/xtheadcondmov-mveqz-imm-eqz.c +++ b/gcc/testsuite/gcc.target/riscv/xtheadcondmov-mveqz-imm-eqz.c @@ -1,7 +1,7 @@ /* { dg-do compile } */ /* { dg-options "-march=rv32gc_xtheadcondmov" { target { rv32 } } } */ /* { dg-options "-march=rv64gc_xtheadcondmov" { target { rv64 } } } */ -/* { dg-skip-if "" { *-*-* } { "-O0" "-Os" "-Og" } } */ +/* { dg-skip-if "" { *-*-* } { "-O0" "-Os" "-Og" "-Oz" } } */ int not_int_int (int x, int cond) diff --git a/gcc/testsuite/gcc.target/riscv/xtheadcondmov-mveqz-imm-not.c b/gcc/testsuite/gcc.target/riscv/xtheadcondmov-mveqz-imm-not.c index 1bc8b8382335..491343370b77 100644 --- a/gcc/testsuite/gcc.target/riscv/xtheadcondmov-mveqz-imm-not.c +++ b/gcc/testsuite/gcc.target/riscv/xtheadcondmov-mveqz-imm-not.c @@ -1,7 +1,7 @@ /* { dg-do compile } */ /* { dg-options "-march=rv32gc_xtheadcondmov" { target { rv32 } } } */ /* { dg-options "-march=rv64gc_xtheadcondmov" { target { rv64 } } } */ -/* { dg-skip-if "" { *-*-* } { "-O0" "-Os" "-Og" } } */ +/* { dg-skip-if "" { *-*-* } { "-O0" "-Os" "-Og" "-Oz" } } */ int not_int_int (int x, int cond) diff --git a/gcc/testsuite/gcc.target/riscv/xtheadcondmov-mveqz-reg-eqz.c b/gcc/testsuite/gcc.target/riscv/xtheadcondmov-mveqz-reg-eqz.c index 8ef5869a89b6..d7227249e84c 100644 --- a/gcc/testsuite/gcc.target/riscv/xtheadcondmov-mveqz-reg-eqz.c +++ b/gcc/testsuite/gcc.target/riscv/xtheadcondmov-mveqz-reg-eqz.c @@ -1,7 +1,7 @@ /* { dg-do compile } */ /* { dg-options "-march=rv32gc_xtheadcondmov" { target { rv32 } } } */ /* { dg-options "-march=rv64gc_xtheadcondmov" { target { rv64 } } } */ -/* { dg-skip-if "" { *-*-* } { "-O0" "-Os" "-Og" } } */ +/* { dg-skip-if "" { *-*-* } { "-O0" "-Os" "-Og" "-Oz" } } */ int not_int_int (int x, int cond, int v) diff --git a/gcc/testsuite/gcc.target/riscv/xtheadcondmov-mveqz-reg-not.c b/gcc/testsuite/gcc.target/riscv/xtheadcondmov-mveqz-reg-not.c index f9568bee27fc..6cc98e36e71f 100644 --- a/gcc/testsuite/gcc.target/riscv/xtheadcondmov-mveqz-reg-not.c +++ b/gcc/testsuite/gcc.target/riscv/xtheadcondmov-mveqz-reg-not.c @@ -1,7 +1,7 @@ /* { dg-do compile } */ /* { dg-options "-march=rv32gc_xtheadcondmov" { target { rv32 } } } */ /* { dg-options "-march=rv64gc_xtheadcondmov" { target { rv64 } } } */ -/* { dg-skip-if "" { *-*-* } { "-O0" "-Os" "-Og" } } */ +/* { dg-skip-if "" { *-*-* } { "-O0" "-Os" "-Og" "-Oz" } } */ int not_int_int (int x, int cond, int v) diff --git a/gcc/testsuite/gcc.target/riscv/xtheadcondmov-mvnez-imm-cond.c b/gcc/testsuite/gcc.target/riscv/xtheadcondmov-mvnez-imm-cond.c index 8feddbeb79d9..7cce2c71d18a 100644 --- a/gcc/testsuite/gcc.target/riscv/xtheadcondmov-mvnez-imm-cond.c +++ b/gcc/testsuite/gcc.target/riscv/xtheadcondmov-mvnez-imm-cond.c @@ -1,7 +1,7 @@ /* { dg-do compile } */ /* { dg-options "-march=rv32gc_xtheadcondmov" { target { rv32 } } } */ /* { dg-options "-march=rv64gc_xtheadcondmov" { target { rv64 } } } */ -/* { dg-skip-if "" { *-*-* } { "-O0" "-Os" "-Og" } } */ +/* { dg-skip-if "" { *-*-* } { "-O0" "-Os" "-Og" "-Oz" } } */ int not_int_int (int x, int cond) diff --git a/gcc/testsuite/gcc.target/riscv/xtheadcondmov-mvnez-imm-nez.c b/gcc/testsuite/gcc.target/riscv/xtheadcondmov-mvnez-imm-nez.c index 7c08e20c25db..51b90bbc9a9e 100644 --- a/gcc/testsuite/gcc.target/riscv/xtheadcondmov-mvnez-imm-nez.c +++ b/gcc/testsuite/gcc.target/riscv/xtheadcondmov-mvnez-imm-nez.c @@ -1,7 +1,7 @@ /* { dg-do compile } */ /* { dg-options "-march=rv32gc_xtheadcondmov" { target { rv32 } } } */ /* { dg-options "-march=rv64gc_xtheadcondmov" { target { rv64 } } } */ -/* { dg-skip-if "" { *-*-* } { "-O0" "-Os" "-Og" } } */ +/* { dg-skip-if "" { *-*-* } { "-O0" "-Os" "-Og" "-Oz" } } */ int not_int_int (int x, int cond) diff --git a/gcc/testsuite/gcc.target/riscv/xtheadcondmov-mvnez-reg-cond.c b/gcc/testsuite/gcc.target/riscv/xtheadcondmov-mvnez-reg-cond.c index c1619509af93..d9bde61cd2b0 100644 --- a/gcc/testsuite/gcc.target/riscv/xtheadcondmov-mvnez-reg-cond.c +++ b/gcc/testsuite/gcc.target/riscv/xtheadcondmov-mvnez-reg-cond.c @@ -1,7 +1,7 @@ /* { dg-do compile } */ /* { dg-options "-march=rv32gc_xtheadcondmov" { target { rv32 } } } */ /* { dg-options "-march=rv64gc_xtheadcondmov" { target { rv64 } } } */ -/* { dg-skip-if "" { *-*-* } { "-O0" "-Os" "-Og" } } */ +/* { dg-skip-if "" { *-*-* } { "-O0" "-Os" "-Og" "-Oz" } } */ int not_int_int (int x, int cond, int v) diff --git a/gcc/testsuite/gcc.target/riscv/xtheadcondmov-mvnez-reg-nez.c b/gcc/testsuite/gcc.target/riscv/xtheadcondmov-mvnez-reg-nez.c index ff95a57927a6..c12501a752c0 100644 --- a/gcc/testsuite/gcc.target/riscv/xtheadcondmov-mvnez-reg-nez.c +++ b/gcc/testsuite/gcc.target/riscv/xtheadcondmov-mvnez-reg-nez.c @@ -1,7 +1,7 @@ /* { dg-do compile } */ /* { dg-options "-march=rv32gc_xtheadcondmov" { target { rv32 } } } */ /* { dg-options "-march=rv64gc_xtheadcondmov" { target { rv64 } } } */ -/* { dg-skip-if "" { *-*-* } { "-O0" "-Os" "-Og" } } */ +/* { dg-skip-if "" { *-*-* } { "-O0" "-Os" "-Og" "-Oz" } } */ int not_int_int (int x, int cond, int v)