Skip to content

Conversation

@dogi
Copy link
Member

@dogi dogi commented Nov 10, 2025

Replaced the coroutine-based implementation in ANRWatchdog with a more memory-efficient Handler and Runnable. This resolves an OutOfMemoryError caused by the continuous creation of coroutine objects in a loop. The new implementation uses a single Handler and a reusable Runnable to post updates to the main thread, significantly reducing memory overhead.


https://jules.google.com/session/17867790474745510265

Replaced the coroutine-based implementation in ANRWatchdog with a more memory-efficient Handler and Runnable. This resolves an OutOfMemoryError caused by the continuous creation of coroutine objects in a loop. The new implementation uses a single Handler and a reusable Runnable to post updates to the main thread, significantly reducing memory overhead.
@dogi dogi added triage Further information is requested experiment close? labels Nov 10, 2025
@dogi dogi closed this Nov 10, 2025
@dogi dogi reopened this Nov 10, 2025
@dogi dogi removed the close? label Nov 10, 2025
@dogi dogi changed the title Refactor ANRWatchdog to use Handler Refactor ANRWatchdog to use Handler (fixes #9027) Nov 11, 2025
@dogi dogi changed the title Refactor ANRWatchdog to use Handler (fixes #9027) all: smoother anr watchdog handling (fixes #9027) Nov 11, 2025
@dogi dogi merged commit dd698c1 into master Nov 11, 2025
2 of 3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants