feat(libSceVideoOut): export the hardware cursor functions as not implemented #6135
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/6135"
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 DavidSamir on 2026-10-14T23:02:31Z.
What
Prospero Win (PPSA99995) imports four libSceVideoOut functions that no library exports. On Windows, where a module's imports are bound when it loads, the title stops there:
tools/nid_names.pynames themsceVideoOutCursorDisable,sceVideoOutCursorSetImageAddress,sceVideoOutCursorEnableandsceVideoOutCursorSetPosition, the hardware cursor. The title's Vulkan module calls them to show a Windows program's mouse cursor over its frames (pw_vulkan_radv.c); its launcher did not call them in the 60 s runs below.libSceVideoOut now exports the four next to its other unimplemented exports in
Unimplemented.cpp, and each reports<name> not implementedwhen called. Drawing the cursor would need the image format and size and the console's return values, which are not known; the debt note says so.Three commits:
feat(libSceVideoOut): export the hardware cursor functions as not implemented.test(libSceVideoOut): check that the cursor functions report they are not implemented:guest_video_out_cursorcalls each with a handle, a cursor index, an image and a position, and requires the error. Without the exports it does not link.docs(debt): record where the cursor functions' signatures come from, under Unknown function info.There is no fourth step to split out.
Tested
Windows (
10bc2f05aonmain922abe6a4, Windows 11 10.0.26300, WinLibs GCC 15.2.0 r7, Release):--trap-sdk-syscall-stubsfrom a local merge of this branch with #6102 and #6028 onmain922abe6a4:/data/prospero-win/logs/session-0.log) records the keyboard and mouse opening, an empty game library andlauncher video=ok pad=ok hid=ok frame=1 apps=0, the state #6028 reports on Linux.libSceVideoOut.prxexportsfEPEwROdCwM,u-9bhWQApq8,UPZWCH8qTM4andN17AK88NdD0(objdump). WithUnimplemented.cppas onmain,guest_video_out_cursordoes not link (undefined references to the four functions); with the change it passes.guest_video_out_high_frame_rateandvideo_out_output_mode_policypass at every commit,guest_video_out_cursorfrom the second.ctest --parallel 4on a full build: 1240 of 1241 pass.check_main_syncfails on this machine at a file name withéread back through the console code page; it passes withPYTHONUTF8=1, and the branch changes nothing undertools/.tools/check_conventions.py --base origin/mainpasses.tools/pr_overlap.py --branchreports no overlap with open pull requests.Linux (same commit, WSL2 Ubuntu 24.04, GCC 13.3.0, Release):
libsbuilds andguest_video_out_cursorpasses.Not checked on a console.
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)mainaloneImported from boykopovar/AnyPS5. Originally posted by github-actions[bot] on 2026-10-14T23:03:13Z.
Progress report (
6239cef→10bc2f0)📉 System libraries: 88.6% (-0.09%, +4 declared functions)
🆕 4 declared as stubs
sceVideoOutCursorDisablesceVideoOutCursorEnablesceVideoOutCursorSetImageAddresssceVideoOutCursorSetPositionImported from boykopovar/AnyPS5. Originally posted by github-actions[bot] on 2026-10-15T12:15:21Z.
Other open pull requests touch the same code. Merging one will break the other, or both implement the same thing. If this one builds on them, list them in Depends on.
main)sceVideoOutCursorDisablesceVideoOutCursorEnablesceVideoOutCursorSetImageAddresssceVideoOutCursorSetPositionSome comparisons could not be completed because a pull request conflicts with the base branch. Review these shared files manually before concluding that there is no overlap.
core/libs/prx/libSceVideoOut/CMakeLists.txtdocs/dev/debt/libSceVideoOut.mdcore/libs/prx/libSceVideoOut/CMakeLists.txtcore/libs/prx/libSceVideoOut/CMakeLists.txtcore/libs/prx/libSceVideoOut/CMakeLists.txtcore/libs/prx/libSceVideoOut/Unimplemented.cppdocs/dev/debt/libSceVideoOut.mdcore/libs/prx/libSceVideoOut/CMakeLists.txtImported from boykopovar/AnyPS5. Originally posted by screamm on 2026-10-15T14:37:18Z.
Cross-validation on Windows 11 Pro 26220, NVIDIA RTX 4070 (596.21), MinGW GCC 15.2, PR head
10bc2f05amerged on main2e5dd5aa1with #6102f1735f59f:Ryzen 7 5700X, WinLibs GCC 15.2.0 r7, Ninja, Release,
BUILD_TESTING=ON. The host was under load during the runs.Prospero Win (PPSA99995): relinked with
--trap-sdk-syscall-stubs --module-dir win/wine/lib/wine/x86_64-unix,app0/eboot.binstaged,ANYPS5_REQUIRE_DISPLAY=1, 90 s per run.Unimplemented.cppas onmain), 2 runs: exit0xC0000139after about 1 s, 0 frames:0xC0000139, 0 frames. The fourlibSceVideoOut.prxlines are gone; only the threeFAIL: unresolved ELF import b7uXQmnfB2s from libkernel.prxlines (sysarch, #6028) remain.183782ddcmerged as well:0xC0000139, only the fourlibSceVideoOut.prxlines;Prospero Win | FPS: 1.02 (86)), and the frame dumps show the launcher's library screen ("NO APPLICATION PROFILES FOUND"). No stop line./data/prospero-win/logs/session-0.loghaslauncher video=ok pad=ok hid=ok frame=1 apps=0, as in the PR;tools/import_audit.py: the four imports, all fromlibvulkan.prx, move from absent to stub, leaving none absent.--trace-imports, withAPS5_TRACE_CALLS=libSceVideoOutandAPS5_HANG_DUMP_SECS=80, recorded 76 libSceVideoOut calls in 80 s:sceVideoOutWaitVblank72 times, andsceVideoOutOpen,sceVideoOutSetFlipRate,sceVideoOutSetBufferAttribute2andsceVideoOutRegisterBuffers2once each. None of the four cursor functions was called, and no run printednot implemented. The trace records only that a call was made, not its arguments or result. The launcher does not reachpw_videoout_cursor; once a Windows program shows a cursor, the title will stop atsceVideoOutCursorEnable not implemented.Tests:
guest_video_out_cursor: passed 3 of 3 times.Unimplemented.cppas onmainand the test kept,guest_video_out_cursor_testsdoes not link (undefined referenceto all four).NotImplemented_nid_no_patchcall removed fromsceVideoOutCursorSetPosition, the test fails withsceVideoOutCursorSetPosition returned instead of reporting that it is not implemented.ctest -R video_out, 3 runs of 22 tests: 11 pass and 11 skip (thevideo_out_flip_*tests find no Vulkan in the offscreen SDL driver;guest_video_out_wqhd_detection_no_vulkan). The exception isguest_video_out_high_frame_rate, which failed in 1 of the 3 runs (incorrect vblank periods).main8856f180cfails it 2 of 4 times on this host under the same load, so the failure is not from this PR.-j8 --timeout 120 -E '^agc_driver_|^video_out_flip'): 830 of 832 pass, 2 skipped, 0 failed. The load was lower during this run.tools/check_conventions.py --base origin/mainpasses,git diff origin/main --checkis clean, and the changed files compile without warnings.tools/progress.py: libraries 88.7% -> 88.6% (3272/3689 -> 3272/3693); libSceVideoOut goes from 2 to 6 functions to do, with the four added as stubs.Note: the debt line says the cursor image's format and size and the console's return values are not known. However, the cited
pw_vulkan_radv.c(lines 58-60 and 132) says VideoOut composes up to two 64x64 straight-alpha B8G8R8A8 images and that the enable, image and position calls return 0 (measured on FW 12.02). Throwing is still reasonable, since that is a comment in a homebrew source, but the debt line could say what the source states and what is still missing. This is not a blocker.Verdict: confirmed. The four imports resolve, and with #6102 and #6028 Prospero Win reaches its launcher on Windows.
Written with Claude Code assistance.
Imported from boykopovar/AnyPS5. Originally posted by screamm on 2026-10-16T08:24:14Z.
Follow-up to my earlier run, now on current main
5d9dcc42dwith this PR built alone and the stack merged in the order #6028 (fb0f83ddf) -> #6102 (f1735f59f) -> #6135 (10bc2f05a). #6028 moved from183782ddctofb0f83ddfsince my earlier run; it is the same commit rebased.Windows 11 Pro 26220, Ryzen 7 5700X, NVIDIA RTX 4070 (596.21), WinLibs MinGW-w64 GCC 15.2.0 r7, Ninja, Release.
-k 0on the stack: onlyagc_driver_gpu_indirect_arguments_misaligned_writer_ahead_testsfails (the 64 KiBalignasthat also fails onmain, #6452/#6478);libsbuilds; no warnings in the changed files.main:guest_video_out_cursor,--repeat until-fail:3: 3 of 3. WithUnimplemented.cppas onmainand the test kept, it does not link (undefined referenceto all four).libs:libSceVideoOut.prx359 -> 363 (UPZWCH8qTM4,fEPEwROdCwM,u-9bhWQApq8,N17AK88NdD0), 62614 -> 62618 in total. Of 1093 relinked import registries of 51 local titles, only PPSA99995 imports them (libvulkan.prx).-j8 --timeout 120 -E '^agc_driver_|^video_out_flip'): 837 of 840 pass, 2 skipped,hardware_oracle_comparetimed out under load and passes alone (11.2 s).tools/check_conventions.py --base origin/mainandgit diff --check: pass.Prospero Win (PPSA99995),
--trap-sdk-syscall-stubs --module-dir win/wine/lib/wine/x86_64-unix, display on, 125 s limit:mainandmain+ this PR alone: conversion stops atFAIL: Unsupported Windows guest TLS instruction (bytes: 65 48 8b 0c 25 78 03 00 00) (offset 0x3214c)(#6102's part).0xC0000139after 1-3 s, 0 frames:not implemented; the window shows the launcher's library screen andsession-0.loghaslauncher video=ok pad=ok hid=ok frame=1 apps=0. The import audit goes from 8 absent to 0 absent.My earlier note on the debt line (the cited source describes the image format and return values) still applies; not a blocker.
Not checked: Linux, a console, a Windows program inside Prospero Win that shows a cursor (it would stop at
sceVideoOutCursorEnable not implemented).Written with Claude Code assistance (validation by a subagent, reviewed in this session).
Imported from boykopovar/AnyPS5. Originally posted by adriadam10 on 2026-10-16T23:52:41Z.
Checked on the merged tree: build and the VideoOut ctest scope green (60/60,
guest_video_out_cursorpasses), and the test no longer links without the four exports. The NIDs and parameter lists matchaerolib.csvandpw_vulkan_radv.c, each stub throws viaNotImplemented_nid_no_patch, and the debt line is under Unknown function info. @screamm's Windows run covers the load path; merging.