blob: 55c8b296d4d7357bc6f622ff5358093b650c55c7 [file] [log] [blame]
Viet-Trung Luu96b05c12016-01-11 11:26:36 -08001#include <math.h>
2#include <stdint.h>
3
George Kulakowski17e3b042016-02-18 15:59:50 -08004float fabsf(float x) {
5 union {
6 float f;
7 uint32_t i;
8 } u = {x};
9 u.i &= 0x7fffffff;
10 return u.f;
Viet-Trung Luu96b05c12016-01-11 11:26:36 -080011}