|
|
|
|
|
by dagw
3017 days ago
|
|
I assume you're talking about in the web browser/pure js? Because otherwise you can just bind to the native CUDA etc. libraries like most other languages do. And even on the browser side SIMD is being implemented in WebAssembly and (limited) GPGPU will be possible via WebGL 2.0 compute shaders. So as such I don't see any reason why JavaScript couldn't at the very least match python/numpy in performance if someone put their mind to it. |
|
Additionally, 4 years ago, WebCL was announced and implemented in some browsers, but then it was scrapped in favor of compute shaders in WebGL 2.0. When WebGL 2.0 finally arrived, it did not have compute shaders. Instead, they have been delayed to be implemented as an extension at some indefinite point in the future.
Sorry if this sounds a bit grumpy, but I have been disappointed too often to be enthusiastic about this.
There are also issues like floating point rounding modes in JS and floating point precision in WebGL that have to be addressed. Should not be too hard, but who knows.