Skip to content

Release 1.81.1: no busy loop with the companions off - #87

Merged
DrogaBox merged 1 commit into
mainfrom
fix/companion-off-loop
Nov 9, 2026
Merged

DrogaBox merged 1 commit into
mainfrom
fix/companion-off-loop

Conversation

@DrogaBox

@DrogaBox DrogaBox commented Nov 9, 2026

Copy link
Copy Markdown
Owner

1.81.1: no busy loop with the companions off

No kext changes (kexts stay at 3.40.1).

Fixed

  • High CPU with the companions turned off. With the Dynamic Island on and its companion off, every preference sync of the island flushed the companion's hearts, hourglass and gold. The flush wrote all three keys even when nothing had changed. Each write posted a preference change, and the island answered it with another full sync, so the main thread stayed about 85% busy for as long as the companion was off.
  • The flush now writes a key only when its stored value differs. An idle flush posts nothing, so the loop has nothing to feed on.

Verification

  • New test: a flush with nothing new posts no preference change, and a flush with new gold still saves it.
  • ./build.sh --test: all checks OK.
  • Concurrency gate: 0 diagnostics.
  • Installed as 1.81.1 (build 149).

With the Dynamic Island on and its companion off, every pass over the
island's preferences flushed the companion's hearts, hourglass and gold.
The flush wrote all three keys even when nothing had changed, each write
posted UserDefaults.didChangeNotification, and the island answered that
notification with another full preference pass. The main thread stayed
around 85% busy for as long as the companion was off.

NotchMascotRPGState.flush() now writes a key only when its stored value
differs, so an idle flush posts nothing and the loop has nothing to feed
on. A test checks that a flush with nothing new posts no preference
change and that a flush with new gold still saves it.
@DrogaBox
DrogaBox merged commit 0ca3cb5 into main Nov 9, 2026
3 of 4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants