| 281 | } |
| 282 | |
| 283 | inline uint32_t nextPowerOf2( uint32_t x ) |
| 284 | { |
| 285 | x |= (x >> 1); |
| 286 | x |= (x >> 2); |
| 287 | x |= (x >> 4); |
| 288 | x |= (x >> 8); |
| 289 | x |= (x >> 16); |
| 290 | return(x+1); |
| 291 | } |
| 292 | |
| 293 | //! Returns true if \a x is a power of two, false otherwise. |
| 294 | inline bool isPowerOf2( size_t x ) |
no outgoing calls
no test coverage detected