Hacker News new | ask | show | jobs
by lebuffon 1190 days ago
That's an interesting case and use of the word efficient.

Developer time reduced by 5X CPU time increased by 500x

When CPU cycles are cheap it's a logical tradeoff but it still grates against my sensibilities.

4 comments

5X is a gigantic underestimate of how much developer time has improved. How long would it take a good assembly programmer to implement a CRUD web server connected to a database? Way more than 5x longer what a mediocre Python programmer would need.
> How long would it take a good assembly programmer to implement a CRUD web server connected to a database?

You know you can call import functions and call libraries in other languages than python? If everyone was programming in assembly then there would be plenty of libraries to make database calls or make web servers in assembly, and there would be plenty of tutorials online that you could copy and paste to get things going, meaning it wouldn't take much work at all. It would be more work, but not orders of magnitude more work.

an assembly programmer wouldn't write a web server connected to a database, they would implement a tui over tty, and it would be faster.
How good would it be at letting business users attach photos and emailed documents?
Depends on the field kinda. For a really extreme case, something like big dense linear algebra is going to just use BLAS calls anyway. For big enough matrices, all of the flops are coming from the library, the cost of calling from Python vs the cost of calling from C or Fortran is amortized anyway, and probably most people won’t beat a tuned BLAS however much developer time they throw at it.

It makes more sense to tune libraries excessively, we could say it is less of a trade off, more of an allocation of the finite low-level tuning developer resources to high-impact libraries.

Anyway it turns out that the only way to get most people to link to a good BLAS is to use Numpy and distribute it through some giant Anaconda Rube Goldberg machine, so, I dunno, people are weird.

What does it even mean to say that a hypothetical assembly program is 500x faster than an existing Python program, when the assembly program does not even exist?

It's some kind of philosophical question.

Maintaining an assembly version of a modern software stack is not 5x more costly, it's simply not possible.

We should stop thinking about the trade-off as between developer time and CPU time. The CPU is an inanimate object which doesn't mind pushing around more electrons. What we're really throwing under the bus when we optimize for developer time is the customer's time.

If an inefficiency saves a developer 10 days of work, but results in an operation taking 100 milliseconds longer, and you have 50M customers who do that operation just one time, then you've wasted ~58 customer-days.

Don't forget customer's battery
So we just have to figure out if developer-hours or customer-hours are the tighter bottleneck.