Programmers will write more efficient algorithms if their employers tell them to trade time-to-market for hardware cost. Previously, it was trade hardware cost for time-to-market. "Programmers" don't make this decision, the product owner does.
I disagree. Engineers choose the technical stack based on the specs. With LLMs, it's faster to ship even in a more verbose language like Go or Rust.
Ask HN: Will programmers write more efficient code during the memory shortage?
211–220 of 264 posts
Re: Ask HN: Will programmers write more efficient code during the memory shortage?
#212"will they" seems like the least interesting/useful question though. How can we , e.g. raise awareness in users and programmers that this is possible and useful? I wanna hang out with coders who care, I wanna read articles about caring and how you can achieve more with less code, and I want to see video content that visualizes the sheer insanity of it all. Like those "scale of the universe" videos, except the complex…
This very much reminds me of an expression coined by Loris Cro (VP of Community at Zig Foundation): "Create software you can love".
Looks like it's even got a website these days: https://softwareyoucan.love/
Re: Ask HN: Will programmers write more efficient code during the memory shortage?
#213Re: Ask HN: Will programmers write more efficient code during the memory shortage?
#214When I started out, the mini computers were 16 bit and there was a limit to program size. You could do a lot within those limits, but once in a great while I did exceed the limits and the compile (if lucky) would fail or the program would dump. That was well before GUIs.
I believe the GUI portion of a program are the largest use of memory, so I do not even know if people today can survive without GUIs :)
Re: Ask HN: Will programmers write more efficient code during the memory shortage?
#215Earlier quoted context omitted.
The key word here is “server”. Optimizing memory server-side directly translates to cost savings for companies. There is a lot less incentive to optimize memory for code that runs on the user’s computer.
There's plenty of incentive if it causes your users to churn.
My anecdotal data point: my MacBook neo with 8 gb of ram running mac os is much snappier than my thinkpad x13g1 (ryzen 7 pro, 8c/16t+ 32gb memory) running linux.
Same user (me), same apps, same websites, same data.
I don’t really blame the apps.
Re: Ask HN: Will programmers write more efficient code during the memory shortage?
#216Earlier quoted context omitted.
Yes, Lumen (and raytracing in general) has a performance overhead. If you don't want that you can skip that feature. Split Fiction and other games choose to do so. I think certain games like Robocop are awesome on UE5.
> If you don't want that you can skip that feature. Unfortunately, for the consumer this can also mean skipping some games altogether: for example, I might not be able to play the latest Indiana Jones or Doom game because they refuse to let RT be disabled (unless they get enough pushback, but we can all see where things are heading). At least there are some (usually indie) games that let you do that, like Incursion:…
A lot of RT features makes game development faster (or more efficient) so you won't be able to play the game without them.
Re: Ask HN: Will programmers write more efficient code during the memory shortage?
#217Programmers will write more efficient algorithms if their employers tell them to trade time-to-market for hardware cost. Previously, it was trade hardware cost for time-to-market. "Programmers" don't make this decision, the product owner does.
The classic excuse for industry-wide incompetence. The average programmer today can't write good code even if told it's an explicit priority. The manager wants the Submit button to submit the form, they rarely care how the programmer does it. It's the programmer that chose to install the 11,000 node_modules, to use React with 3 layers of state management on top with hybrid SSR/CSR and to do Kubernetes because that's…
But what even is good code?
As an infrastructure guy i see my fellow software engineers endlessly debating and bikeshedding on anything but speed and memory consumption.
I see them arguing about functional vs object oriented, immutable data structures, test driven development, agentic bs, this or that interpreted language… never about reducing memory consumption .
Re: Ask HN: Will programmers write more efficient code during the memory shortage?
#218Re: Ask HN: Will programmers write more efficient code during the memory shortage?
#219I don't believe so do for two reasons: - everyone assumes their program / website is the only thing running at the machine at a given time, and dev machines are always more powerful than user machines - it's not really lack of advanced data structures and algorithms that result in the bloat most of the time but the fact that programs and websites are delivered by large teams, there are dozens of submodules that are o…
Advertisements and tracking.
About 90% of the bloat found on most big company websites comes from these scripts being added all over the place. Ideally removing these would make these sites far more efficient, but the marketing and sales folks probably wouldn't allow it.
Re: Ask HN: Will programmers write more efficient code during the memory shortage?
#220Earlier quoted context omitted.
There's nothing more permanent than a temporary fix. If deadlines are causing those stopgaps, the aggressive deadlines are the root problem.
> There's nothing more permanent than a temporary fix. That should be one of those Tech culture “laws.” I suspect that the dependapocalyse is a significant factor. When every part of an operation has multiple context rebuilds, and resources are not shared across module boundaries, you get inefficient behavior. But I’m skeptical that there’s a will to rethink that.
We already have something:
"Nothing is so permanent as a temporary government program."
Milton Friedman, Tyranny of the Status Quo