summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLars-Dominik Braun <lars@6xq.net>2015-03-07 12:22:24 +0100
committerLars-Dominik Braun <lars@6xq.net>2015-05-02 21:36:45 +0200
commit979edc5ceac0f47120331b54ec8183400694af8d (patch)
tree1d01189d3a75e5637914b2f60ce59336df4e7864
parent78dc71bda71fc8eb7accfcf68d010a0fea1a7921 (diff)
downloadpucket-979edc5ceac0f47120331b54ec8183400694af8d.tar.gz
pucket-979edc5ceac0f47120331b54ec8183400694af8d.tar.bz2
pucket-979edc5ceac0f47120331b54ec8183400694af8d.zip
Do not use amdlibm’s nearbyint
~3% slower than GCC builtin.
-rw-r--r--math.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/math.h b/math.h
index 96b9d5b..a7a5ff6 100644
--- a/math.h
+++ b/math.h
@@ -26,6 +26,7 @@
#ifdef HAVE_AMDLIBM
#define REPLACE_WITH_AMDLIBM
#include <amdlibm.h>
+#undef nearbyint
#endif
#define clamp(a,min,max) (a > max ? max : (a < min ? min : a))