Ask HN: Why is desktop computing still so slow?

18 points by Justin_K ↗ HN
I don't understand why using a desktop is still so painfully slow. On moderate to better hardware 10 years ago it took ~5-10 seconds for me to open photoshop... today it's still the same. Windows took 10-30 seconds to load then and it's about the same now (to go from power button to actually in Windows with the desktop loaded). With the hardware being multiple times faster, why doesn't software follow suit? If you asked me 10 years ago, I would have been most looking forward to things loading in an instant, but we appear to be no better today.

45 comments

[ 2.7 ms ] story [ 102 ms ] thread
Linux has preload which makes applications launch faster the second time they are run. My system runs on a thumb drive and it takes 11 seconds to launch krita. The second time takes 3 seconds.
I have to wonder, how long would it take for your desktop of today to open photoshop from 10 years ago?

Perhaps software bloat happens in pace with hardware capabilities.

That's a great question... I wish I could find an old disc!
I remember back around 1999 I had a Pentium 3 450 or 500 running NT 4 and it was fast. I think we had Photoshop 5 at the time. It seemed to load almost instantly. This is with SCSI adapter and decent video card too. I loved NT 4, but as time went on the lack of USB support made it hard to use.
That generation of hardware was very fast. The user interfaces of most things are more usable for more people, but have also bloated up and become slow.

PCs are frustrating as they are incredibly powerful, but are engineered in baffling ways.

Upgrading to NVMe drive was probably the best purchase I've made last year

Sadly even with an NVMe boot drive and it still takes me 11s to boot Windows because I got multiple Electron apps: Spotify, Docker Desktop, and Slack

Couldn't you disable those at startup and then turn them on as needed? For example, will you instantly listen to music or run a docker container after you log in?
Personally, waiting an extra 2-3s on boot is an acceptable tradeoff to save a few clicks in my morning routine. Back when I was using an ssd, I might have reconsidered since those apps would add an extra 10s to my boot time
Very great point and I did the same too! For me, I keep them turned off as they're not used daily,e.g., Spotify.
Yeah, my company laptop has a 6-core i7 and 512 GB NVMe, yet it takes a considerable time to even show the lockscreen from a cold boot.

Wonder what junk Dell put in the UEFI. Wasn't Windows 8/10 supposed to boot up in a blink with an SSD and modern PCs?

I can even hear coil whine from SSD which resembles HDD crunching along, albeit much quieter.

> Wonder what junk Dell put in the UEFI

Think of the dumbest thing that you can, and then try to imagine something 10x dumber.

Case in point: Dell makes rugged tablets for use cases like vehicle mounts (police, field service, etc) or outdoor use. They have buttons that are customizable. Customization requires a UWP Windows 10 app.

Yeah Electron is bad for users. I know MBAs love it because they can fire 1/2 of their devs and still check the "we support cross-platform" box.

Try this 1-liner in your Terminal (if you're on Mac)

    e=$(find /Applications -name "Electron Framework.framework" -mindepth 1 -maxdepth 4 | wc -l); t=$(find /Applications -name "*.app" -maxdepth 1 | wc -l); p=$(bc -l <<<"($e/$t)*100"); printf '%.2f%s\n' "$p" "% of your apps are Electron"
On my system, about 20% of my installed apps are Electron now, and this number is growing. No matter how much RAM & CPU you throw at these dogs, they just don't run any better. Gobs of RAM, wasteful use of CPU cycles. A modern desktop dystopia.
I tend to run the ones that work the same way as a webpage(or are just missing features I don't need) in Chrome "app" mode.

Looks just like an electron app and has a normal shortcut, but uses the existing chrome instance and saves memory + cpu if you're using chrome anyways.

Boot of Linux (Debian/10) is very quick (but not instant) on my Samsung NVMe [1], but I have yet to try it with winding through some multi-terabyte databases, but I expect good things.

[1] I have an HP Z240 SFF Xeon; Pretty vanilla. I'm not a modder. The addition of the NVMe drive means that you can have a system without any SATA SSD cables -- and it looks much more industrial, and less PC-like.

Why are your electron apps holding up your boot sequence?
>With the hardware being multiple times faster, why doesn't software follow suit?

Because software has to be written in a way that leverages the new hardware. The optimization is not automatic. If you haven't read this[1] then it may provide some insight.

[1] https://lwn.net/Articles/250967/ (see parts 5 and 6)

The part where you need to do work to really use the new hardware typically is for stuff computers didn’t use to do at all.

For parts where you think “my computer from 10 years ago did that, too, and at the same speed” I think it’s more because software gets written to use the new hardware.

It seems there’s an equivalent of Marchetti’s constant (https://en.wikipedia.org/wiki/Marchetti's_constant: “Marchetti posits that although forms of urban planning and transport may change, and although some live in villages and others in cities, people gradually adjust their lives to their conditions (including location of their homes relative to their workplace) such that the average travel time stays approximately constant”) for the speed of personal computers. As computers get faster, programs get more resource-hungry.

Some of that has tangible benefits. Screens have higher resolution, icons are much larger, spell checkers get better, emojis are added, text anti-aliasing is improved, support for perceptual color spaces ais added, video codecs get better compression, but at the price of decompression speed, etc. (often, the law of diminishing returns is harsh, but there is progress)

Some of it is invisible; programs grow in resource usage in exchange for a shorter time to market. Growth comes from using more resource-hungry languages, from using large libraries, and from not spending (‘wasting’) time to find performance bottlenecks.

This can be seen when installing an old OS for example. This is as controlled situation as you can get - no background tasks, bare metal operation. Installing XP and updating it to SP2 took half an hour or so. Doing exactly the same thing on a system produced 10 years later... takes a comparable amount of time (slightly improved by SSD write speed)
Perfect example.

And now we have SIMD/AVX-512, as well as the M1 ... the compilers/runtimes need to be able to output the optimized instructions to make applications really fly.

Also, OP photoshop might be slow because it's dialing into the cloud?

You’re using the wrong software. People used to complain about Emacs taking forever to open and being dreadfully slow. Most of Emacs runs instantly on my low-spec, years-old Thinkpad.

Seriously: if you use simple software, it’s fast. My Mac is over five years old and everything I do with it runs fast, and that’s with my Mac OS release being only one version behind the current one.

Unfortunately I don't use simple software, we have specific software we have to run based upon our client's requirements.
Very soon you won't use barely any desktop software nor will your coding depend on your hardware as much as now. Many companies are working on that and the time seems much better than a few years back. I am curious to see how some startups in this space will reshape the world.
They've been saying this for 20 years :). But seriously I don't agree... A lot of the work I do must be run locally for security reasons.
Software can easily grow to eat available RAM, and to swamp your disk I/O.

SSD's are helping with this in one way, but also just making it worse by fueling it.

64 bit has also opened a gate toward bloatware: no more barrier in the 3Gb - 4Gb range. Plus 64 bit directly contributes to bloat: now every pointer takes up twice as much space. Any data structure that contains nothing but pointers has doubled in size. If you previously had 100 MB worth of that structure in RAM, now it is 200M without any change in the program's source code.

Years ago I remember significant paging if you had <4gb of ram on windows vista.

No in 2021 I had the run into paging on 8gb of ram with what should have been a lighter OS (windows 10) and a very mild use case. I bought a 16gb stick thinking I would need to remove the 8gb first. and instead I found I could use both so now I have 24gb. No paging but it’s pretty crazy that the thing idles at 10gb and its even possible for my basic use case to need 20gb of ram at times.

(comment deleted)
Stuff's loading a lot faster and seems dramatically more responsive on my M1 mac. It feels like the most significant advancement in a long time. They're built with on-die ARC memory management and it's coded through the OS. It seems to have paid off greatly.

Otherwise, it's not like software's written to be performant and always use 100% of all cores. That'd require you the user to be doing a lot and probably some dramatically re-engineered software up/down the stack.

Page faults are the very slow thing. When you boot, your cache is gonna start empty. Maybe it will run faster after it has been running a while. If you have a pretty stable linux machine, you might only re-boot once or twice in a pandemic.

This situation may eventually be improved by some more secure run-time environment(?s) that somehow eliminate the need for hardware to mother hen so many memory accesses, but we might not be so happy to work under such a regime either.

Because for every inch of computer power get devs get, we take a mile in unoptimized code, frameworks, etc. for the 'developer experience'.
Talking about specifically boot? Once all other bottlenecks (such as mechanical HDDs or insufficient RAM) are eliminated?

Plug and play. Enumerating buses for hardware, and loading drivers for it all. Starting off in backward-compatible hardware modes (eg. a BIOS using PIO in the case of storage devices) and progressively enabling faster and more complicated modes (e.g. DMA or AHCI as drivers get loaded).

The same mechanisms that allow you to plug in hardware to a desktop and have it “just work” make your computer slower to start up than it could theoretically be. There’s a trade-off between that configurability and startup performance. Embedded systems can start up faster because addresses of its peripherals, resources, accessories etc. are computed ahead of time and hardcoded. It doesn’t have to dynamically rediscover them every time it starts.

Extend the “plug and play” concept to software — modular software packages, frameworks, reusable components, dynamic plugins. That’s why, once the OS is loaded, software is slow to start up.

The configurability/performance trade off is true at every level of computing, even down to the function call - https://stackoverflow.com/questions/4667882/is-a-statically-...

Linux/LXQT boots to a ready desktop in about 10 seconds. Not everything is slow.
Maybe the developers just don't care that much.

We created once an electron based app, on a very simple use case. It was extremely slow since some bad dev decisions as well since nobody focused on performance. Later optimized it a bit and it was usable. In the end it worked. Features and good look were just ways more important.

could be, or maybe their bosses are prioritizing cramming in different ad/tracking libraries in there that all start at once, instead of bugs
Probably so and what a shame. To me, it should really start at the OS and trickle down. Imagine if MS or Apple focused on performance, it would be a great competition. I believe they could convince users to switch if they showed and instantaneous OS.
Have you bought a new laptop recently? Because I just switched from 7 years old decent laptop to a new decent in December. And I have completely different feelings than you: I didn't know my software stack can be even faster than it was but it is!

System load was 10 seconds and is 10 seconds again (Linux here) but for example starting phpstorm is like 2-3 times faster.

I had a few GB big project which was scanned for 30 minutes when loaded first time in phpstorm. Now it takes max 10 minutes.

Yes within the last year... Lenovo with 32 GB Ram, core I7, 1GB SSD, decent GPU... I'm just amazed that the UX hasn't improved after all these years.
Forgot to say am running Windows because of client software requirements.
See Wirth' Law: https://en.wikipedia.org/wiki/Wirth%27s_law : "Wirth's law is an adage on computer performance which states that software is getting slower more rapidly than hardware is becoming faster."

In work environments, it can be even worse. It takes me (at work) 5 minutes to log in; 2 minutes to open a MS office app or email; 5-10s to save a document; 20s to insert a row in Excel. Please send help.

The answer to your question depends: For office settings like I described, it may be due to forced network requests, and surveillance/compliance software. More broadly, it's unoptimized software, and various pieces of software competing for resources and scheduling. A mirror that may be easier to GROK is the web: Web apps can be small and responsive by using targeted DOM-manipulation. Most web apps use layers of frameworks, cookies, trackers etc that make them take up much more space, and make them less responsive.

In order to fix this, we may need a new generation of operating systems and software, built from scratch, with a focus on performance (ie responsiveness).

This is one of the reasons I've gotten so excited about embedded and low-level programming: You can ditch the OS, and make programs that respond in a way that feels instantaneous.

There was that study about how after the invention of the vacuum cleaner, the amount of time domestic housewives spent cleaning actually went UP!
Probably one reason is because slower programs are written. Sometimes there are actual improvements in the program, but often it is just slower without real improvements.
Because of the crazy power hardware has now, developers have no incentives to optimize code.

Modern code SUCKS.