From c938d9eb3c070db75100f4a1d3f4aedaea9068fe Mon Sep 17 00:00:00 2001 From: janis Date: Fri, 5 Dec 2008 21:05:53 +0000 Subject: [PATCH] * lib/target-supports.exp (check_effective_target_hard_dfp): New. * gcc.dg/dfp/convert-dfp-round.c: Skip for hard_dfp. * gcc.dg/dfp/fe-binop.c: Ditto. * gcc.dg/dfp/fe-convert-1.c: Ditto. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@142494 138bc75d-0d04-0410-961f-82ee72b054a4 --- gcc/testsuite/ChangeLog | 7 +++++++ gcc/testsuite/gcc.dg/dfp/convert-dfp-round.c | 1 + gcc/testsuite/gcc.dg/dfp/fe-binop.c | 1 + gcc/testsuite/gcc.dg/dfp/fe-convert-1.c | 1 + gcc/testsuite/lib/target-supports.exp | 9 +++++++++ 5 files changed, 19 insertions(+) diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 6a0d2c6933d..f4843d5b507 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,10 @@ +2008-12-05 Janis Johnson + + * lib/target-supports.exp (check_effective_target_hard_dfp): New. + * gcc.dg/dfp/convert-dfp-round.c: Skip for hard_dfp. + * gcc.dg/dfp/fe-binop.c: Ditto. + * gcc.dg/dfp/fe-convert-1.c: Ditto. + 2008-12-05 Catherine Moore * gcc-target/mips/mips-nonpic: New testsuite. diff --git a/gcc/testsuite/gcc.dg/dfp/convert-dfp-round.c b/gcc/testsuite/gcc.dg/dfp/convert-dfp-round.c index 87867fad8b2..9833abb7ff0 100644 --- a/gcc/testsuite/gcc.dg/dfp/convert-dfp-round.c +++ b/gcc/testsuite/gcc.dg/dfp/convert-dfp-round.c @@ -1,4 +1,5 @@ /* { dg-options "-O0 -std=gnu99" } */ +/* { dg-skip-if "test is for emulation" { hard_dfp } { "*" } { "" } } */ /* N1150 5.2: Conversions among decimal floating types and between decimal floating types and generic floating types. diff --git a/gcc/testsuite/gcc.dg/dfp/fe-binop.c b/gcc/testsuite/gcc.dg/dfp/fe-binop.c index 007bc6e44dd..23f137818ed 100644 --- a/gcc/testsuite/gcc.dg/dfp/fe-binop.c +++ b/gcc/testsuite/gcc.dg/dfp/fe-binop.c @@ -1,4 +1,5 @@ /* { dg-options "-std=gnu99" } */ +/* { dg-skip-if "test is for emulation" { hard_dfp } { "*" } { "" } } */ /* Touch tests that check for raising appropriate exceptions for binary arithmetic operations on decimal float values. */ diff --git a/gcc/testsuite/gcc.dg/dfp/fe-convert-1.c b/gcc/testsuite/gcc.dg/dfp/fe-convert-1.c index 6ea632d427f..f65cf7870ae 100644 --- a/gcc/testsuite/gcc.dg/dfp/fe-convert-1.c +++ b/gcc/testsuite/gcc.dg/dfp/fe-convert-1.c @@ -1,4 +1,5 @@ /* { dg-options "-std=gnu99" } */ +/* { dg-skip-if "test is for emulation" { hard_dfp } { "*" } { "" } } */ /* Check that appropriate exceptions are raised for conversions involving decimal float values. */ diff --git a/gcc/testsuite/lib/target-supports.exp b/gcc/testsuite/lib/target-supports.exp index cc62a97ea7d..a297480a62a 100644 --- a/gcc/testsuite/lib/target-supports.exp +++ b/gcc/testsuite/lib/target-supports.exp @@ -2656,3 +2656,12 @@ proc check_effective_target_pow10 { } { } } "-lm" ] } + +# Return 1 if current options generate DFP instructions, 0 otherwise. + +proc check_effective_target_hard_dfp {} { + return [check_no_messages_and_pattern hard_dfp "!adddd3" assembly { + _Decimal64 x, y, z; + void foo (void) { z = x + y; } + }] +} -- 2.11.0