Mojo function
strided_load
strided_load[dtype: DType, //, simd_width: Int, *, invariant: Bool = False](addr: UnsafePointer[Scalar[dtype], address_space=address_space, mut=False, origin=origin], stride: Int, mask: SIMD[DType.bool, simd_width] = SIMD[DType.bool, simd_width](True)) -> SIMD[dtype, simd_width]
Loads values from addr according to a specific stride.
Parameters:
- dtype (
DType): DType ofvalue, the value to store. - simd_width (
Int): The width of the SIMD vectors. - invariant (
Bool): Whether the memory is load invariant.
Args:
- addr (
UnsafePointer): The memory location to load data from. - stride (
Int): How many lanes to skip before loading again. - mask (
SIMD): A binary vector which prevents memory access to certain lanes ofvalue.
Returns:
SIMD: A vector containing the loaded data.
Was this page helpful?
Thank you! We'll create more content like this.
Thank you for helping us improve!