Message ID | 400dc01d-fcb1-43f5-873e-3c3cfdacb987@gjlay.de |
---|---|
State | New |
Headers | show |
Series | [avr] Skip some tests that don't work on avr | expand |
On 12/3/24 3:57 AM, Georg-Johann Lay wrote: > This patch skips some tests that don't work on avr. > > Ok for trunk? > > Johann > > -- > > AVR: Skip some test cases that don't work for it. > > gcc/testsuite/ > * gcc.c-torture/execute/ieee/cdivchkd.x: New file. > * gcc.c-torture/execute/ieee/cdivchkf.x: New file. > * gcc.dg/flex-array-counted-by.c: Skip on avr. > * gcc.dg/fold-copysign-1.c [avr]: Add -mdouble=64. Do you think there's more of these likely to pop up? If so, then I'd recommend some kind of a test in target-supports.exp and isolate the avr-isms there. If this is about it, then it's OK. jeff
Am 03.12.24 um 15:36 schrieb Jeff Law: > > On 12/3/24 3:57 AM, Georg-Johann Lay wrote: >> This patch skips some tests that don't work on avr. >> >> Ok for trunk? >> >> Johann >> >> -- >> >> AVR: Skip some test cases that don't work for it. >> >> gcc/testsuite/ >> * gcc.c-torture/execute/ieee/cdivchkd.x: New file. >> * gcc.c-torture/execute/ieee/cdivchkf.x: New file. >> * gcc.dg/flex-array-counted-by.c: Skip on avr. >> * gcc.dg/fold-copysign-1.c [avr]: Add -mdouble=64. > Do you think there's more of these likely to pop up? If so, then I'd > recommend some kind of a test in target-supports.exp and isolate the > avr-isms there. If this is about it, then it's OK. > > jeff Yes, there are likely to be more. Though there's not one single reason for why some tests are failing on avr. For example, one of the above tests failed because wchar_t support is incomplete, an other one failed because ilogb is missing, etc. So I don't see what exactly such a dg-require test should test for. But flex-array-counted-by.c would better do dg-require wchar which is already there. Johann
On 12/3/24 7:45 AM, Georg-Johann Lay wrote: > Am 03.12.24 um 15:36 schrieb Jeff Law: >> >> On 12/3/24 3:57 AM, Georg-Johann Lay wrote: >>> This patch skips some tests that don't work on avr. >>> >>> Ok for trunk? >>> >>> Johann >>> >>> -- >>> >>> AVR: Skip some test cases that don't work for it. >>> >>> gcc/testsuite/ >>> * gcc.c-torture/execute/ieee/cdivchkd.x: New file. >>> * gcc.c-torture/execute/ieee/cdivchkf.x: New file. >>> * gcc.dg/flex-array-counted-by.c: Skip on avr. >>> * gcc.dg/fold-copysign-1.c [avr]: Add -mdouble=64. >> Do you think there's more of these likely to pop up? If so, then I'd >> recommend some kind of a test in target-supports.exp and isolate the >> avr-isms there. If this is about it, then it's OK. >> >> jeff > > Yes, there are likely to be more. > > Though there's not one single reason for why some tests are failing > on avr. For example, one of the above tests failed because wchar_t > support is incomplete, an other one failed because ilogb is missing, > etc. Got it. So it's really about missing things in the target environment. > > So I don't see what exactly such a dg-require test should test for. Probably not a good one that would cover all of what you're trying to do. > > But flex-array-counted-by.c would better do dg-require wchar which > is already there. So let's go with the dg-require wchar for that. When you see commonality between reasons to skip, try to create a suitable target-support.exp test. But when there isn't any obvious commonality, go ahead with your skip approach. Thanks and sorry for the delays. jeff
AVR: Skip some test cases that don't work for it. gcc/testsuite/ * gcc.c-torture/execute/ieee/cdivchkd.x: New file. * gcc.c-torture/execute/ieee/cdivchkf.x: New file. * gcc.dg/flex-array-counted-by.c: Skip on avr. * gcc.dg/fold-copysign-1.c [avr]: Add -mdouble=64. diff --git a/gcc/testsuite/gcc.c-torture/execute/ieee/cdivchkd.x b/gcc/testsuite/gcc.c-torture/execute/ieee/cdivchkd.x new file mode 100644 index 00000000000..7c575fceae8 --- /dev/null +++ b/gcc/testsuite/gcc.c-torture/execute/ieee/cdivchkd.x @@ -0,0 +1,5 @@ +if [istarget "avr-*-*"] { + # Floating-point support is incomplete. + return 1 +} +return 0 diff --git a/gcc/testsuite/gcc.c-torture/execute/ieee/cdivchkf.x b/gcc/testsuite/gcc.c-torture/execute/ieee/cdivchkf.x new file mode 100644 index 00000000000..7c575fceae8 --- /dev/null +++ b/gcc/testsuite/gcc.c-torture/execute/ieee/cdivchkf.x @@ -0,0 +1,5 @@ +if [istarget "avr-*-*"] { + # Floating-point support is incomplete. + return 1 +} +return 0 diff --git a/gcc/testsuite/gcc.dg/flex-array-counted-by.c b/gcc/testsuite/gcc.dg/flex-array-counted-by.c index e8b54c2de1c..4758877c517 100644 --- a/gcc/testsuite/gcc.dg/flex-array-counted-by.c +++ b/gcc/testsuite/gcc.dg/flex-array-counted-by.c @@ -1,6 +1,7 @@ /* Testing the correct usage of attribute counted_by. */ /* { dg-do compile } */ /* { dg-options "-O2" } */ +/* { dg-skip-if "wchar support is incomplete" { "avr-*-*" } } */ #include <wchar.h> diff --git a/gcc/testsuite/gcc.dg/fold-copysign-1.c b/gcc/testsuite/gcc.dg/fold-copysign-1.c index 96b80c73379..1f5141b1c5d 100644 --- a/gcc/testsuite/gcc.dg/fold-copysign-1.c +++ b/gcc/testsuite/gcc.dg/fold-copysign-1.c @@ -1,6 +1,7 @@ /* { dg-do compile } */ /* { dg-options "-O -fdump-tree-cddce1" } */ /* { dg-additional-options "-msse -mfpmath=sse" { target { { i?86-*-* x86_64-*-* } && ilp32 } } } */ +/* { dg-additional-options "-mdouble=64" { target { avr-*-* } } } */ double foo (double x) {