News for hackers. Stuff that matters.
Re:Dart team posts an example of fast code with 22ms for a “... by wahern on Thursday May 07, 2020 @07:03PM (#23109404)
All that proves is that V8 is a beast, similar to the JVM. Here's what an alternative world could look like:

  $ time luajit -e 'print"hello world"'
  hello world

  real 0m0.002s
  user 0m0.000s
  sys  0m0.002s
But it's worse than that, because the time at issue is for the AOT-compiled native code binary.

To be fair, I presume that the included runtime is written in C++, and modern C++ coding styles are pretty inefficient. Lots of small, dynamic allocations. Too much of the wrong kinds of abstraction. It's what happens when you shoehorn problems into established solution models, rather than approach development, including boiler plate code, as crafting a bespoke solution model fit to the problem. But the latter makes onboarding new engineers more difficult--you can't start hacking without first grasping the larger architecture--and therefore frowned upon in larger companies, or in small companies that equivocate big company approaches to "best practice".

Re:Dart team posts an example of fast code with 22ms for a “... by hedora on Thursday May 07, 2020 @08:39PM (#23110092)
Poking around on my laptop, dash and perl take about 2ms. Python takes 12.

Anyway, the modern c++ I use avoids allocations like the plague.

I subscribe to the idea that C++ is a language for standard library implementors, and that std:: is mostly placeholders for the “real” implementation you’ll use later.