Repository navigation
Conversation
An ITIMER_REAL or alarm expiry with SIGALRM blocked threw "pending signals are not implemented". Now that blocked signals stay pending, the expiry marks SIGALRM pending as a blocked raise does, following FreeBSD's realitexpire, which sends it through kern_psignal: sigwait, sigwaitinfo and sigtimedwait take it, and unblocking it runs a registered handler. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_017b3iPcA6fL66awNGDnP8wo
This was referenced Oct 13, 2026
Author
11 tasks done
Collaborator
|
Closing: no title is known to reach this. With the queue at 700+ open PRs, please hold off on new PRs that don't name a title needing the change until it's down. If a title stops on this on current main, reopen with the title ID and the log line. |
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.
What
An
ITIMER_REALoralarmexpiry withSIGALRMblocked threwITIMER_REAL (...) expired while SIGALRM is blocked: pending signals are not implemented. Since upstream added a process-wide pending set (28063f1, "wait for pending guest signals in the signal waits"), blocked signals can stay pending, so the expiry now marksSIGALRMpending exactly as a blockedraisedoes, instead of throwing.This follows FreeBSD 11's
realitexpire(kern_time.c), which sendsSIGALRMthroughkern_psignalandtdsendsignal, where a masked signal is held. With it,sigwait,sigwaitinfoandsigtimedwaittake the expiry, and unblocking it runs a registered handler. Expiries withSIG_IGN, and unblocked expiries (default disposition exits with 142, a handler throws), are unchanged.This is the pattern QEMU's
qemu_signal_inituses: it blocksSIGIO,SIGALRMandSIGBUSand takes them withsigwaiton a dedicated thread (compatfd.c), so an armed QEMU timer would otherwise end the process at its first expiry. Thesetitimerentry indocs/dev/debt/libkernel.mdis updated: the pendingsiginfo_treportsSI_USERlike the other pending signals (the kernel reportsSI_KERNEL), and one pending instance absorbs further expiries until it is taken.Tested
Linux, Ubuntu 24.04 x86_64, GCC 13.3,
-DBUILD_TESTING=ON. Two cases added toguest_sigtimedwait: SIGALRM blocked, a 50 ms one-shotsetitimer,sigtimedwaitreturns 14; and with a handler registered, the expiry stays pending while blocked and the handler runs when_sigprocmaskunblocks it. On unpatchedmainthe test aborts with thepending signals are not implementederror; with the change it passes.guest_sigtimedwait,guest_signals,guest_itimer,guest_getitimer,guest_signal_setsandguest_user_contextpass;guest_sigtimedwaitpassed 10 sequential runs and 3 parallel runs under CPU oversubscription (0.6 s each).tools/check_conventions.pypasses. Not tested on Windows or macOS, or on a title.Checklist
main; no other open PR implements the same functionsNotImplemented_nid_no_patch); silent stubs are listed in TechnicalDebt.mdfiles or images added to the repository (attach them to this PR)🤖 Generated with Claude Code
https://claude.ai/code/session_017b3iPcA6fL66awNGDnP8wo