libSceSystemService: RetroArch (PPSA99169) stops on sceSystemServiceLoadExec("/app0/picker/picker.bin"), a second executable the title ships #4793
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
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 marshmll on 2026-10-12T22:05:24Z.
Title: RetroArch PS5 (PPSA99169, catalog record v1.0.0-beta.1, release ZIP checked against its sha256).
Host: Linux (Fedora 44, kernel 7.2.9), GCC 16.2.1, AMD RX 9060 XT (RADV, Mesa 26.2.4). Run in a rootless Podman container without network.
Build:
mainee4962190with the logging fix of #4792 applied (without it the stop leaves no message, see there), Release,-DBUILD_TESTING=ON -DANYPS5_ENABLE_SPIRV_TOOLS=ON.eboot.binandsce_module/unwrapped from their SELF containers,relinker --registry.Where it stops
At start-up, every run:
The title's
eboot.binis a front end. Its trace (app0/trace.txt) shows it choosing the picker:and it then calls
sceSystemServiceLoadExec(gdb at the call,rdi/rsi):path:/app0/picker/picker.binarguments: two entries, a pointer to an empty string, then NULLThe release ships three executables, all SELF containers whose ELF type is
0xFE10:eboot.bin(38.9 MB),picker/picker.bin(29.6 MB) andes-de/es-de.bin(48.2 MB). (webui/ps5-retroarch-webui.elfis a plainET_DYNELF, not passed toLoadExec.)Why #1525 does not cover it
#1525 implemented
sceSystemServiceLoadExec("/app0/eboot.bin", argv)as a restart of the running title (Linux:execv("/proc/self/exe")afterLibcRunShutdown; Windows: a new process that waits for the old one) and was closed because no title reached the call. This title reaches it with a different executable, which #1525 left throwing because the relinker converts only the title's executable.Proposal
--module-dirdoes for modules, for example a repeatable--executable <path>(relative to the module parent) that writes the converted executable next to the converted modules underapp0/, with the samelibs/rpath.sceSystemServiceLoadExec: map the guest path to that converted executable, run the runtime shutdown and replace the process as #1525 did for the restart. A path with no converted executable keeps throwing, with the path in the message.Questions:
0xFE10executable it finds under the title directory?argumentshere is{"", NULL}. #1525 read the array as NULL-terminated without the program name (as shadPS4 does), which would give the picker one empty argument; the empty entry could also be an empty program name. Is either confirmed?AI-assisted: yes
Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-10-13T04:29:50Z.
Opened #4925 for the narrow diagnostic gap: unsupported
sceSystemServiceLoadExeccalls now include the requested path in the exception, with a regression check for/app0/picker/picker.bin.This does not implement conversion or process replacement for secondary executables, so #4793 remains open for that behavior.
Imported from boykopovar/AnyPS5. Originally posted by p3n1cillin on 2026-10-13T07:19:28Z.
Reproduced on Windows 11 (MinGW GCC 15.2.0,
main510a2188c, catalog record v1.0.0-beta.1 checked against its sha256): the first call issceSystemServiceLoadExec("/app0/picker/picker.bin", {"", NULL}), read with gdb at the call (rdi,rsi). I'd like to take this on; here is what the title needs and a plan, with one question before I write it.The whole chain (source at bead807):
eboot.bin→/app0/picker/picker.binor/app0/es-de/es-de.bin(src/frontend_mode_ps5.cpp)LoadExec(next->next, {next->argument, NULL}), e.g./app0/eboot.binwith--ps5-mode=retroarch(frontends/picker/picker.cpp:445)LoadExec("/app0/eboot.bin", {..., "--ps5-mode=quit", NULL})(frontends/es-de/ps5/main_ps5.cpp:180)So the argument list holds only arguments (no program name), and both the second executables and the
eboot.binrestart with arguments are reached.eboot.binfinds its mode by scanning everyargventry for--ps5-mode=, so whether the console puts the path inargv[0]doesn't decide this title.Runtime facts that shape the design:
/app0,/dataand/download0resolve against the working directory, and on Windows the library path ($ORIGINbecomes.) and the guest module paths are working-directory relative too. A second converted executable started with the same working directory therefore sees the sameapp0. The Windows entry stub already turns the host command line into the guestargv(CommandLineToArgvW), soLoadExecarguments can be passed as command-line arguments.Plan
--executable <path>(relative to the module parent, like--module-dir) runs the pipeline for that ELF too and writes it asapp0/<path>.exeon Windows (app0/<path>.elfon Linux), beside the original's directory.sceSystemServiceLoadExec:"exit"as today;/app0/eboot.binrestarts the main executable; any other/app0/...path starts its converted executable if it exists, else throws with the path (as #4925 reports it). The arguments go on the new process's command line. The old process runs the guest shutdown and exits without waiting, so its direct memory is released before the new one allocates (Windows:CreateProcessWwith the inherited working directory; Linux:execv). #4786 is theeboot.binhalf of this and would become part of it.Question: a guest module's conversion depends on the executable that needs it: deferred initialization comes from that executable's dynamic section, so
picker.binandeboot.bincan produce differentlibc.prx.guest.prxfiles. Should each extra executable get its own converted module tree (for exampleapp0/picker/picker.bin.modules/sce_module/...), or would you rather have one shared tree with initialization decided at run time?Imported from boykopovar/AnyPS5. Originally posted by p3n1cillin on 2026-10-13T08:04:03Z.
Implemented in #4786. On the module question:
libc.prx.guest.prxcomes out byte-identical foreboot.bin,picker.binandes-de.bin, so the executables share one module tree, and the relinker fails if a module ever converts differently. The extra executables go beside the output (picker.picker.bin.exe) rather than underapp0/, because the Windows entry stub sets the working directory to the executable's own directory. The RetroArch picker now starts and hands off in both directions; ES-DE also needstzname(#5009).