Returns the ceil of value/divisor
| 42 | |
| 43 | // Returns the ceil of value/divisor |
| 44 | constexpr int64_t CeilDiv(int64_t value, int64_t divisor) { |
| 45 | return (value == 0) ? 0 : 1 + (value - 1) / divisor; |
| 46 | } |
| 47 | |
| 48 | // Return the number of bytes needed to fit the given number of bits |
| 49 | constexpr int64_t BytesForBits(int64_t bits) { |
no outgoing calls