y = ceil(p->x);
e = fetestexcept(INEXACT|INVALID|DIVBYZERO|UNDERFLOW|OVERFLOW);
- if (!checkexceptall(e, p->e, p->r)) {
+ if (!checkexceptall(e, p->e, p->r) && (e|INEXACT) != p->e) {
printf("%s:%d: bad fp exception: %s ceil(%a)=%a, want %s",
p->file, p->line, rstr(p->r), p->x, p->y, estr(p->e));
printf(" got %s\n", estr(e));
y = ceilf(p->x);
e = fetestexcept(INEXACT|INVALID|DIVBYZERO|UNDERFLOW|OVERFLOW);
- if (!checkexceptall(e, p->e, p->r)) {
+ if (!checkexceptall(e, p->e, p->r) && (e|INEXACT) != p->e) {
printf("%s:%d: bad fp exception: %s ceilf(%a)=%a, want %s",
p->file, p->line, rstr(p->r), p->x, p->y, estr(p->e));
printf(" got %s\n", estr(e));
y = ceill(p->x);
e = fetestexcept(INEXACT|INVALID|DIVBYZERO|UNDERFLOW|OVERFLOW);
- if (!checkexceptall(e, p->e, p->r)) {
+ if (!checkexceptall(e, p->e, p->r) && (e|INEXACT) != p->e) {
printf("%s:%d: bad fp exception: %s ceill(%La)=%La, want %s",
p->file, p->line, rstr(p->r), p->x, p->y, estr(p->e));
printf(" got %s\n", estr(e));
y = floor(p->x);
e = fetestexcept(INEXACT|INVALID|DIVBYZERO|UNDERFLOW|OVERFLOW);
- if (!checkexceptall(e, p->e, p->r)) {
+ if (!checkexceptall(e, p->e, p->r) && (e|INEXACT) != p->e) {
printf("%s:%d: bad fp exception: %s floor(%a)=%a, want %s",
p->file, p->line, rstr(p->r), p->x, p->y, estr(p->e));
printf(" got %s\n", estr(e));
y = floorf(p->x);
e = fetestexcept(INEXACT|INVALID|DIVBYZERO|UNDERFLOW|OVERFLOW);
- if (!checkexceptall(e, p->e, p->r)) {
+ if (!checkexceptall(e, p->e, p->r) && (e|INEXACT) != p->e) {
printf("%s:%d: bad fp exception: %s floorf(%a)=%a, want %s",
p->file, p->line, rstr(p->r), p->x, p->y, estr(p->e));
printf(" got %s\n", estr(e));
y = floorl(p->x);
e = fetestexcept(INEXACT|INVALID|DIVBYZERO|UNDERFLOW|OVERFLOW);
- if (!checkexceptall(e, p->e, p->r)) {
+ if (!checkexceptall(e, p->e, p->r) && (e|INEXACT) != p->e) {
printf("%s:%d: bad fp exception: %s floorl(%La)=%La, want %s",
p->file, p->line, rstr(p->r), p->x, p->y, estr(p->e));
printf(" got %s\n", estr(e));
yi = llround(p->x);
e = fetestexcept(INEXACT|INVALID|DIVBYZERO|UNDERFLOW|OVERFLOW);
- if (!checkexcept(e, p->e, p->r)) {
+ if (!checkexcept(e, p->e, p->r) && (e|INEXACT) != p->e) {
printf("%s:%d: bad fp exception: %s llround(%a)=%lld, want %s",
p->file, p->line, rstr(p->r), p->x, p->i, estr(p->e));
printf(" got %s\n", estr(e));
yi = llroundf(p->x);
e = fetestexcept(INEXACT|INVALID|DIVBYZERO|UNDERFLOW|OVERFLOW);
- if (!checkexcept(e, p->e, p->r)) {
+ if (!checkexcept(e, p->e, p->r) && (e|INEXACT) != p->e) {
printf("%s:%d: bad fp exception: %s llroundf(%a)=%lld, want %s",
p->file, p->line, rstr(p->r), p->x, p->i, estr(p->e));
printf(" got %s\n", estr(e));
yi = llroundl(p->x);
e = fetestexcept(INEXACT|INVALID|DIVBYZERO|UNDERFLOW|OVERFLOW);
- if (!checkexcept(e, p->e, p->r)) {
+ if (!checkexcept(e, p->e, p->r) && (e|INEXACT) != p->e) {
printf("%s:%d: bad fp exception: %s llroundl(%La)=%lld, want %s",
p->file, p->line, rstr(p->r), p->x, p->i, estr(p->e));
printf(" got %s\n", estr(e));
yi = lround(p->x);
e = fetestexcept(INEXACT|INVALID|DIVBYZERO|UNDERFLOW|OVERFLOW);
- if (!checkexcept(e, p->e, p->r)) {
+ if (!checkexcept(e, p->e, p->r) && (e|INEXACT) != p->e) {
printf("%s:%d: bad fp exception: %s lround(%a)=%lld, want %s",
p->file, p->line, rstr(p->r), p->x, p->i, estr(p->e));
printf(" got %s\n", estr(e));
yi = lroundf(p->x);
e = fetestexcept(INEXACT|INVALID|DIVBYZERO|UNDERFLOW|OVERFLOW);
- if (!checkexcept(e, p->e, p->r)) {
+ if (!checkexcept(e, p->e, p->r) && (e|INEXACT) != p->e) {
printf("%s:%d: bad fp exception: %s lroundf(%a)=%lld, want %s",
p->file, p->line, rstr(p->r), p->x, p->i, estr(p->e));
printf(" got %s\n", estr(e));
yi = lroundl(p->x);
e = fetestexcept(INEXACT|INVALID|DIVBYZERO|UNDERFLOW|OVERFLOW);
- if (!checkexcept(e, p->e, p->r)) {
+ if (!checkexcept(e, p->e, p->r) && (e|INEXACT) != p->e) {
printf("%s:%d: bad fp exception: %s lroundl(%La)=%lld, want %s",
p->file, p->line, rstr(p->r), p->x, p->i, estr(p->e));
printf(" got %s\n", estr(e));
y = round(p->x);
e = fetestexcept(INEXACT|INVALID|DIVBYZERO|UNDERFLOW|OVERFLOW);
- if (!checkexceptall(e, p->e, p->r)) {
+ if (!checkexceptall(e, p->e, p->r) && (e|INEXACT) != p->e) {
printf("%s:%d: bad fp exception: %s round(%a)=%a, want %s",
p->file, p->line, rstr(p->r), p->x, p->y, estr(p->e));
printf(" got %s\n", estr(e));
y = roundf(p->x);
e = fetestexcept(INEXACT|INVALID|DIVBYZERO|UNDERFLOW|OVERFLOW);
- if (!checkexceptall(e, p->e, p->r)) {
+ if (!checkexceptall(e, p->e, p->r) && (e|INEXACT) != p->e) {
printf("%s:%d: bad fp exception: %s roundf(%a)=%a, want %s",
p->file, p->line, rstr(p->r), p->x, p->y, estr(p->e));
printf(" got %s\n", estr(e));
y = roundl(p->x);
e = fetestexcept(INEXACT|INVALID|DIVBYZERO|UNDERFLOW|OVERFLOW);
- if (!checkexceptall(e, p->e, p->r)) {
+ if (!checkexceptall(e, p->e, p->r) && (e|INEXACT) != p->e) {
printf("%s:%d: bad fp exception: %s roundl(%La)=%La, want %s",
p->file, p->line, rstr(p->r), p->x, p->y, estr(p->e));
printf(" got %s\n", estr(e));
y = trunc(p->x);
e = fetestexcept(INEXACT|INVALID|DIVBYZERO|UNDERFLOW|OVERFLOW);
- if (!checkexceptall(e, p->e, p->r)) {
+ if (!checkexceptall(e, p->e, p->r) && (e|INEXACT) != p->e) {
printf("%s:%d: bad fp exception: %s trunc(%a)=%a, want %s",
p->file, p->line, rstr(p->r), p->x, p->y, estr(p->e));
printf(" got %s\n", estr(e));
y = truncf(p->x);
e = fetestexcept(INEXACT|INVALID|DIVBYZERO|UNDERFLOW|OVERFLOW);
- if (!checkexceptall(e, p->e, p->r)) {
+ if (!checkexceptall(e, p->e, p->r) && (e|INEXACT) != p->e) {
printf("%s:%d: bad fp exception: %s truncf(%a)=%a, want %s",
p->file, p->line, rstr(p->r), p->x, p->y, estr(p->e));
printf(" got %s\n", estr(e));
y = truncl(p->x);
e = fetestexcept(INEXACT|INVALID|DIVBYZERO|UNDERFLOW|OVERFLOW);
- if (!checkexceptall(e, p->e, p->r)) {
+ if (!checkexceptall(e, p->e, p->r) && (e|INEXACT) != p->e) {
printf("%s:%d: bad fp exception: %s truncl(%La)=%La, want %s",
p->file, p->line, rstr(p->r), p->x, p->y, estr(p->e));
printf(" got %s\n", estr(e));