Module utils

Module utils 

Source
Expand description

Helper functions for aligned memory operations

Functions§

align_up
Get the next aligned address
alignment_padding
Calculate padding needed for alignment
create_aligned_buffer
Create an aligned buffer that can be used like a Vec
is_aligned
Check if a pointer is aligned to the given alignment
is_vec_aligned
Check if a Vec’s data is aligned