diff options
author | Richard Sandiford <richard@codesourcery.com> | 2006-04-13 08:45:51 +0000 |
---|---|---|
committer | Richard Sandiford <richard@codesourcery.com> | 2006-04-13 08:45:51 +0000 |
commit | 3e3d140df42697feb7329b9ca2870e3228ee0c16 (patch) | |
tree | 0778ce134f8e15c2e2bae7914ad923c061a85861 | |
parent | 37538071c16fd621bfbdca62c000e80edcac5c5e (diff) |
gcc/testsuite/
* lib/target-supports.exp (check_missing_uclibc_feature): Make test
produce an error unless the required condition is known not to hold.
(check_effective_target_uclibc): New procedure.
(check_effective_target_uclibc_lax_strtofp): Likewise.
(check_effective_target_uclibc_dummy_wcsftime): Likewise.
libstdc++-v3/testsuite/
* 22_locale/time_put/put/wchar_t/1.cc: XFAIL if uclibc_dummy_wcsftime.
* 22_locale/time_put/put/wchar_t/5.cc: Likewise.
* 22_locale/time_put/put/wchar_t/9.cc: Likewise.
* 22_locale/time_put/put/wchar_t/10.cc: Likewise.
* 22_locale/num_get/get/wchar_t/2.cc: XFAIL if uclibc_lax_strtofp.
* 22_locale/num_get/get/char/2.cc: Likewise.
* 27_io/basic_istream/extractors_arithmetic/wchar_t/12.cc: Likewise.
* 27_io/basic_istream/extractors_arithmetic/wchar_t/09.cc: Likewise.
* 27_io/basic_istream/extractors_arithmetic/char/12.cc: Likewise.
* 27_io/basic_istream/extractors_arithmetic/char/09.cc: Likewise.
* 27_io/basic_ostream/inserters_arithmetic/wchar_t/6.cc: Likewise.
* 27_io/basic_ostream/inserters_arithmetic/char/6.cc: Likewise.
* 26_numerics/cmath/c99_classification_macros_c++.cc: XFAIL
for uClibc.
* 26_numerics/cmath/c99_classification_macros_c.cc: Likewise.
git-svn-id: https://gcc.gnu.org/svn/gcc/branches/csl/coldfire-4_1@112916 138bc75d-0d04-0410-961f-82ee72b054a4
16 files changed, 86 insertions, 12 deletions
diff --git a/ChangeLog.csl b/ChangeLog.csl index c48c484e321..59e9318ad99 100644 --- a/ChangeLog.csl +++ b/ChangeLog.csl @@ -1,3 +1,29 @@ +2006-04-13 Richard Sandiford <richard@codesourcery.com> + + gcc/testsuite/ + * lib/target-supports.exp (check_missing_uclibc_feature): Make test + produce an error unless the required condition is known not to hold. + (check_effective_target_uclibc): New procedure. + (check_effective_target_uclibc_lax_strtofp): Likewise. + (check_effective_target_uclibc_dummy_wcsftime): Likewise. + + libstdc++-v3/testsuite/ + * 22_locale/time_put/put/wchar_t/1.cc: XFAIL if uclibc_dummy_wcsftime. + * 22_locale/time_put/put/wchar_t/5.cc: Likewise. + * 22_locale/time_put/put/wchar_t/9.cc: Likewise. + * 22_locale/time_put/put/wchar_t/10.cc: Likewise. + * 22_locale/num_get/get/wchar_t/2.cc: XFAIL if uclibc_lax_strtofp. + * 22_locale/num_get/get/char/2.cc: Likewise. + * 27_io/basic_istream/extractors_arithmetic/wchar_t/12.cc: Likewise. + * 27_io/basic_istream/extractors_arithmetic/wchar_t/09.cc: Likewise. + * 27_io/basic_istream/extractors_arithmetic/char/12.cc: Likewise. + * 27_io/basic_istream/extractors_arithmetic/char/09.cc: Likewise. + * 27_io/basic_ostream/inserters_arithmetic/wchar_t/6.cc: Likewise. + * 27_io/basic_ostream/inserters_arithmetic/char/6.cc: Likewise. + * 26_numerics/cmath/c99_classification_macros_c++.cc: XFAIL + for uClibc. + * 26_numerics/cmath/c99_classification_macros_c.cc: Likewise. + 2006-04-08 Richard Sandiford <richard@codesourcery.com> * gcc/regrename.c (scan_rtx_address): Use REG_MODE_OK_FOR_INDEX_P diff --git a/gcc/testsuite/lib/target-supports.exp b/gcc/testsuite/lib/target-supports.exp index 9870369b460..830f2943e61 100644 --- a/gcc/testsuite/lib/target-supports.exp +++ b/gcc/testsuite/lib/target-supports.exp @@ -80,19 +80,16 @@ proc check_no_compiler_messages {prop args} { return $value } -# Return true if this is a uclibc target and if the uclibc feature +# Return true if this is a uClibc target and if the uClibc feature # described by __$feature__ is not present. proc check_missing_uclibc_feature {feature} { - if {[check_no_compiler_messages $feature object " + return [check_no_compiler_messages $feature object " #include <features.h> - #if defined (__UCLIBC__) && !defined (__${feature}__) + #if !defined (__UCLIBC__) || defined (__${feature}__) #error FOO #endif - "]} { - return 0 - } - return 1 + "] } ############################### @@ -1300,6 +1297,36 @@ proc check_effective_target_wchar { } { return 1 } +# Return true if this is a uClibc target. + +proc check_effective_target_uclibc {} { + return [check_no_compiler_messages uclibc object { + #include <features.h> + #if !defined (__UCLIBC__) + #error FOO + #endif + }] +} + +# Return 1 if +# (a) this is a uClibc target; and +# (a) an error of a few ULP is expected in string to floating-point +# conversion functions; and +# (c) overflow is not always detected correctly by those functions. + +proc check_effective_target_uclibc_lax_strtofp {} { + # By default, assume that all uClibc targets suffer from this. + return [check_effective_target_uclibc] +} + +# Return 1 if this is a uClibc target for which wcsftime is a dummy +# function that always returns 0. + +proc check_effective_target_uclibc_dummy_wcsftime {} { + # By default, assume that all uClibc targets suffer from this. + return [check_effective_target_uclibc] +} + # Return 1 if the target matches the effective target 'arg', 0 otherwise. # This can be used with any check_* proc that takes no argument and # returns only 1 or 0. It could be used with check_* procs that take diff --git a/libstdc++-v3/testsuite/22_locale/num_get/get/char/2.cc b/libstdc++-v3/testsuite/22_locale/num_get/get/char/2.cc index 98e13612222..9a89a13d51b 100644 --- a/libstdc++-v3/testsuite/22_locale/num_get/get/char/2.cc +++ b/libstdc++-v3/testsuite/22_locale/num_get/get/char/2.cc @@ -20,6 +20,8 @@ // 22.2.2.1.1 num_get members +// { dg-do run { xfail uclibc_lax_strtofp } } + #include <locale> #include <sstream> #include <testsuite_hooks.h> diff --git a/libstdc++-v3/testsuite/22_locale/num_get/get/wchar_t/2.cc b/libstdc++-v3/testsuite/22_locale/num_get/get/wchar_t/2.cc index 782275d1c82..ea79e44dc23 100644 --- a/libstdc++-v3/testsuite/22_locale/num_get/get/wchar_t/2.cc +++ b/libstdc++-v3/testsuite/22_locale/num_get/get/wchar_t/2.cc @@ -20,6 +20,8 @@ // 22.2.2.1.1 num_get members +// { dg-do run { xfail uclibc_lax_strtofp } } + #include <locale> #include <sstream> #include <testsuite_hooks.h> diff --git a/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/1.cc b/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/1.cc index 9dd77260a61..644165e3c4f 100644 --- a/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/1.cc +++ b/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/1.cc @@ -20,6 +20,8 @@ // 22.2.5.3.1 time_put members +// { dg-do run { xfail uclibc_dummy_wcsftime } } + #include <locale> #include <sstream> #include <testsuite_hooks.h> diff --git a/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/10.cc b/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/10.cc index f1c91b171e7..8df49d4c3fe 100644 --- a/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/10.cc +++ b/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/10.cc @@ -20,6 +20,8 @@ // 22.2.5.3.1 time_put members +// { dg-do run { xfail uclibc_dummy_wcsftime } } + #include <locale> #include <sstream> #include <testsuite_hooks.h> diff --git a/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/5.cc b/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/5.cc index 4d30717cc86..9e8a14c7dc2 100644 --- a/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/5.cc +++ b/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/5.cc @@ -20,6 +20,8 @@ // 22.2.5.3.1 time_put members +// { dg-do run { xfail uclibc_dummy_wcsftime } } + #include <locale> #include <sstream> #include <testsuite_hooks.h> diff --git a/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/9.cc b/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/9.cc index 3a3e01c633b..850c9ed5971 100644 --- a/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/9.cc +++ b/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/9.cc @@ -20,6 +20,8 @@ // 22.2.5.3.1 time_put members +// { dg-do run { xfail uclibc_dummy_wcsftime } } + #include <locale> #include <sstream> #include <testsuite_hooks.h> diff --git a/libstdc++-v3/testsuite/26_numerics/cmath/c99_classification_macros_c++.cc b/libstdc++-v3/testsuite/26_numerics/cmath/c99_classification_macros_c++.cc index fbbfbfd4ef0..5455008c428 100644 --- a/libstdc++-v3/testsuite/26_numerics/cmath/c99_classification_macros_c++.cc +++ b/libstdc++-v3/testsuite/26_numerics/cmath/c99_classification_macros_c++.cc @@ -27,7 +27,8 @@ // invalidate any other reasons why the executable file might be covered by // the GNU General Public License. -// { dg-do compile } +// { dg-do compile { xfail uclibc } } +// { dg-excess-errors "" { target uclibc } } #include <cmath> diff --git a/libstdc++-v3/testsuite/26_numerics/cmath/c99_classification_macros_c.cc b/libstdc++-v3/testsuite/26_numerics/cmath/c99_classification_macros_c.cc index 5af904b1190..a9cd0584a33 100644 --- a/libstdc++-v3/testsuite/26_numerics/cmath/c99_classification_macros_c.cc +++ b/libstdc++-v3/testsuite/26_numerics/cmath/c99_classification_macros_c.cc @@ -27,8 +27,8 @@ // invalidate any other reasons why the executable file might be covered by // the GNU General Public License. -// { dg-do compile { xfail *-*-linux* *-*-darwin* } } -// { dg-excess-errors "" { target *-*-linux* *-*-darwin* } } +// { dg-do compile { xfail { { *-*-linux* *-*-darwin* } || uclibc } } } +// { dg-excess-errors "" { target { { *-*-linux* *-*-darwin* } || uclibc } } } #include <math.h> diff --git a/libstdc++-v3/testsuite/27_io/basic_istream/extractors_arithmetic/char/09.cc b/libstdc++-v3/testsuite/27_io/basic_istream/extractors_arithmetic/char/09.cc index 5da83724b6c..bf5089fe8af 100644 --- a/libstdc++-v3/testsuite/27_io/basic_istream/extractors_arithmetic/char/09.cc +++ b/libstdc++-v3/testsuite/27_io/basic_istream/extractors_arithmetic/char/09.cc @@ -20,6 +20,8 @@ // 27.6.1.2.2 arithmetic extractors +// { dg-do run { xfail uclibc_lax_strtofp } } + #include <istream> #include <sstream> #include <locale> diff --git a/libstdc++-v3/testsuite/27_io/basic_istream/extractors_arithmetic/char/12.cc b/libstdc++-v3/testsuite/27_io/basic_istream/extractors_arithmetic/char/12.cc index 21e2940417f..b441315bae5 100644 --- a/libstdc++-v3/testsuite/27_io/basic_istream/extractors_arithmetic/char/12.cc +++ b/libstdc++-v3/testsuite/27_io/basic_istream/extractors_arithmetic/char/12.cc @@ -23,7 +23,7 @@ // XXX This test fails on sparc-solaris2 because of a bug in libc // XXX sscanf for very long input. See: // XXX http://gcc.gnu.org/ml/gcc/2002-12/msg01422.html -// { dg-do run { xfail sparc*-*-solaris2* } } +// { dg-do run { xfail { { sparc*-*-solaris2* } || uclibc_lax_strtofp } } } #include <istream> #include <sstream> diff --git a/libstdc++-v3/testsuite/27_io/basic_istream/extractors_arithmetic/wchar_t/09.cc b/libstdc++-v3/testsuite/27_io/basic_istream/extractors_arithmetic/wchar_t/09.cc index 26021c2379f..a5e9cb14303 100644 --- a/libstdc++-v3/testsuite/27_io/basic_istream/extractors_arithmetic/wchar_t/09.cc +++ b/libstdc++-v3/testsuite/27_io/basic_istream/extractors_arithmetic/wchar_t/09.cc @@ -18,6 +18,8 @@ // 27.6.1.2.2 arithmetic extractors +// { dg-do run { xfail uclibc_lax_strtofp } } + #include <istream> #include <sstream> #include <locale> diff --git a/libstdc++-v3/testsuite/27_io/basic_istream/extractors_arithmetic/wchar_t/12.cc b/libstdc++-v3/testsuite/27_io/basic_istream/extractors_arithmetic/wchar_t/12.cc index 6ffae088125..652df20c0e9 100644 --- a/libstdc++-v3/testsuite/27_io/basic_istream/extractors_arithmetic/wchar_t/12.cc +++ b/libstdc++-v3/testsuite/27_io/basic_istream/extractors_arithmetic/wchar_t/12.cc @@ -21,7 +21,7 @@ // XXX This test fails on sparc-solaris2 because of a bug in libc // XXX sscanf for very long input. See: // XXX http://gcc.gnu.org/ml/gcc/2002-12/msg01422.html -// { dg-do run { xfail sparc*-*-solaris2* } } +// { dg-do run { xfail { { sparc*-*-solaris2* } || uclibc_lax_strtofp } } } #include <istream> #include <sstream> diff --git a/libstdc++-v3/testsuite/27_io/basic_ostream/inserters_arithmetic/char/6.cc b/libstdc++-v3/testsuite/27_io/basic_ostream/inserters_arithmetic/char/6.cc index dac5afd4b03..278a3c3742a 100644 --- a/libstdc++-v3/testsuite/27_io/basic_ostream/inserters_arithmetic/char/6.cc +++ b/libstdc++-v3/testsuite/27_io/basic_ostream/inserters_arithmetic/char/6.cc @@ -19,6 +19,8 @@ // Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, // USA. +// { dg-do run { xfail uclibc_lax_strtofp } } + #include <cmath> // for abs #include <cfloat> // for DBL_EPSILON #include <sstream> diff --git a/libstdc++-v3/testsuite/27_io/basic_ostream/inserters_arithmetic/wchar_t/6.cc b/libstdc++-v3/testsuite/27_io/basic_ostream/inserters_arithmetic/wchar_t/6.cc index b25b3f0288d..4940c7abb26 100644 --- a/libstdc++-v3/testsuite/27_io/basic_ostream/inserters_arithmetic/wchar_t/6.cc +++ b/libstdc++-v3/testsuite/27_io/basic_ostream/inserters_arithmetic/wchar_t/6.cc @@ -16,6 +16,8 @@ // Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, // USA. +// { dg-do run { xfail uclibc_lax_strtofp } } + #include <cmath> // for abs #include <cfloat> // for DBL_EPSILON #include <sstream> |