Hacker News new | past | comments | ask | show | jobs | submit login

You don't understand what asm.js is for, right? It is not meant for writing code in it, it is for compiling code from other languages to it. Well, sometimes you may need to write code in it for optimization. But the code you point to looks complicated not because it is written in asm.js, but because algorithm itself is compilcated. If you will rewrite it in any other language it will still contain all of these magic numbers and strange operations. In fact, almost any hashing algorithm looks like this. Just open wikipedia page for sha-1 or md5 and look at pseudocode.



Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: