projects
/
libc-test
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
math: print file:line in the error msg, fix nearbyint tests
[libc-test]
/
src
/
math
/
ceil.c
diff --git
a/src/math/ceil.c
b/src/math/ceil.c
index
e39d039
..
ab6be5f
100644
(file)
--- a/
src/math/ceil.c
+++ b/
src/math/ceil.c
@@
-3,9
+3,9
@@
#include "util.h"
static struct d_d t[] = {
#include "util.h"
static struct d_d t[] = {
-
#include "ucb/ceil.h"
#include "sanity/ceil.h"
#include "ucb/ceil.h"
#include "sanity/ceil.h"
+
};
int main(void)
};
int main(void)
@@
-21,14
+21,15
@@
int main(void)
y = ceil(p->x);
e = getexcept();
if (!checkexcept(e, p->e, p->r)) {
y = ceil(p->x);
e = getexcept();
if (!checkexcept(e, p->e, p->r)) {
- printf("%s ceil(%a)==%a except: want %s", rstr(p->r), p->x, p->y, estr(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));
err++;
}
d = ulperr(y, p->y, p->dy);
if (!checkulp(d, p->r)) {
printf(" got %s\n", estr(e));
err++;
}
d = ulperr(y, p->y, p->dy);
if (!checkulp(d, p->r)) {
- printf("%s ceil(%a) want %a got %a ulperr %.3f = %a + %a\n",
- rstr(p->r), p->x, p->y, y, d, d-p->dy, p->dy);
+ printf("%s
:%d: %s
ceil(%a) want %a got %a ulperr %.3f = %a + %a\n",
+
p->file, p->line,
rstr(p->r), p->x, p->y, y, d, d-p->dy, p->dy);
err++;
}
}
err++;
}
}