feat(libSceDiscMap): report no disc bitmap from sceDiscMapGetPackageSize #8647
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/8647"
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 nikowolf123 on 2026-10-20T20:04:09Z.
What
sceDiscMapGetPackageSize(NIDfl1eoDnwQ4s) was a throwing stub, declared in #8106. It now returnsSCE_DISC_MAP_ERROR_NO_BITMAP_INFO(0x81100004) for every input and writes nothing. This is the no-disc-bitmap state that #6527 set up for the library's other two calls,sceDiscMapIsRequestOnHDDandioKMruft1ek, which already return the same error.Sources:
sceDiscMapGetPackageSize(s64 fflags, int* ret1, int* ret2)returnsORBIS_DISC_MAP_ERROR_NO_BITMAP_INFOand writes nothing (disc_map.cpp L12-L14). The value is0x81100004(disc_map_codes.h L9).ORBIS_DISC_MAP_ERROR_NO_BITMAP_INFO.ps4_sceDiscMapGetPackageSize(fflags:Int64;pret1,pret2:PInt64)also returnsSCE_DISC_MAP_ERROR_NO_BITMAP_INFOand writes nothing (ps4_libscediscmap.pas L53-L56). It defines the value as0x81100004at L18 and registers the function under$7E5D5EA039F0438Bat L69. Those 8 bytes in base64 arefl1eoDnwQ4s.fl1eoDnwQ4s.Signature: the two outputs change from
int*tovoid*because their width is unknown: shadPS4 usesint*and fpPS4 usesPInt64. Nothing is written to them, as withioKMruft1ek. The return type is nowstd::int32_t, like the other two calls. The function checks no arguments and keeps no state.What stays unverified is recorded in
docs/dev/debt/libSceDiscMap.md. Nothing was measured on a console: not the meaning offflagsor of the two outputs, not the output widths, and not the result once the console library has a bitmap.sceDiscMapGetPackageSizewith the other two calls.sceDiscMapGetPackageSizeentry is cut to what is still open. It no longer says that every call throws.#6527 left
fl1eoDnwQ4sout because no title reported there imports it.tools/progress.py --module libSceDiscMapgoes from 2 of 3 functions done (66.67%) to 3 of 3 (100%). Like the other two calls, the function is listed ininert_namesbecause it only returns a constant.Overlap: #6977, which conflicts with
main, adds its own copies of this library'sCMakeLists.txt,Export.cpp,GuestDiscMap.cppand debt file. None of them mentions this function, so the overlap is textual only. #9124 adds a check toGuestDiscMap.cppthat this function throws, the opposite of this PR; the two conflict there. The open draft #9137 changes this library's other outputs and its debt entry and leavessceDiscMapGetPackageSizethrowing. I found no other open PR that changes these files.Tested
Linux: WSL2 Ubuntu 26.04, GCC 15.2.0 (Ubuntu 15.2.0-16ubuntu1), Release with
BUILD_TESTING=ON. I built the targetslibSceDiscMapandguest_disc_map_testsand ranctest -R '^guest_disc_map$'.guest_disc_mappassed (1 of 1, 0.02 s), and again at2093e7b96onmain2c4b116da.guest_disc_map(core/libs/tests/GuestDiscMap.cpp) now also callssceDiscMapGetPackageSize:fflags0, 0x1 and 0x100. Each call must return0x81100004and leave both 64-bit outputs at~0ull.0x81100004.The new checks fail on
main. I put only this PR'sGuestDiscMap.cpponmain434e965d46and ran the same build andctestcommand.guest_disc_mapfailed (Subprocess aborted) withterminate called after throwing an instance of 'std::runtime_error'andwhat(): sceDiscMapGetPackageSize not implemented.Windows: not built.
No title was run.
tools/check_conventions.py --base origin/mainpasses.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)🤖 Generated with Claude Code
Imported from boykopovar/AnyPS5. Originally posted by github-actions[bot] on 2026-10-20T20:04:56Z.
Progress report (
cecb540→2093e7b)📈 System libraries: 42.11% (+0.01%, +1 implemented functions)
✅ 1 implemented
sceDiscMapGetPackageSize⚪ 1 behaviourally empty (constant return or throw)
sceDiscMapGetPackageSizeImported from boykopovar/AnyPS5. Originally posted by xXPBSXx on 2026-10-21T04:48:38Z.
Independent Windows run of this PR (data only).
Environment: Windows 10 Pro 10.0.19045, Ryzen 7 5800X3D, WinLibs GCC 15.2.0 r7 (MinGW-w64 UCRT), Release, BUILD_TESTING=ON. Merge-tree of the PR head against
mainis clean. I built onlyguest_disc_map_tests;ctest -N -R guest_disc_maplists exactly one test.Results (3 runs each):
guest_disc_mappasses 3/3.core/libs/prx/libSceDiscMap/Export.cppwith the version from the PR's merge base (434e965d46), then rebuilt. The test fails 3/3 (exit 0xc0000409). I restored the PR's files afterwards.Not run: other platforms, the other tests in the same family, the full repository CTest, and any title or console run.
AI-assisted (Claude Code).
Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-10-23T04:06:03Z.
Review: CHANGES_REQUESTED
Reviewed this original DiscMap implementation and ran its exact-head focused test locally: GCC 12.2 built
Export.cppplusGuestDiscMap.cppwith-O2 -Wall -Wextra -Werror; the test passed. Current-main conventions and diff checks pass against9d6adeb, and the PR reports an independent Windows 3/3 positive run with a 3/3 failing baseline control.The head still needs updating before merge. GitHub reports it non-mergeable, and current main has changed
core/libs/prx/libSceDiscMap/Export.cppsince this PR's base (including the other export's signature from #9137). Please rebase onto current main, preserve that current signature alongside this function, and rerun the focused test against the rebased tree. A newer PR #9997 now proposes the same function; I asked its author to coordinate rather than maintain two implementations.Pull request closed