refactor(npuniversaldatasystem): drop errno saves around guest copies #26190
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/26190"
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 LeandroLP23 on 2026-11-23T12:28:34Z.
What
Same change as #25937, #25944 and #25945, for
libSceNpUniversalDataSystem.GuestCopyIn_nid_no_patch,GuestCopyOut_nid_no_patchandGuestWritable_nid_no_patchrestoreerrnothemselves since #21243 (RestoreErrnoinlibc/src/General.cpp), so saving and restoringerrnoaround them does nothing.19 inline saves around a guest copy are removed, in
EventPropertyArray.cpp,EventPropertyObject.cpp,Handle.cpp,Record.cppandSystem.cpp. A save is kept where the saved value is used again later in the function. 38 lines removed.Context.cppandEvent.cppare left out because #21557 changes them.No change in behaviour.
Tested
Windows 11 (10.0.26300), WinLibs GCC 15.2.0 r7, Release.
ctest -R 'universal_?data|np_?uds', with its 3 build outputs fromtools/select_tests.py targets: 3 of 3 onmain709342e209and 3 of 3 with this change applied to it.tools/check_conventions.pypasses.tools/pr_overlap.py --branchfinds no overlap with the 2550 open pull requests.Not run: Linux and macOS.
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)Imported from boykopovar/AnyPS5. Originally posted by mihiii1337 on 2026-11-23T12:47:27Z.
Review: APPROVED
I ran a native Windows GCC 15.2 A/B fixture built from all five changed UDS sources on base
81a4fdbfe0and head71f053d135. Both revisions passed 22 export cases, including 2 real read-hook and 18 write-hook calls that deliberately changed errno. Rejected outputs preserved the caller's errno and left the event property and record containers unchanged. Retrying into writable memory attached the clone. Omitting the optional child output attached the child without invoking the write hook. The fixture ran entirely in process.The Windows CI log also shows np_uds_events and patched_libraries passing. Test merges with #23418 and #22049 were clean. The Context.cpp and Event.cpp conflicts with #21557 are already present against base.
AI-assisted: yes