How do I detect whether a browser supports SIMD by JS code?

Viewed 859

I found a way to detect but it's not work on my computer with the latest chrome enabling simd flag:

var simd =  async () => WebAssembly.validate(new Uint8Array([0, 97, 115, 109, 1, 0, 0, 0, 1, 4, 1, 96, 0, 0, 3, 2, 1, 0, 10, 9, 1, 7, 0, 65, 0, 253, 4, 26, 11]));
await simd();

Is there another way to detect?

1 Answers
Related