For the complete Mojo documentation index, see llms.txt. Markdown versions of all pages are available by appending .md to any URL (e.g. /docs/manual/basics.md).
splat
splat[size: Int, //, dtype: DType](value: SIMD[DType.bool, size]) -> SIMD[dtype, size]
Elementwise splat the boolean value of each element in the SIMD vector into all bits of the corresponding element in a new SIMD vector.
Parameters:
Args:
- value (
SIMD[DType.bool, size]): The value to check.
Returns:
SIMD[dtype, size]: A SIMD vector where each element is filled with 1 bits if the
corresponding element in value is True, or filled with 0 bits
otherwise.