From 51f4f8c512d682fe0c1a7a891909e75f416f20f6 Mon Sep 17 00:00:00 2001 From: Alexander Monakov Date: Tue, 14 Jan 2020 14:53:38 +0300 Subject: math: move x87-family rint functions to C with inline asm --- src/math/i386/rintf.c | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100644 src/math/i386/rintf.c (limited to 'src/math/i386/rintf.c') diff --git a/src/math/i386/rintf.c b/src/math/i386/rintf.c new file mode 100644 index 00000000..bb4121a4 --- /dev/null +++ b/src/math/i386/rintf.c @@ -0,0 +1,7 @@ +#include + +float rintf(float x) +{ + __asm__ ("frndint" : "+t"(x)); + return x; +} -- cgit 1.4.1