Live data from Hacker News

Control Center on macOS is always re-rendering its SwiftUI causing 1% CPU load

twitter.com

81–90 of 145 posts

Re: Control Center on macOS is always re-rendering its SwiftUI causing 1% CPU load

#81
post #76

Earlier quoted context omitted.

How many of these problems can be overcome by simply running the tools in the browser and not as standalone apps?

For electron-based tools that were designed as web-first apps, I agree with you that it's better to have them in a browser tab than as standalone apps. However, for real desktop tools that utilize the operating system's bells and whistles, which truly make an app a desktop app—like Sublime—I'd never use an alternative in the browser.

> However, for real desktop tools that utilize the operating system's bells and whistles, which truly make an app a desktop app—like Sublime—I'd never use an alternative in the browser.

I such cases I would also never favor an Electron app posing as native software.

Re: Control Center on macOS is always re-rendering its SwiftUI causing 1% CPU load

#82
post #64

Earlier quoted context omitted.

Just be aware that 1% on modern multi-core systems is not a lot. The macOS activity monitor doesn't calculate the average percentage over all cores, instead (AFAIK) a process on e.g. a M1 Pro/Max can use up to 1000% if it utilizes all 10 cores. Stuff like this will be run on the efficiency cores, I doubt it will have a lot of impact on anything. You can see the usage of efficiency vs performance cores by using Activi…

It's only a fraction of the CPU's power, sure, but it's still consuming power (electricity & processing) without actually doing anything, which is wasteful. And every small inefficiency adds up over the scale of everything.

in this example it's showing the seconds on the clock, which might be useful to some. (Just pointing out that using < 0.1% of the total CPU (depending on how you'd weight the efficiency cores) should not be a dealbreaker if you like this feature)

Re: Control Center on macOS is always re-rendering its SwiftUI causing 1% CPU load

#83
post #63
post #11

Off topic: I wish someone would do this kind of analysis to determine why Microsoft Teams helper process is always at 50-70% CPU load on my M-Based MacBook Pro. My laptop is warm/hot to touch as a result of it.

I wish someone did an analysis to determine why my intel-based macbook is so incredibly laggy all the time, even after fresh system installation. I can't shake the feeling that Apple Silicon is so much faster that performance issues just got into the system without anyone at Apple bothering to fix them, and Intel macs suffer as a result.

It's overheating and the (my) problems came from:

- loading the battery and powering the device

- high gpu power usage when plugging in a external monitor

- cpu power usage

- bad cooling which must be cleaned often

My recommendations:

Plug in the power from the right side. Afaik the thermal throttling kicks in sooner if you have it plugged in on the left.

Clean the device. Unfortunately it really sucks to open it. You will need special tools and lots of trust in the spaghetti monster that you dont break anything.

Cpu power usage can be lowered by using any of the tools:

https://github.com/sicreative/VoltageShift

https://volta.garymathews.com/ (most probably not working anymore)

Unfortunately in later updates apple prevented undervolting the cpu so it's (VoltageShift) use is limited now. But i was able to limit the power usage to 5W, which somehow helped keeping my device cooler. Be aware that you need to disable quite a lot of security measures to install Voltageshift.

Apparently having power saving active even when plugged in helps keeping the cpu and gpu cooler. I did not test this extensively because i switched to a m2.

A big problem comes from the gpu, if you have an external monitor plugged in, the video drivers start using 10W+ which causes problems when you are loading the battery as well. There are a lot of discussions on what causes the problems, it has to do with the drivers and some screens causing it to use way more power then needed. It can help to close the lid of the macbook while working with a external monitor.

Re: Control Center on macOS is always re-rendering its SwiftUI causing 1% CPU load

#84
post #47
post #18

Earlier quoted context omitted.

Meanwhile Apple is the company most actively working on better battery performance, less memory utilization (e.g. compressed memory) and other such changes...

MacOS had compressed memory for at least a decade

I know. Your point being?

Did I say that only recently they started optimizing things?

Re: Control Center on macOS is always re-rendering its SwiftUI causing 1% CPU load

#85
post #56

I am currently at war with google docs and notion re: memory usage. gmail takes something like half a gigabyte of memory. I had a notion database where each time it loaded an additional 25 rows, memory use went up 400MB. It only got up to 200-300 rows total before it died. I gave up Sublime because of memory usage, but the alternatives aren't much better. I'm getting ready to trade in my 8gb Mac for 24gb to help with…

I thought Sublime was one of the efficient ones

I think it is, or at least I use it all day every day and its memory usage is good for me.

Re: Control Center on macOS is always re-rendering its SwiftUI causing 1% CPU load

#86
Yea anything that unnecessarily updates the screen has lots of unexpected power consumption effects. For example, it might prevent the CPU or display itself from entering lower power modes.

Everything in modern systems is super optimized for the case where the screen is mostly static.

Re: Control Center on macOS is always re-rendering its SwiftUI causing 1% CPU load

#87
post #71
post #64

Earlier quoted context omitted.

Just be aware that 1% on modern multi-core systems is not a lot. The macOS activity monitor doesn't calculate the average percentage over all cores, instead (AFAIK) a process on e.g. a M1 Pro/Max can use up to 1000% if it utilizes all 10 cores. Stuff like this will be run on the efficiency cores, I doubt it will have a lot of impact on anything. You can see the usage of efficiency vs performance cores by using Activi…

1% is still a lot for power saving. If the system is idle, it should be at 0%. If it is anything above, then it shows poor design.

Realistically no modern consumer OS is ever at idle for long.

It's constantly monitoring WiFi signals, battery level, checking for background processes to run, and a hundred other things.

Whether CPU usage is being reported as 0% or 1% averaged over the course of a second doesn't have anything to do with poor design. It's just being rounded from values like 0.3% or 0.8% anyways.

Re: Control Center on macOS is always re-rendering its SwiftUI causing 1% CPU load

#88
post #56

I am currently at war with google docs and notion re: memory usage. gmail takes something like half a gigabyte of memory. I had a notion database where each time it loaded an additional 25 rows, memory use went up 400MB. It only got up to 200-300 rows total before it died. I gave up Sublime because of memory usage, but the alternatives aren't much better. I'm getting ready to trade in my 8gb Mac for 24gb to help with…

For the gmail issue, I feel like I might as well plug http://mimestream.com, a gmail client that is a pleasure to use & efficient.

Re: Control Center on macOS is always re-rendering its SwiftUI causing 1% CPU load

#89
post #64

Earlier quoted context omitted.

Just be aware that 1% on modern multi-core systems is not a lot. The macOS activity monitor doesn't calculate the average percentage over all cores, instead (AFAIK) a process on e.g. a M1 Pro/Max can use up to 1000% if it utilizes all 10 cores. Stuff like this will be run on the efficiency cores, I doubt it will have a lot of impact on anything. You can see the usage of efficiency vs performance cores by using Activi…

It's only a fraction of the CPU's power, sure, but it's still consuming power (electricity & processing) without actually doing anything, which is wasteful. And every small inefficiency adds up over the scale of everything.

Perhaps but this thread and discussion might add up to a year's worth of that waste.

Just saying every little thing counts can be very misleading, even though inarguable in theory, and result in non-obvious inefficiency.

Re: Control Center on macOS is always re-rendering its SwiftUI causing 1% CPU load

#90
post #56

I am currently at war with google docs and notion re: memory usage. gmail takes something like half a gigabyte of memory. I had a notion database where each time it loaded an additional 25 rows, memory use went up 400MB. It only got up to 200-300 rows total before it died. I gave up Sublime because of memory usage, but the alternatives aren't much better. I'm getting ready to trade in my 8gb Mac for 24gb to help with…

I thought Sublime was one of the efficient ones

Theoretically it is, but on one Linux computer I have it freezes from time to time, whereupon it stops redrawing frames, resizing the window results in gray rectangles etc. I think it’s caused by a slower disk, which is sad, because I don’t think that’s a legitimate reason for a UI to stop working. I can accept having to wait when opening a file, but the UI completely freezing is unacceptable. I typically close and open it again in those situations.

It still has a faster fuzzy file search than anything available in Emacs, which is why I stick with it.

Post reply on HN