feat(libkernel): implement sigpending and sigsuspend #3252

Closed
pushkarreddyy wants to merge 1 commit from upstream-pr/3252 into main
pushkarreddyy commented 2026-10-11 03:31:51 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by pushkarreddyy on 2026-10-11T03:31:51Z.


What

Implement sigpending (NID hpoDTzy9Yy0) and sigsuspend (NID KZ-4qlqlpmo) in libkernel.

  • Completes the POSIX signal set family in libkernel:
    • sigpending: Checks pointer for null (EFAULT 14); clears returned signal set (as no asynchronous pending signals queue is maintained); preserves guest errno.
    • sigsuspend: Checks mask pointer for null (EFAULT 14); returns -1 and sets *__error_nid_postfix() = 4 (EINTR).
  • Extended GuestSignals.cpp unit test suite covering null pointer rejection, sentinel errno preservation, and EINTR return.
  • Documented in docs/dev/TechnicalDebt.md.

Addresses missing signal set imports identified in issue #1578 for homebrew applications and ports.

Tested

  • Windows 11 host.
  • Verified test suite: GuestSignals passes.
  • Verified conventions: python tools/check_conventions.py --base origin/main reports 0 errors.

Checklist

  • Based on current main; no other open PR implements the same functions
  • One topic per PR; follow-ups go in a new PR
  • No comments in code except technical debt
  • Unimplemented paths throw (NotImplemented_nid_no_patch); silent stubs are listed in TechnicalDebt
  • No notes, investigation .md files or images added to the repository (attach them to this PR)
  • New third-party code is a submodule built from source
  • Generic behaviour, not specific to one title
  • Depends on: none
  • AI-assisted: yes
<!-- greyfinch-sync:boykopovar/AnyPS5:issue:4816298948 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/3252). Originally posted by [pushkarreddyy](https://github.com/pushkarreddyy) on 2026-10-11T03:31:51Z. --- ### What Implement `sigpending` (NID `hpoDTzy9Yy0`) and `sigsuspend` (NID `KZ-4qlqlpmo`) in `libkernel`. - Completes the POSIX signal set family in `libkernel`: - `sigpending`: Checks pointer for null (`EFAULT` 14); clears returned signal set (as no asynchronous pending signals queue is maintained); preserves guest errno. - `sigsuspend`: Checks mask pointer for null (`EFAULT` 14); returns -1 and sets `*__error_nid_postfix() = 4` (`EINTR`). - Extended `GuestSignals.cpp` unit test suite covering null pointer rejection, sentinel errno preservation, and EINTR return. - Documented in `docs/dev/TechnicalDebt.md`. Addresses missing signal set imports identified in issue #1578 for homebrew applications and ports. ### Tested - Windows 11 host. - Verified test suite: `GuestSignals` passes. - Verified conventions: `python tools/check_conventions.py --base origin/main` reports 0 errors. ### Checklist - [x] Based on current `main`; no other open PR implements the same functions - [x] One topic per PR; follow-ups go in a new PR - [x] No comments in code except [technical debt](https://github.com/boykopovar/AnyPS5/blob/main/docs/dev/CONVENTIONS.md) - [x] Unimplemented paths throw (`NotImplemented_nid_no_patch`); silent stubs are listed in [TechnicalDebt](https://github.com/boykopovar/AnyPS5/blob/main/docs/dev/TechnicalDebt.md#silent-stubs) - [x] No notes, investigation `.md` files or images added to the repository (attach them to this PR) - [x] New third-party code is a submodule built from source - [x] Generic behaviour, not specific to one title - [x] Depends on: none - [x] AI-assisted: yes
github-actions[bot] commented 2026-10-11 03:32:01 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by github-actions[bot] on 2026-10-11T03:32:01Z.


Thank you for your interest in the project! We are sorry, but we cannot accept more PRs while we work through the existing backlog. This PR has been automatically closed and labeled "intake paused". This is not a judgment of the quality of your changes.

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6105047955 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/3252#issuecomment-6105047955). Originally posted by [github-actions[bot]](https://github.com/apps/github-actions) on 2026-10-11T03:32:01Z. --- Thank you for your interest in the project! We are sorry, but we cannot accept more PRs while we work through the existing backlog. This PR has been automatically closed and labeled "intake paused". This is not a judgment of the quality of your changes.
github-actions[bot] commented 2026-10-11 03:32:12 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by github-actions[bot] on 2026-10-11T03:32:12Z.


Progress report (961b25f → 0b35d74)

📈 System libraries: 86.01% (+0.01%, +2 implemented functions)

✅ 2 implemented
Library Name
libkernel sigpending_nid_postfix
libkernel sigsuspend_nid_postfix
<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6105049184 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/3252#issuecomment-6105049184). Originally posted by [github-actions[bot]](https://github.com/apps/github-actions) on 2026-10-11T03:32:12Z. --- <!-- progress-report --> ### Progress report (961b25f → 0b35d74) 📈 **System libraries**: 86.01% (+0.01%, +2 implemented functions) <details> <summary>✅ 2 implemented</summary> | Library | Name | | - | - | | libkernel | `sigpending_nid_postfix` | | libkernel | `sigsuspend_nid_postfix` | </details>
pushkarreddyy commented 2026-10-11 06:38:49 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by pushkarreddyy on 2026-10-11T06:38:49Z.


The intake check closed this automatically. @oneandonlydean @MarcZX100 @adriadam10: Could one of you please reopen or carry this when convenient? It implements sigpending and sigsuspend (#1578), tracked in issue #3253. It is cleanly rebased, mergeable onto current main (1690db9a2) with Mergeable: True, and passes all conventions and unit tests.

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6106318760 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/3252#issuecomment-6106318760). Originally posted by [pushkarreddyy](https://github.com/pushkarreddyy) on 2026-10-11T06:38:49Z. --- The intake check closed this automatically. @oneandonlydean @MarcZX100 @adriadam10: Could one of you please reopen or carry this when convenient? It implements `sigpending` and `sigsuspend` (#1578), tracked in issue #3253. It is cleanly rebased, mergeable onto current `main` (`1690db9a2`) with `Mergeable: True`, and passes all conventions and unit tests.

Pull request closed

Sign in to join this conversation.
No reviewers
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
boykopovar/AnyPS5!3252
No description provided.