This is the mail archive of the
libstdc++@gcc.gnu.org
mailing list for the libstdc++ project.
Re: [v3] cleanup testsuite for newlib targets
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).
Richard.