Documentation
¶
Index ¶
- Variables
- func AlignUp(n, align uint64) (uint64, error)
- func CeilDiv(a, b uint64) (uint64, error)
- func ClearLowestBit(n uint64) uint64
- func FastMod(n, m uint64) (uint64, error)
- func FindLowestBit(n uint64) uint64
- func Log2Ceil(n uint64) uint64
- func NextPowerOfTwo(n uint64) uint64
- func ReverseBits(n uint64) uint64
Constants ¶
This section is empty.
Variables ¶
Functions ¶
func ClearLowestBit ¶
ClearLowestBit clears the least significant set bit in n and returns the result.
func FindLowestBit ¶
FindLowestBit returns the index of the least significant set bit in n (0-based). Returns 0 if n is 0.
func NextPowerOfTwo ¶
NextPowerOfTwo returns the next power of 2 >= n.
func ReverseBits ¶
ReverseBits reverses the bits of a 64-bit unsigned integer.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.