Files
AnyPS5/docs/dev/debt/libSceGnmDriverForNeoMode.md
T

5.0 KiB

libSceGnmDriverForNeoMode technical debt

Unknown function info

  • 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
  • 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