From 3eaf74beac9c587edab13aa946b52a09b759d7fe Mon Sep 17 00:00:00 2001 From: Dimitar Dimitrov <dimitar@dinux.eu> Date: Wed, 4 Dec 2024 17:51:11 +0200 Subject: [PATCH] testsuite: RISC-V: Skip tests using -mcpu= for ILP32E/ILP64E ABIs The tests are specifying -mcpu with D extension, which is not compatible with the ILP32E and ILP64E ABIs. Fix by skipping the tests if toolchain's default ABI is an E variant. gcc/testsuite/ChangeLog: * gcc.target/riscv/pr109508.c: Skip for E ABI. * gcc.target/riscv/pr114139.c: Ditto. Signed-off-by: Dimitar Dimitrov <dimitar@dinux.eu> --- gcc/testsuite/gcc.target/riscv/pr109508.c | 2 +- gcc/testsuite/gcc.target/riscv/pr114139.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/gcc/testsuite/gcc.target/riscv/pr109508.c b/gcc/testsuite/gcc.target/riscv/pr109508.c index 65f291e17ed8..9ed06a4daed4 100644 --- a/gcc/testsuite/gcc.target/riscv/pr109508.c +++ b/gcc/testsuite/gcc.target/riscv/pr109508.c @@ -1,4 +1,4 @@ -/* { dg-do compile } */ +/* { dg-do compile { target { ! riscv_abi_e } } } */ /* { dg-options "-mcpu=sifive-s76" } */ typedef char __attribute__((__vector_size__ (1))) V; diff --git a/gcc/testsuite/gcc.target/riscv/pr114139.c b/gcc/testsuite/gcc.target/riscv/pr114139.c index 1d4eeb65f5c5..d4e7593f5c04 100644 --- a/gcc/testsuite/gcc.target/riscv/pr114139.c +++ b/gcc/testsuite/gcc.target/riscv/pr114139.c @@ -1,4 +1,4 @@ -/* { dg-do compile } */ +/* { dg-do compile { target { ! riscv_abi_e } } } */ /* { dg-options "-O2 -fpic -mexplicit-relocs -mcpu=sifive-p450" } */ static void *p; -- GitLab