test(libkernel): check the libc++ steady clock errno around the host sleep #24116
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/24116"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from boykopovar/AnyPS5. Originally posted by Romannachwievor on 2026-11-20T06:37:58Z.
Title: test(libkernel): check the libc++ steady clock errno around the host sleep
What
guest_kernel_clockaborts on macOS since #23862 addedTestLibcxxSteadyClock. The test sets guest errno to 97, callssteady_clock::now, sleeps withstd::this_thread::sleep_for, callsnowagain, and then requires errno to still be 97.The guest errno is the host errno (
__error_nid_postfixreturns&errno). On macOS,nanosleepsets errno toETIMEDOUT(60) even when the sleep succeeds, so the check fails because of the host sleep, not because ofsteady_clock::now. A plain host program shows the same thing: errno is 60 after a 2 mssleep_for, both as x86_64 and as arm64.The test now checks errno right after the first
nowcall and sets it back to 97 after the sleep. Bothnowcalls are still checked for leaving errno alone, and the sleep is no longer part of the check. The library code is unchanged.Tested
macOS 26.5, Apple M1, x86_64 Release under Rosetta 2, on main
a4d1053d4bplus #17425 and #11049.guest_kernel_clockaborts every time.ctest -R '^guest_kernel_clock$'passes, three runs in a row.python3 tools/check_conventions.py --base origin/mainpasses on this branch.240d7aa391and this branch:guest_kernel_clockpasses on both, three runs each.Checklist
main; no other open PR implements the same functionsNotImplemented_nid_no_patch); silent stubs are listed under Silent stubs in their library's technical debt file.mdfiles or images added to the repository (attach them to this PR)AI-assisted: yes (Claude Code)
Imported from boykopovar/AnyPS5. Originally posted by PrivacyOnion on 2026-11-20T06:40:31Z.
Review: APPROVED
Verified on Linux (Ubuntu 24.04, GCC 13.3, Ninja, Release) against
772cfd6b72:tools/check_conventions.pypassed.guest_kernel_clock_testsbuilt cleanly.guest_kernel_clock):Looks Good To Me
Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-11-20T06:46:38Z.
Review: COMMENTED
Reviewed — comments
The prepared bundle contains no diff or changed-file entries, so I cannot verify the proposed test change or justify a formal approval or change request.
What I ran
772cfd6b724152336c72c7bd637bdd146515a5ad.Results
Findings
Blocking
None verified.
Non-blocking
None.
Not verified
core/libs/tests/GuestKernelClock.cpp; the description identifies it as excluded, but it does not appear among the manifest's changed files and no diff was supplied.reviewed; thus there are no files read to compare against files reviewed.To get this to a good state
Provide a complete prepared diff and changed-file manifest for this head so the code and changed lines can be reviewed.