So I was reading Howard Oakley’s Eclectic Light Company blog, as I often do (and you should too), and he mentioned the taskpolicy command line app, which I wasn’t aware of before. taskpolicy allows you to demote a process to “background priority,” making it run more slowly by giving it a lower priority for its disk and network access and – key point here – on M1-powered Macs, also runs the process on the M1’s efficiency cores instead of on the performance cores.
That got me thinking… if there’s a command line tool to do this, there must be a system API to make this happen, too. And lo and behold, the setpriority( ) system call will actually perform this neat trick, even though the man page lies and says it won’t.
I made some changes to App Tamer yesterday to add this, and App Tamer now has a new checkbox:
Turn the checkbox on, and whenever an app isn’t frontmost, App Tamer will give that app background priority, reducing its disk and network priority and switching it over to run on an M1 efficiency core. Running a few apps that consume quite a bit of CPU looks like this in Activity Monitor:
In my initial testing, the feature seems to work quite nicely. App Tamer automatically moves apps between the performance and efficiency cores as you switch between apps. So far, I haven’t found any downsides to this – but then again, I just added the feature yesterday and have only done limited testing. It’d be great to actually quantify whether this delivers additional battery life.
If you’d like to give it a try, you can download App Tamer 2.7d1 here. Just unzip it and run it, then click on a cpu-hungry app in App Tamer’s process list and turn on “Run this app on an M1 efficiency core” – that’s it. App Tamer will automatically lower the app’s priority when it isn’t frontmost.
Update: There’s now a beta version of App Tamer 2.7 that includes an almost-finished version of this feature.
Note for users of Intel-based Macs: On your machine, the checkbox is named “Run this app as a low-priority process” because your Mac doesn’t have separate efficiency and performance cores 😢. The app will be demoted to background priority so it uses fewer CPU and I/O resources, but I’m afraid there’s no fancy cpu-juggling involved.