Files
AnyPS5/docs/dev/debt/libSceGnmDriverForNeoMode.md
T
Dean Galvin bd6b845ef4 Merge main into feat/gnm-debug-inventory-exports-20261030
# Conflicts:
#	docs/dev/debt/libSceGnmDriverForNeoMode.md
2026-11-01 21:13:14 +13:00

7.3 KiB

libSceGnmDriverForNeoMode technical debt

Unknown function info

  • sceGnmIsDebugResetAvailable (xMMot887QXE) - the PS5 firmware 13.60 export table and public NID map identify the export, but its signature and behaviour are unknown; its placeholder uses the no-parameter unknown-signature convention and throws through NotImplemented_nid_no_patch.
  • sceGnmDingDongForWorkload, sceGnmRegisterOwner - the first throws through NotImplemented_nid_no_patch and sceGnmRegisterOwner returns Failure (0x8EEE00FF) without registering anything; behaviour and the PS5 prototypes are unmeasured. The only source of the parameter lists is shadPS4's PS4-derived prototypes (GPLv2, used as a reference only), with no second reference; structure pointers are void* because no layout is known.
  • libSceGnmDriverForNeoMode pending exports - 34 named callable exports are listed in the PS5 3.20 export table and were cross-checked against the same module in PS5 firmware 13.60. Their signatures and behaviour are unverified; the declarations use the no-parameter unknown-signature convention and throw through NotImplemented_nid_no_patch.

Functional

  • retail-only answers (libSceGnmDriverForNeoMode) - the debug resets, the resource and owner registration calls, the SDMA calls and the SQ counter calls return 0x8EEE00FF, the five sceGnmDriverInternalRetrieveGnmInterface* calls return 0x80000000, sceGnmGetDbgGcHandle returns -1, sceGnmDriverTraceInProgress and sceGnmValidateOnSubmitEnabled return 0 and the other validation calls return 0x80D13FFF. These are the values shadPS4 returns for calls it marks as not available in retail firmware; they are not measured on a console, and the arguments are not read
  • default state packets (libSceGnmDriverForNeoMode) - sceGnmDrawInitDefaultHardwareState, sceGnmDrawInitDefaultHardwareState200, sceGnmDrawInitDefaultHardwareState350, sceGnmDrawInitToDefaultContextState and sceGnmDrawInitToDefaultContextState400 write the sequences in InitSequences.hpp, taken from shadPS4's gnmdriver_init.h: its Neo sequences, except the plain hardware state, which shadPS4 also writes unchanged in Neo mode. The size checks and returned sizes are shadPS4's. Not compared with console output, and nothing in AnyPS5 consumes a GNM command buffer yet
  • sceGnmDrawInitToDefaultContextStateInternalCommand (libSceGnmDriverForNeoMode) - answers as sceGnmDrawInitToDefaultContextState when the compiled SDK version in the process parameters is below 0x04000000 and as sceGnmDrawInitToDefaultContextState400 from it, as firmware 13.42's module does, run natively with its imports stubbed, not on a console. The module reads the version at init through sceKernelGetCompiledSdkVersion. From 0x04000000 its result and output equal ...State400 for every size tried (run). Below it, size 0x20 writes 19 words byte-identical to the module's own sceGnmDrawInitToDefaultContextState, from a copy of that sequence, and other sizes write nothing (@BunnyFl's comparison). The version is read at each call here, not cached at init
  • draw, dispatch, wait and VGT packets (libSceGnmDriverForNeoMode) - the signatures, size checks, PM4 words and refusals (-1) of the 17 command writers follow shadPS4 on its Neo-mode path, since this module is the Neo-mode driver: draw initiators keep flag bits 29 to 31, and sceGnmSetVgtControl and sceGnmResetVgtControl write IA_MULTI_VGT_PARAM through SET_UCONFIG_REG (shadPS4's UseNeoCompatSequences is false). The packets are not compared with console output, and nothing in AnyPS5 consumes a GNM command buffer yet
  • embedded shaders (libSceGnmDriverForNeoMode) - sceGnmSetEmbeddedVsShader (id 0, a fullscreen triangle) and sceGnmSetEmbeddedPsShader (id 0 writes black, id 1 exports depth only) write the register packets of shadPS4, pointing at the shader code in EmbeddedShaders.hpp in this module's memory instead of the console's 0xfe000f00 area. That code is shadPS4's instruction listing assembled with LLVM 19 llvm-mc -arch=amdgcn -mcpu=bonaire, without the binary header and register block that follow it on the console, since nothing here reads them; another id returns 0x8EEE00FF. The size and modifier arguments are not checked, as in shadPS4. Not compared with console output, and nothing in AnyPS5 consumes a GNM command buffer yet
  • shader register packets (libSceGnmDriverForNeoMode) - sceGnmUpdateVsShader, sceGnmUpdatePsShader, sceGnmUpdatePsShader350, sceGnmSetPsShader350, sceGnmUpdateGsShader, sceGnmUpdateHsShader and sceGnmSetCsShaderWithModifier write the packets, size checks and -1 refusals of shadPS4; the update forms carry context registers inside NOP packets as there. Not compared with console output, and nothing in AnyPS5 consumes a GNM command buffer yet
  • workloads (libSceGnmDriverForNeoMode) - sceGnmCreateWorkloadStream, sceGnmBeginWorkload and sceGnmEndWorkload return shadPS4's values (3 for a null output or name, 1 for a stream above 15, 2 for workload 0 or one with a top byte above 15) and keep no state; not measured on a console
  • sceGnmGetGpuCoreClockFrequency (libSceGnmDriverForNeoMode) - returns 911 MHz, shadPS4's Neo-mode value, which it derives from Neo mode instead of the console's ioctl. sceGnmGetOffChipTessellationBufferSize returns shadPS4's 0x800000

Additional callable exports

  • Additional callable exports - 20 callable NIDs are present in both version-labelled images. Both images also export these NIDs from the distinct normal Gnm provider; matching NIDs do not establish behavioral equivalence. Future declarations or implementations in that provider require loader analysis. Image labels are not authenticated. Names, signatures and behavior are unverified; each declaration throws.