Return a number that's equal or smaller than @num and aligned on @alignment
| 36 | |
| 37 | // Return a number that's equal or smaller than @num and aligned on @alignment |
| 38 | uint64_t alignDown(uint64_t num, uint64_t alignment) { |
| 39 | return num - num % alignment; |
| 40 | } |
| 41 | |
| 42 | // Return a number that's equal or bigger than @num and aligned on @alignment |
| 43 | uint64_t alignUp(uint64_t num, uint64_t alignment) { |
no outgoing calls
no test coverage detected