News for hackers. Stuff that matters.
Re:My Node.js is a bit Rusty by marcosdumay on Friday September 08, 2023 @10:18AM (#37433834)
No, I do claim that attitude is completely counterproductive.

This is not some case of bad pick of algorithms. The entire optimization work will happen through microoptimizations spread through the code.

If you insist on doing the microoptimizations on a language that is actively antagonistic to them, you will only create a lot of useless work, and have only mildly useful results to show for it, that will go away as soon as anything on your ecosystem changes (in JS that is measured in what? minutes?). And also, you will end up with an horrible codebase that's probably much less legible than what a lower level language will give you.

And that besides not having any good tooling or community support, because all the tools and the community are focused on developer productivity, not software performance, as that's the entire focus of the language.

Re:My Node.js is a bit Rusty by orf on Friday September 08, 2023 @10:38AM (#37434082)
I can parse a 200gb TSV with NodeJS in under a minute.

Could it be done in 1 millisecond with assembly? Probably.

But we are talking about over a days runtime here. That is not a micro optimisation, regardless of the language you’re using. You’re just using the language wrong, the same as if it took a day to parse with C.

Your attitude, that it’s pointless to even try and investigate performance issues because it’s written in JS rather than whatever language you see as optimal, is totally counterproductive.

Re:My Node.js is a bit Rusty by hnfong on Saturday September 09, 2023 @09:04AM (#37444891)
> Could it be done in 1 millisecond with assembly? Probably.

I know you're probably just knowingly spewing hyperbole to make your point, but unless your L1 cache is 200GB memory bandwidth alone makes this impossible.