[v3] cleanup testsuite for newlib targets

Richard Guenther richard.guenther@gmail.com
Fri Mar 23 10:41:00 GMT 2007


On 3/23/07, Richard Guenther <richard.guenther@gmail.com> wrote:
> On 3/23/07, Benjamin Kosnik <bkoz@redhat.com> wrote:
> >
> > > It looks like this breaks tramp3d-v4.cpp which includes fenv.h:
> > >
> > > /gcc/spec/scripts/c++bench/tramp3d/tramp3d-v4.cpp: In function 'void
> > > enable_fp_exceptions()':
> > > /gcc/spec/scripts/c++bench/tramp3d/tramp3d-v4.cpp:51965: error:
> > > 'fexcept_t' was not declared in this scope
> > > /gcc/spec/scripts/c++bench/tramp3d/tramp3d-v4.cpp:51965: error:
> > > expected `;' before 'f'
> > > /gcc/spec/scripts/c++bench/tramp3d/tramp3d-v4.cpp:51966: error: 'f'
> > > was not declared in this scope
> > > /gcc/spec/scripts/c++bench/tramp3d/tramp3d-v4.cpp:51966: error:
> > > 'FE_INVALID' was not declared in this scope
> > > /gcc/spec/scripts/c++bench/tramp3d/tramp3d-v4.cpp:51966: error:
> > > 'FE_DIVBYZERO' was not declared in this scope
> > > /gcc/spec/scripts/c++bench/tramp3d/tramp3d-v4.cpp:51966: error:
> > > 'FE_OVERFLOW' was not declared in this scope
> > > /gcc/spec/scripts/c++bench/tramp3d/tramp3d-v4.cpp:51966: error:
> > > 'FE_UNDERFLOW' was not declared in this scope
> > > /gcc/spec/scripts/c++bench/tramp3d/tramp3d-v4.cpp:51966: error:
> > > 'fegetexceptflag' was not declared in this scope
> > > /gcc/spec/scripts/c++bench/tramp3d/tramp3d-v4.cpp:51967: error:
> > > 'fesetexceptflag' was not declared in this scope
> > > /gcc/spec/scripts/c++bench/tramp3d/tramp3d-v4.cpp: In function 'void
> > > disable_fp_exceptions()':
> > > /gcc/spec/scripts/c++bench/tramp3d/tramp3d-v4.cpp:51971: error:
> > > 'FE_INEXACT' was not declared in this scope
> > > /gcc/spec/scripts/c++bench/tramp3d/tramp3d-v4.cpp:51971: error:
> > > 'FE_DIVBYZERO' was not declared in this scope
> > > /gcc/spec/scripts/c++bench/tramp3d/tramp3d-v4.cpp:51971: error:
> > > 'FE_UNDERFLOW' was not declared in this scope
> > > /gcc/spec/scripts/c++bench/tramp3d/tramp3d-v4.cpp:51971: error:
> > > 'FE_OVERFLOW' was not declared in this scope
> > > /gcc/spec/scripts/c++bench/tramp3d/tramp3d-v4.cpp:51971: error:
> > > 'FE_INVALID' was not declared in this scope
> > > /gcc/spec/scripts/c++bench/tramp3d/tramp3d-v4.cpp:51971: error:
> > > 'feclearexcept' was not declared in this scope
> > >
> > > How am I supposed to fix this?
> >
> > Hey Richard.
> >
> > A small reproducer would be appreciated.
>
> This:
>
> #include <fenv.h>
>
> void enable_fp_exceptions(void)
> {
>   fexcept_t f;
>   fegetexceptflag(&f, FE_INVALID|FE_DIVBYZERO|FE_OVERFLOW|FE_UNDERFLOW);
>   fesetexceptflag(&f, FE_INVALID|FE_DIVBYZERO|FE_OVERFLOW|FE_UNDERFLOW);
> }
>
> no longer works with g++ (it still does with gcc).

Ah, the offender seems to be (I overlooked that):

/gcc/spec/sb-vangelis-head-64/x86_64/install-200703230136/lib/gcc/x86_64-unknown-linux-gnu/4.3.0/../../../../include/c++/4.3.0/c++0x_warning.h:36:2:
error: #error This file requires compiler and library support for the
upcoming ISO C++ standard, C++0x. This support is currently
experimental, and must be enabled with the -std=c++0x or -std=gnu++0x
compiler options.

Richard.



More information about the Gcc-patches mailing list