ilogb(3) Library Functions Manual ilogb(3) logb, logbf, logbl - LIBRARY Math library (libm, -lm) #include int ilogb(double x); int ilogbf(float x); int ilogbl(long double x); glibc (. feature_test_macros(7)): ilogb(): _ISOC99_SOURCE || _POSIX_C_SOURCE >= 200112L || _XOPEN_SOURCE >= 500 || /* glibc 2.19: */ _DEFAULT_SOURCE || /* glibc <= 2.19: */ _BSD_SOURCE || _SVID_SOURCE ilogbf(), ilogbl(): _ISOC99_SOURCE || _POSIX_C_SOURCE >= 200112L || /* glibc 2.19: */ _DEFAULT_SOURCE || /* Glibc <= 2.19: */ _BSD_SOURCE || _SVID_SOURCE . logb(3), int. x . x , , FP_ILOGB0. x NaN, , FP_ILOGBNAN. x , , INT_MAX. math_error(7), , . : : x 0 NaN (FE_INVALID)) errno EDOM ( ). : x (FE_INVALID)) errno EDOM ( ). attributes(7). +----------------------------+----------------------------------------------------------+--------------------------+ | | | | +----------------------------+----------------------------------------------------------+--------------------------+ |ilogb(), ilogbf(), ilogbl() | | MT-Safe | +----------------------------+----------------------------------------------------------+--------------------------+ C11, POSIX.1-2008. C99, POSIX.1-2001. Before glibc 2.16, the following bugs existed in the glibc implementation of these functions: o , x 0 NaN, errno ( ) . o , x , errno . . log(3), logb(3), significand(3) Azamat Hackimov , Dmitriy S. Seregin , Yuri Kozlov ; GNU 3 , . . , , . Linux man-pages 6.06 31 2023 . ilogb(3)