7 ms·
Levenstein distance with WASM is 40% faster in the benchmarks on the linked medium article. WASM (145,086 ops/sec) JavaScript (102,775 ops/sec) https://mediu
by peterth3 5y ago
Levenstein distance with WASM is 40% faster in the benchmarks on the linked medium article.
WASM (145,086 ops/sec)
JavaScript (102,775 ops/sec)
https://medium.com/netscape/javascript-c-modern-ways-to-use-c-in-javascript-projects-a19003c5a9ff https://medium.com/netscape/javascript-c-modern-ways-to-use-...
- maga 5y agoAnd that's another thing about JavaScript engines--they evolve and usually result in better performance. The article is written in 2017 and the results are from Node.js of the time, meanwhile the results in the repository are from the last year.
- zamadatix 5y agoCan confirm, I ran the benchmark in that repo and rather than JS being 30% faster in Levenstein distance it was ~10% slower but both had improved relative to the native score.
- duped 5y agoIs it a naive recursive implementation or the matrix formulation?