mirror of
https://github.com/jart/cosmopolitan.git
synced 2025-02-21 05:29:02 +00:00
10 lines
140 B
C
10 lines
140 B
C
#include "libc/math/math.h"
|
|
|
|
float logbf(float x)
|
|
{
|
|
if (!isfinite(x))
|
|
return x * x;
|
|
if (x == 0)
|
|
return -1/(x*x);
|
|
return ilogbf(x);
|
|
}
|