|
Zephyr API Documentation 4.4.0-rc1
A Scalable Open Source RTOS
|
Integer log2 utilities for mathematical operations. More...
Macros | |
| #define | ilog2_compile_time_const_u32(n) |
| Calculate the floor of log2 for compile time constant. | |
| #define | ilog2(n) |
| Calculate integer log2. | |
Integer log2 utilities for mathematical operations.
| #define ilog2 | ( | n | ) |
#include <zephyr/math/ilog2.h>
Calculate integer log2.
This calculates the floor of log2 (integer of log2).
| n | Input value |
n | #define ilog2_compile_time_const_u32 | ( | n | ) |
#include <zephyr/math/ilog2.h>
Calculate the floor of log2 for compile time constant.
This calculates the floor of log2 (integer log2) for 32-bit unsigned integer.
| n | Input value |