Repository navigation
drm/asahi: G16: run each probe phase in its own stack frame - #1669
Merged
DjDeveloperr merged 1 commit intoNov 12, 2026
Merged
Conversation
Loading the GPU module on the J713 overflows the probe's stack: Insufficient stack space to handle exception! pc : ...g16...Firmware13start_backend+0x54 [aurora] Kernel panic - not syncing: kernel stack overflow Gpu::new() runs admission, the firmware start and the backend start in turn. Built for the J713, the compiler now inlines the first two into it, a 17 KB frame, and calls the third, which has 14 KB of its own. Below the probe path that no longer fits in the 32 KB stack. Before the last G16 changes the backend start was inlined as well: one 18 KB frame. Keep all three out of line, so each phase's temporaries are gone when it returns. Measured from the frames in aurora.o, the deepest path below the probe goes from 34.5 KB to 24.9 KB (26.1 KB before those changes). The backend start's own frame, mostly whole-Firmware moves, is the next thing to shrink. Assisted-by: LLM Signed-off-by: Bartosz Nitka <niteria@gmail.com>
niteria
marked this pull request as ready for review
November 12, 2026 10:24
DjDeveloperr
approved these changes
Nov 12, 2026
DjDeveloperr
merged commit Nov 12, 2026
f173f7c
into
aurora-silicon:integration/aurora
1 check passed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
On the J713 (MacBook Air M4), loading the G16 GPU module overflows the probe's 32 KB stack:
Gpu::new()runs admission, the firmware start and the backend start in turn. Built for the J713, the compiler now inlines the first two into it, a 17 KB frame, and calls the third, which has 14 KB of its own. Below the probe path that no longer fits in the 32 KB stack. Before the G16 changes #1445 brought in, the backend start was inlined as well: one 18 KB frame.This keeps all three out of line, so each phase's temporaries are gone when it returns. Measured from the frames in
aurora.o, the deepest path below the probe goes from 34.5 KB to 24.9 KB (26.1 KB before those changes). The backend start's own frame, mostly whole-Firmwaremoves, is the next thing to shrink.Seen with the G16 code as #1445 merged it, which
integration/aurorastill has. Tested on the J713 as part of #1314: with this commit the module loads, the GPU renders, and its firmware comes back after each deep sleep.🤖 Generated with Claude Code