BackgroundMusic icon indicating copy to clipboard operation
BackgroundMusic copied to clipboard

High coreaudio usage while running

Open pseudolimonada opened this issue 2 years ago • 2 comments
trafficstars

While not running image

While running image

Seems rather significant usage, 15-20% cpu for a sound management tool with speakers on idle (no apps directly running audio), and base settings for all apps (no mixing done yet through background music).

edit: 8th column is cpu usage

pseudolimonada avatar Sep 15 '23 17:09 pseudolimonada

It's a bug that Background Music is leaving coreaudiod active while no apps are playing audio, but I think that CPU usage is roughly what I see anytime audio is playing. Background Music is probably playing audio, but only silence.

IIRC the CPU usage is from the audio processing coreaudiod does on MacBooks to protect the speakers and tune the audio for the laptop speakers. Are you using a laptop?

At the moment, I don't have Background Music running, but something on my system must be running audio (probably Firefox) because coreaudiod is at around 16% CPU. That's only 16% of one core, of course, but still very annoying. It's common enough that I wonder if it might be a bug in CoreAudio that's causing this.

I'd guess that https://github.com/kyleneideck/BackgroundMusic/issues/470 could be the underlying cause for you, but that bug only occurs after you've played audio while Background Music is running. Is that the case for you as well or does it happen immediately?

kyleneideck avatar Sep 16 '23 03:09 kyleneideck

I command+Q Background Music, took the first screenshot, then opened Background music and it immediately shot up to this 17-20 range that persists, without anything playing.

I also tried testing just playing audio without Background Music and one source shoots it to 8%, two concurrent to 10%.

This is on an M2 MBP.

pseudolimonada avatar Sep 16 '23 06:09 pseudolimonada