feat(libSceNKWebKit): answer Process::identifier and setIdentifier as firmware 13.42 does #16386
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/16386"
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 BunnyFl on 2026-11-06T14:46:33Z.
What
WebCore::Process::identifier()threw, andWebCore::Process::setIdentifier(NIDB6CB7QLhsdk) was not declared. This implements both as firmware 13.42'slibSceNKWebKit.sprxdoes:identifier()runs a one-time initialisation. If no identifier has been stored by then, it takes the next value of the object-identifier counter. It returns the stored value on every call.setIdentifier(identifier)stores the value at any time, before or after the firstidentifier().src/WtfObjectIdentifier.cpp). In the module the same counter also feeds theHistoryItemconstructors, seven other exports and internal code. None of those is implemented yet, and they can use this helper when they are.The setter's name was recovered from its NID:
_ZN7WebCore7Process13setIdentifierEN3WTF23ObjectIdentifierGenericINS_21ProcessIdentifierTypeENS1_38ObjectIdentifierMainThreadAccessTraitsEEEhashes toB6CB7QLhsdk, which is a defined export at0x2e3bb0. The identifier is 8 bytes, passed inrdi(0x2e3bc0below) and returned inrax(0x20717e); both exports usestd::uint64_t.Source.
system_ex/common_ex/lib/libSceNKWebKit.sprx, firmware 13.42, SHA-256e63acdc164592330a287cf6914c265336b27a357098a449c1609f8f82e104409. This was read from disassembly and not run, and nothing was measured on a console.identifier()at0x207100, read to itsretand its threeud2arms:setIdentifierat0x2e3bb0, the whole function:The counter at
0x336f0c8and the value at0x338b840lie past the file-backed end of theirLOADsegment, so both start at 0, and the first generated identifier is 1. The import names come from their GOT slots (0x334e318,0x334e328).Debt. In
docs/dev/debt/libSceNKWebKit.md,identifier()leaves the throwing inventory of "Additional callable exports" and its count becomes 6186 withmain9163fe9677merged in, derived from the merged tree by resolving every inventory row to its symbol inExport.cppand counting the rows whose symbol throws: 6193 data rows, 6186 throwing, 7 implemented in other translation units. The count line ofmain9163fe9677reads 6187.setIdentifierhad no inventory row. One new entry:cmpbinstructions (0x207142,0x7300c4,0x7aee62) and in no store by address; what sets it is unknown.Tested
Windows 11 Pro 10.0.26300, WinLibs GCC, Release, head
5c8f17e06b(main9163fe9677merged in):main9163fe9677says 6187, and the merged tree gives 6186: the merged table has 6193 data rows, of which 6186 resolve to a throwing symbol inExport.cppand 7 are implemented in other translation units of the library (the same seven named under the previous head below). That is one below the 6187 inmain's count line, for the one export whose row this pull request removes. The derivation was not repeated onmain9163fe9677itself this time.nkwebkit|nk_webkittests rebuilt at this head and thelibSceNKWebKitlibrary target built. The set is the 55 tests listed under the previous head plusnkwebkit_contenttype, whichmainregistered in between.mainalso added the3rdparty/libxml2and3rdparty/libpslsubmodules, which the library's build now needs.tools/check_conventions.py --base upstream/mainon the committed head5c8f17e06b: all checks pass.review-tools/sig_users.py HEAD --buildon the merged tree: the one changed declaration isidentifier(); 4 files name it, none outside this branch's own changes, and its three users (libSceNKWebKit,nkwebkit_webcoreprocess_tests,nkwebkit_webcoreprocessidentifier_tests) build.tools/pr_overlap.py --branch feat/nkwebkit-process-identifier --jobs 8at this head, against 1,991 open pull requests: 100 share files or exports with the branch, and none shares an export or a new file. Of the ones it could compare, five have a conflicting line, all indocs/dev/debt/libSceNKWebKit.md: #16853 and #16901 on both the debt entry (line 34 in the comparison base) and the inventory count sentence (line 113), and #15515, #15672 and #17726 on the count sentence alone; whichever lands first makes the others recount it. The run failed closed (exit 2) on 52 pull requests that conflict withmainthemselves and compared none of them. All 52 were then checked by hand at this head: every added and removed line of each diff searched for_ZN7WebCore7Process10identifierEv, the mangledsetIdentifiername and the NIDnyPJWvkvO0A. None of the three appears in any of them, and every diff was fetched.Windows 11 Pro 10.0.26300, WinLibs GCC, Release, head
854b936dec(main31b4aa91e8merged in):main31b4aa91e8says 6194, and the merged tree gives 6193. The derivation is now exact instead of an offset: every row of the inventory table is resolved to its symbol inExport.cpp(by the NID itsAPS5_EXPORTentry carries, else by name) and counted only when that symbol's body callsNotImplemented_nid_no_patch. The merged table has 6200 data rows, of which 6193 resolve to a throwing symbol and 7 are implemented in other translation units of the library (WKURLRequestCopyFirstPartyForCookies,WKURLRequestCopyHTTPMethod,WKURLRequestCopySettingHTTPBody,WKURLRequestCopyURL,WKURLRequestCreateWithWKURL,_ZNK3WTF3URL17lastPathComponentEv,_ZNK3WTF3URL24strippedForUseAsReferrerEv). The same derivation gives 6194 onmain31b4aa91e8, which is what its own count line reads, so the merged number is one belowmain's, for the one export whose row this pull request removes.NotImplemented_nid_no_patchcalls inExport.cppminus 2501, no longer holds: onmain31b4aa91e8it gives 6192 against the table's 6194, because the subtrahend stands for calls outside the inventory andmainhas changed how many of those there are. It is replaced by the derivation above, which reads both numbers off the tree. That derivation reproduces the 6269 this description already states for the previous head8da3f52c51; the heads before that were not re-derived.nkwebkit|nk_webkittests rebuilt at this head and thelibSceNKWebKitlibrary target built:guest_nkwebkit_dates,guest_nkwebkit_numbers,guest_nkwebkit_urls,nkwebkit_argumentreturn,nkwebkit_base,nkwebkit_bmallocfreelist,nkwebkit_cachecontrol,nkwebkit_concurrentptrhashset,nkwebkit_config,nkwebkit_connection,nkwebkit_constants,nkwebkit_contextsettings,nkwebkit_contexttermination,nkwebkit_cookieutil,nkwebkit_credentialbase,nkwebkit_diagnosticloggingkeys,nkwebkit_fastbitvector,nkwebkit_fieldsetters,nkwebkit_forwarding,nkwebkit_historyitem,nkwebkit_htmlinteger,nkwebkit_httpheaderfield,nkwebkit_httpheadermap,nkwebkit_inspectoridentifiersfactory,nkwebkit_jsc,nkwebkit_jsonimpl,nkwebkit_mainthread,nkwebkit_mediatime,nkwebkit_mimetyperegistry,nkwebkit_mockmediadevices,nkwebkit_noops,nkwebkit_palsessionid,nkwebkit_parsedcontentrange,nkwebkit_preferences,nkwebkit_regiongeometry,nkwebkit_resourcerequest,nkwebkit_resourceresponse,nkwebkit_securityorigin,nkwebkit_sha1,nkwebkit_symbolset,nkwebkit_usercontenturlpatternhosts,nkwebkit_usermediapermissionrequest,nkwebkit_webcoredump,nkwebkit_webcoregeometry,nkwebkit_webcoreparsers,nkwebkit_webcoreprocess,nkwebkit_webcoreprocessidentifier,nkwebkit_webcoreviewport,nkwebkit_wtf,nkwebkit_wtfbitvector,nkwebkit_wtflanguage,nkwebkit_wtflogger,nkwebkit_wtftext,nkwebkit_wtftext_allocationandnkwebkit_wtfvalues.tools/check_conventions.py --base upstream/mainon the committed head854b936dec: all checks pass.review-tools/sig_users.py HEAD --buildon the merged tree: the one changed declaration isidentifier(); 4 files name it, none outside this branch's own changes, and its three users (libSceNKWebKit,nkwebkit_webcoreprocess_tests,nkwebkit_webcoreprocessidentifier_tests) build.tools/pr_overlap.py --branch feat/nkwebkit-process-identifier --jobs 8at this head, against 1,948 open pull requests: 93 share files or exports with the branch, and none shares an export or a new file. Of the ones it could compare, three have a conflicting line, all indocs/dev/debt/libSceNKWebKit.md: #16853 and #16901 on both the debt entry (line 32 in the comparison base) and the inventory count sentence (line 111), and #17726 on the count sentence alone; whichever lands first makes the others recount it. The run failed closed (exit 2) on 61 pull requests that conflict withmainthemselves and compared none of them. All 61 were then checked by hand at this head: every added and removed line of each diff searched for_ZN7WebCore7Process10identifierEv, the mangledsetIdentifiername and the NIDnyPJWvkvO0A. None of the three appears in any of them, and every diff was fetched.Windows 11 Pro 10.0.26300, WinLibs GCC, Release, head
8da3f52c51(main6719b01bf3merged in):main6719b01bf3says 6275, and both rules give 6269 on the merged tree: 8770NotImplemented_nid_no_patchcalls inExport.cpp(8770 - 2501) and 6276 inventory data rows (the count plus 7). The same two rules give 6270 onmain6719b01bf3(8771 calls, 6277 rows), five below the 6275 its count line states, so the derived number is one belowmain's tree, for the one export whose row this pull request removes, and six below the stale text.nkwebkit|nk_webkittests rebuilt at this head and thelibSceNKWebKitlibrary target built.tools/check_conventions.py --base upstream/mainon the committed head8da3f52c51: all checks pass.review-tools/sig_users.py HEAD --buildon the merged tree: the one changed declaration isidentifier(); 4 files name it, none outside this branch's own changes, and its three users (libSceNKWebKit,nkwebkit_webcoreprocess_tests,nkwebkit_webcoreprocessidentifier_tests) build.tools/pr_overlap.py --branch feat/nkwebkit-process-identifier --jobs 8at this head, against 1,937 open pull requests: 89 share files or exports with the branch. Of the ones it could compare, six have a conflicting line, all indocs/dev/debt/libSceNKWebKit.mdand nowhere else: #16853 and #16901 on both the debt entry (line 32 in the comparison base) and the inventory count sentence (line 111), and #15672, #16508, #16890 and #17726 on the count sentence alone; whichever lands first makes the others recount it. None shares an export or a new file. The run failed closed (exit 2) on 59 pull requests that conflict withmainthemselves and compared none of them. All 59 were then checked by hand at this head: every added and removed line of each diff searched for_ZN7WebCore7Process10identifierEv, the mangledsetIdentifiername and the NIDnyPJWvkvO0A. None of the three appears in any of them, and every diff was fetched.Windows 11 Pro 10.0.26300, WinLibs GCC, Release, head
760993c7f1(main364ceeba2fmerged in):mainmoved again within the hour (our #16316 merged into it, which is what lowered the inventory count by thirteen), so this is another merge of the same shape: the count sentence was the only conflict, and the count is derived from the merged tree rather than taken from a side. This branch said 6303,main364ceeba2fsaid 6291, and both rules give 6290: the mergedExport.cppholds 8791NotImplemented_nid_no_patchcalls (8791 - 2501), and the merged inventory table has 6297 data rows, the count plus 7. Onmain364ceeba2fthe same rules give 6291 (8792 - 2501). One belowmain, for the one export whose row this pull request removes.nkwebkit|nk_webkittests rebuilt at this head and thelibSceNKWebKitlibrary target built.tools/check_conventions.py --base upstream/mainon the committed head760993c7f1: all checks pass.review-tools/sig_users.py HEAD --buildon the merged tree: the one changed declaration isidentifier(); 4 files name it, none outside this branch's own changes, and its three users (libSceNKWebKit,nkwebkit_webcoreprocess_tests,nkwebkit_webcoreprocessidentifier_tests) build.tools/pr_overlap.py --branch feat/nkwebkit-process-identifier --jobs 8at this head, against 1,961 open pull requests: 87 share files or exports with the branch. Of the ones it could compare, three have a conflicting line, all indocs/dev/debt/libSceNKWebKit.mdand nowhere else: #16853 and #16901 on both the debt entry (line 29 in the comparison base) and the inventory count sentence (line 104), and #17726 on the count sentence alone; whichever lands first makes the others recount it. None shares an export or a new file. The run failed closed (exit 2) on 65 pull requests that conflict withmainthemselves and compared none of them. All 65 were then checked by hand at this head: every added and removed line of each diff searched for_ZN7WebCore7Process10identifierEv, the mangledsetIdentifiername and the NIDnyPJWvkvO0A. None of the three appears in any of them, and every diff was fetched.Windows 11 Pro 10.0.26300, WinLibs GCC, Release, head
95705962ba(mainb673b14c39merged in):mainb673b14c39said 6304, and both rules give 6303. The mergedExport.cppholds 8804NotImplemented_nid_no_patchcalls (8804 - 2501), and the merged inventory table has 6310 data rows, the count plus 7. Onmainb673b14c39the same rules give 6304 (8805 - 2501). One belowmain, for the one export whose row this pull request removes.nkwebkit|nk_webkittests rebuilt at this head and thelibSceNKWebKitlibrary target built.tools/check_conventions.py --base upstream/mainon the committed head95705962ba: all checks pass.review-tools/sig_users.py HEAD --buildon the merged tree: the one changed declaration isidentifier(); 4 files name it, none outside this branch's own changes, and its three users (libSceNKWebKit,nkwebkit_webcoreprocess_tests,nkwebkit_webcoreprocessidentifier_tests) build.tools/pr_overlap.py --branch feat/nkwebkit-process-identifier --jobs 8at this head, against 1,953 open pull requests: 85 share files or exports with the branch. Of the ones it could compare, six have a conflicting line indocs/dev/debt/libSceNKWebKit.md, and in every case only there: #16853 and #16901 on both the debt entry (line 29 in the comparison base) and the inventory count sentence (line 103), and #15891, #16453, #17726 and our own #16316 on the count sentence alone; whichever lands first makes the others recount it. None of them shares an export or a new file. The run failed closed (exit 2) on 63 pull requests that conflict withmainthemselves and compared none of them. All 63 were then checked by hand at this head: every added and removed line of each diff searched for_ZN7WebCore7Process10identifierEv, the mangledsetIdentifiername and the NIDnyPJWvkvO0A. None of the three appears in any of them, and every diff was fetched (none refused by GitHub this time).Windows 11 Pro 10.0.26300, WinLibs GCC, Release, head
5318c527d0(maina26b7827e1merged in):mainsaid 6311, and both rules give 6310.Export.cppholds 8811NotImplemented_nid_no_patchcalls (8811 - 2501) and the inventory table has 6317 rows, the count plus 7. Onmaina26b7827e1the same rules give 6311 (8812 - 2501; 6318 rows). One belowmain, for the one export whose row this PR removes.nkwebkit|nk_webkittests rebuilt at this head and thelibSceNKWebKitlibrary target built.tools/check_conventions.py --base upstream/mainon the committed head5318c527d0: all checks pass.review-tools/sig_users.py HEAD --build: the one changed declaration isidentifier(); 4 files name it, none outside this branch's own changes, and its three users (libSceNKWebKit,nkwebkit_webcoreprocess_tests,nkwebkit_webcoreprocessidentifier_tests) build.tools/pr_overlap.py --branch feat/nkwebkit-process-identifier --jobs 8at this head, against 1,941 open pull requests: 86 share files or exports with the branch. Three of the ones it could compare have a conflicting line: #16853 and #16901 on both the debt entry and the count line, #17726 on the count line. Our own #16316 edits that same sentence as well. The run failed closed (exit 2) on 68 pull requests that conflict withmainthemselves and compared none of them. All 68 were then checked by hand at this head: every added and removed line of each diff searched for_ZN7WebCore7Process10identifierEv, the mangledsetIdentifiername and the NIDnyPJWvkvO0A. None of the three appears in any of them. #15807 is refused whole by GitHub (HTTP 406, over 20,000 lines), so it was read through the per-file patches API instead: 191 files, a patch served for all 191, clean.Windows 11 Pro 10.0.26300, WinLibs GCC, Release, head
455c9e7d4a(mainb4d4db7b64merged in):mainhaving moved again within the hour. The inventory count sentence was the only conflict. The count is derived from the merged tree, not taken from a side - this branch said 6322,mainsaid 6315, and both rules give 6314:Export.cppholds 8815NotImplemented_nid_no_patchcalls (8815 - 2501) and the inventory table has 6321 rows, the count plus 7. Onmainb4d4db7b64the same rules give 6315 (8816 - 2501; 6322 rows). One belowmain, for the one export whose row this PR removes.nkwebkit|nk_webkittests rebuilt at this head and thelibSceNKWebKitlibrary target built. The set is 48 here against 47 at the previous head: the extra one isnkwebkit_cookieutil, whichmainregistered in between.tools/check_conventions.py --base upstream/mainon the committed head455c9e7d4a: all checks pass.review-tools/sig_users.py HEAD --build: the one changed declaration isidentifier(); 4 files name it, none outside this branch's own changes, and its three users (libSceNKWebKit,nkwebkit_webcoreprocess_tests,nkwebkit_webcoreprocessidentifier_tests) build.tools/pr_overlap.py --branch feat/nkwebkit-process-identifier --jobs 8at this head, against 1,947 open pull requests: 85 share files or exports with the branch. Two of the ones it could compare have conflicting lines, on the debt entry and on the count line: #16853 and #16901. Our own #16316 edits the same count sentence as well, so whichever of the two lands first makes the other recount it. The run failed closed (exit 2) on 70 pull requests that conflict withmainthemselves; those were not compared line by line and their diffs were not re-searched at this head: for those 70, overlap is not verified.Windows 11 Pro 10.0.26300, WinLibs GCC, Release, head
6327675402(maind5d50455f9merged in):docs/dev/debt/libSceNKWebKit.mdonly, on the inventory count sentence. It was resolved by deriving the count on the merged tree rather than taking either side: the branch said 6325,mainsaid 6323, and both rules give 6322 on the merged tree.Export.cpphas 8823NotImplemented_nid_no_patchcalls, 8823 - 2501 = 6322, the same offsetmaincarries (8824 - 2501 = 6323 atd5d50455f9); the inventory table has 6329 rows, the count plus 7 (6330 for 6323 onmain). One belowmain, for the one export whose row this PR removes.Export.cppandinclude/InventoryExports.hppmerged without a conflict.nkwebkit|nk_webkittests rebuilt at this head and thelibSceNKWebKitlibrary target built.tools/check_conventions.py --base upstream/mainon the committed head6327675402: all checks pass.review-tools/sig_users.py HEAD --build: the one changed declaration isidentifier(); 4 files name it, none outside this branch's own changes, and its three users (libSceNKWebKit,nkwebkit_webcoreprocess_tests,nkwebkit_webcoreprocessidentifier_tests) build.tools/pr_overlap.py --branch feat/nkwebkit-process-identifier --jobs 8at this head, against 1,953 open pull requests: 85 share files or exports with the branch. Among those it could compare, one has a conflicting line: #16901, which adds a debt entry where this branch adds its own, at line 29 ofdocs/dev/debt/libSceNKWebKit.mdin the comparison base (theWTF::Loggerbullet there). The run failed closed (exit 2) on 68 pull requests that conflict withmainthemselves. Those 68 were not compared line by line, and their diffs were not re-searched at this head: for them, overlap is not verified. The searches at the two earlier heads below found neither export, their NIDs nor the new helper in any of the ones they covered. Whichever of these lands second recounts the sentence.Windows 11 Pro 10.0.26300, WinLibs GCC, Release, head
efb2d7463e(main3d61c0b24fmerged in):docs/dev/debt/libSceNKWebKit.mdonly, on the inventory count sentence, whichmainhad lowered to 6334.main3d61c0b24fhas 8835NotImplemented_nid_no_patchcalls inExport.cppfor its 6334, the same offset of 2501; the merged tree has 8834: 8834 - 2501 = 6333, one belowmainfor the one export with a row. The merged inventory table has 6340 rows, the count plus 7, the same offset the rows have onmain(6341 for 6334) and at the merge base (6366 for 6359).Export.cppandinclude/InventoryExports.hppmerged without a conflict, andgit merge-tree --write-treeagainstupstream/main3d61c0b24fis clean.mainare the same as ata48fe5ce1b; the mutation probes below were not repeated.nkwebkit_*andguest_nkwebkit_*tests (main's newnkwebkit_usercontenturlpatternhostsincluded) andpublic_headers. ThelibSceNKWebKitlibrary target builds too.tools/check_conventions.py --base upstream/mainon the committed headefb2d7463e: all checks pass.review-tools/sig_users.py HEAD --build: the one changed declaration isidentifier(); 4 files name it, none outside this branch's own changes, and its users (libSceNKWebKit,nkwebkit_webcoreprocess_tests,nkwebkit_webcoreprocessidentifier_tests) build.tools/pr_overlap.py --branch feat/nkwebkit-process-identifier --jobs 8atefb2d7463e, against 1,975 open pull requests: 88 share files with the branch, 2 have conflicting lines (#16853 and #16901, both ondocs/dev/debt/libSceNKWebKit.mdline 25, where this branch adds its entry), and none shares an export or a new file. The run failed closed (exit 2) on 71 that conflict withmainthemselves and were not compared line by line; I searched the added and removed lines of 70 of those diffs for the two exports, their NIDs and the new helper and found none. GitHub refuses #15807's whole diff (HTTP 406, over 20,000 lines), so for it I searched the patches of its twolibSceNKWebKitfiles from the pull request files API (its files), which name none of them. Whichever lands second recounts the sentence.Windows 11 Pro 10.0.26300, WinLibs GCC, Release, head
a48fe5ce1b(main286b14d2f7merged in):docs/dev/debt/libSceNKWebKit.mdonly:mainadded itsWTF::Loggerentry where this branch adds itsWebCore::Processentry, and both are kept._ZN7WebCore7Process10identifierEvrow from the throwing inventory and recounts it, which earlier heads of this branch had missed: 8859 calls − 2501 = 6358, one belowmainfor the one export with a row.mainare the same as at56b1d33791; the mutation probes below were not repeated.nkwebkit_*andguest_nkwebkit_*tests andpublic_headers. ThelibSceNKWebKitlibrary target builds too.tools/check_conventions.py --base upstream/mainon the committed heada48fe5ce1b: all checks pass.review-tools/sig_users.py HEAD --build: the one changed declaration isidentifier(); no file outside this branch's own changes names it, and its users (libSceNKWebKitand the two tests above) build.tools/pr_overlap.py --branch feat/nkwebkit-process-identifier --jobs 8ata48fe5ce1b, against 1,994 open pull requests: 13 have conflicting lines, all indocs/dev/debt/libSceNKWebKit.md(the inventory count sentence on line 93 onmain, and for five of them also line 25 or lines 25-26, where this branch adds its entry), and none shares an export or a new file. The run failed closed (exit 2) on 54 that conflict withmainand were not compared line by line. I searched the added and removed lines of those 54 for these two exports, their NIDs and the new helper and found none. For #15807 GitHub refuses the whole diff, and the search covered its twolibSceNKWebKitfiles only. Whichever lands second recounts the sentence.Windows 11 Pro, WinLibs GCC, Release, on this branch (
56b1d33791, based onmain1ff0fe98aa):nkwebkit_webcoreprocess(a set before the first query is kept, and a later set replaces it),nkwebkit_webcoreprocessidentifier(the first query returns 1, stays 1, and a later set replaces it) and the neighbouringnkwebkit_palsessionid: 3 of 3 pass.public_headers: passes.main,identifier()is aNotImplemented_nid_no_patchstub (core/libs/prx/libSceNKWebKit/Export.cpp:30249there) andsetIdentifieris undeclared, which this PR's tests cannot pass or build against. Mutation probes on this branch, rebuilt each time:identifier()ignoring an earlier set:nkwebkit_webcoreprocessfails.setIdentifiernot storing: both tests fail.python3 tools/check_conventions.py --base upstream/mainon the committed head: all checks passed.python3 tools/pr_overlap.py --branch feat/nkwebkit-process-identifier: no line conflicts. #13486 is listed for the same export; GitHub's file list for its head0bde10d243is three relinker files, none inlibSceNKWebKit. 80 otherlibSceNKWebKitpull requests conflict withmainand could not be compared. A search of open pull requests forProcess::identifier,setIdentifier,ProcessIdentifierandObjectIdentifierfinds none that implements these.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