Hacker News new | ask | show | jobs
by r2b2 1098 days ago
Yes, using a watch + compile + restart development environment where everything can be worked on locally reduces cycle time to 5ms, which is ~100,000x quicker than the 10m compile time in the parent post.

I've deployed 35,000+ lines of code to prod in 2023 with this flow. I've only had 2 small bugs.

This is by far the most efficient setup I've ever used.

3 comments

The biggest latency in any large software project is... other people.
I think Fred Brooks also talked about that in one of his essays didn't he?

(I guess I'm being facetious because I think everyone should read his book of essays. The hardware platforms have changed dramatically since the 1960s, but the wetware hasn't changed a bit)

The issue most have is that they never tend to think they are the "other" people when reality is its arbitrarily anyone at any given point.

In theory if your process is perfectly optimized and everyone is doing the correct things all the tike and the goals are well defined then this is true. The biggest bottleneck I see in most projects are that there little to no definition in what needs to be done. It's not a handholding task, it's a lack of clear or continuously fluctuating goals. That ultimately ends to people slowing down.

Business leadership wants to hand the goal of "make money" to the engineering team but IMHO that's an unrealistic expectation and shows poor, incompetent, and or lazy leadership. Someone needs to find the demand signal and be decent at predicting future demand to direct the team towards what needs to be created. At some point, if you think you can hand off lofty lazy goals to an engineering team like this then your role becomes questionable because you have a hybrid engineering/entrepreneurial team who could basically work without your involvement.

So many cache misses and the context switching? It takes hours!
On my current project, any deploy that we want to do to an AWS environment, including dev, takes at least 10 minutes. So, as soon as you have to work on AWS functionality, you are transported to the past, similarly to the programmers of old. I'm not saying this is a bad thing actually, just to note that we still haven't managed to eliminate the "turn-around time".
Yes, this is the best workflow (though I'm curious how you get 5ms latency with a full dev env restart -- fork/exec alone takes 1-5ms on my 2020 macbook).

Nits aside use the same style and have set a time budget of 50ms for myself. I have even setup nvim to save on every keystroke (one also learns how to not write infinite loops when programming in this style).

This style of programming is transformative because it's like having a persistent repl. It becomes feasible to test every edge case with print debugging as you go. This workflow is also why I have little interest in any language that primarily targets llvm, which will easily blow my time budget in code gen.

Leetcode doesn't capture this, so it must not be a viable way to work.

/s