X-Git-Url: http://nsz.repo.hu/git/?a=blobdiff_plain;f=src%2Fcommon%2Fmtest.h;h=d390d03fcf79fb196a824a04b30fb2027f85689c;hb=2b9639f0f09c5b8bcd245fac49b2fb9da23b0302;hp=9218a7538e1a7c39658668c663f3a0d5e019c475;hpb=cfa23cc1bd01f5c44d7746b8b1839f84d5e1b6eb;p=libc-test diff --git a/src/common/mtest.h b/src/common/mtest.h index 9218a75..d390d03 100644 --- a/src/common/mtest.h +++ b/src/common/mtest.h @@ -102,10 +102,21 @@ float ulperrl(long double got, long double want, float dwant); static int checkexcept(int got, int want, int r) { if (r == RN) +#if defined CHECK_INEXACT + return got == want; +#elif defined CHECK_INEXACT_OMISSION return got == want || got == (want|INEXACT); +#else + return (got|INEXACT) == (want|INEXACT); +#endif return (got|INEXACT|UNDERFLOW) == (want|INEXACT|UNDERFLOW); } +static int checkexceptall(int got, int want, int r) +{ + return got == want; +} + static int checkulp(float d, int r) { // TODO: we only care about >=1.5 ulp errors for now, should be 1.0