authorgravatar for kounoike.yuusuke+github@gmail.comKOUNOIKE Yuusuke <kounoike.yuusuke+github@gmail.com> 2023-03-21 01:45:12+09:00
committergravatar for noreply@github.comGitHub <noreply@github.com> 2023-03-20 17:45:12+01:00
log5df31f3ef3d2c4640fa2c7fc9b03c83c6a8606ae
treef63960a636d57654e9ecb189e5b82b4e1d891398
parent0c169127338ef8af752d1a077e412b5135e300d5
signaturebadge-question-mark Signed by PGP key 4AEE18F83AFDEB23

add wasm-simd support for suggestVectorSizeForCpu (#14992)


1 files changed, 2 insertions(+), 0 deletions(-)

lib/std/simd.zig+2
......@@ -43,6 +43,8 @@ pub fn suggestVectorSizeForCpu(comptime T: type, comptime cpu: std.Target.Cpu) ?
4343 // for multiple processing, but I don't know what's optimal here, if using
4444 // the 2048 bits or using just 64 per vector or something in between
4545 if (std.Target.sparc.featureSetHasAny(cpu.features, .{ .vis, .vis2, .vis3 })) break :blk 64;
46 } else if (cpu.arch.isWasm()) {
47 if (std.Target.wasm.featureSetHas(cpu.features, .simd128)) break :blk 128;
4648 }
4749 return null;
4850 };