mirror of
https://github.com/Ed94/Odin.git
synced 2026-06-22 13:44:59 -07:00
Allow integer vectors in select
This commit is contained in:
@@ -237,7 +237,7 @@ simd_reduce_or :: proc(a: #simd[N]T) -> T ---
|
||||
simd_reduce_xor :: proc(a: #simd[N]T) -> T ---
|
||||
|
||||
simd_shuffle :: proc(a, b: #simd[N]T, indices: #simd[max 2*N]u32) -> #simd[len(indices)]T ---
|
||||
simd_select :: proc(cond: #simd[N]any_boolean, true, false: #simd[N]T) -> #simd[N]T ---
|
||||
simd_select :: proc(cond: #simd[N]boolean_or_integer, true, false: #simd[N]T) -> #simd[N]T ---
|
||||
|
||||
|
||||
// WASM targets only
|
||||
|
||||
+1
-1
@@ -80,7 +80,7 @@ swizzle :: builtin.swizzle
|
||||
// shuffle :: proc(a, b: #simd[N]T, indices: #simd[max 2*N]u32) -> #simd[len(indices)]T
|
||||
shuffle :: intrinsics.simd_shuffle
|
||||
|
||||
// select :: proc(cond: #simd[N]any_boolean, true, false: #simd[N]T) -> #simd[N]T
|
||||
// select :: proc(cond: #simd[N]boolean_or_integer, true, false: #simd[N]T) -> #simd[N]T
|
||||
select :: intrinsics.simd_select
|
||||
|
||||
splat :: #force_inline proc "contextless" ($T: typeid/#simd[$LANES]$E, value: E) -> T {
|
||||
|
||||
Reference in New Issue
Block a user