×


wasm/C++/js/java test(Read 231 times)
wasm/C++/js/java test on: October 08, 2017, 05:26:23 pm
il add OpenGL test or game latter in 7+- days(this week)
Live demo present on github, you can see links in Readme file

https://github.com/danilw/cputests



Re: wasm/C++/js/java test Reply #1 on: October 09, 2017, 12:38:23 am
I've been looking for something similar recently... thinking about a wasm sorting algorithm... don't know if the overhead of converting the data to a binary representation for wasm to use and back would allow for any real gains...

I'm also curious about the general performance difference between basic algorithms like merge sort or prime generation in a relatively efficient vanilla js (w/o the slow for-each/for-in), vs asm.js running as Javascript vs an actual imported wasm module... all the examples seem to be around graphics and rendering rather than general programming actions like those in ai/simulations

thoughts? is this a fool's erand? i know it's not ready for production really w/o js fallback... ( and what docs do you reference when building out something like this? just emscripten and webassembly.org?



Re: wasm/C++/js/java test Reply #2 on: October 09, 2017, 07:50:23 am
I've been looking for something similar recently... thinking about a wasm sorting algorithm... don't know if the overhead of converting the data to a binary representation for wasm to use and back would allow for any real gains...

I'm also curious about the general performance difference between basic algorithms like merge sort or prime generation in a relatively efficient vanilla js (w/o the slow for-each/for-in), vs asm.js running as Javascript vs an actual imported wasm module... all the examples seem to be around graphics and rendering rather than general programming actions like those in ai/simulations

thoughts? is this a fool's erand? i know it's not ready for production really w/o js fallback... ( and what docs do you reference when building out something like this? just emscripten and webassembly.org?

as result of this few my "test" project I can say that- wasm is good (yes wasm has hiden non-C-stadart "problems"(like threads or some sdt:: members work not same like in gcc)), wasm "2d drawing"(put pixels/draw rectangle/etc) is very slow, wasm "calculation sped" ~2x slower then java
javascript and webgl is not ready for "real applications" only for "hello-word-s"
this why I want see "how opengl good" in wasm, will see soon