Skip to content

GNM Driver API Reference

The gnmdriver.h header declares the full runtime driver API for the PS4's Graphics Next Microarchitecture (GNM) library. This is the primary interface between user-space applications and the GPU command processor. It contains 265 functions spanning draw/dispatch command emission, shader binding, command-buffer submission, SDMA transfers, compute-queue management, resource registration, workload tracking, thread tracing (Sqtt), performance monitoring (Spm), debugging, Razor profiling, markers, validation, and internal packet builders.

All functions use the PS4_SYSV_ABI calling convention. Functions with a void parameter list are retail stubs — they exist in the firmware export table but return a fixed error code (typically ORBIS_GNM_ERROR_UNIMPLEMENTED or 0) on retail consoles and are only functional on devkits.

Header: include/gnmdriver.h


SceGnmDrawFlags

Bitfield structure controlling draw-call behaviour. Passed to draw functions and their indirect variants.

typedef struct {
    uint32_t predication : 1;
    uint32_t _unused : 28;
    uint32_t rendertargetsliceoffset : 3;
} SceGnmDrawFlags;
_Static_assert(sizeof(SceGnmDrawFlags) == 0x4, "");
Field Bits Description
predication 1 If set, the draw is conditional on the current predication query result.
_unused 28 Reserved — must be zero.
rendertargetsliceoffset 3 Slice offset into the bound render target array (0–7).

Draw Commands

Functions that emit PM4 draw packets into a command buffer. Each takes a pointer to the command buffer (cmdbuf), the remaining size in dwords (size), and draw-specific parameters.

sceGnmDrawIndex

int32_t PS4_SYSV_ABI sceGnmDrawIndex(uint32_t* cmdbuf, uint32_t size,
                                     uint32_t index_count, uintptr_t index_addr,
                                     uint32_t flags, uint32_t type);

Emits an indexed draw using an explicit GPU-side index buffer address.

sceGnmDrawIndexAuto

int32_t PS4_SYSV_ABI sceGnmDrawIndexAuto(uint32_t* cmdbuf, uint32_t size,
                                         uint32_t index_count, uint32_t flags);

Emits an auto-indexed draw (sequential indices generated by hardware).

sceGnmDrawIndexIndirect

int32_t PS4_SYSV_ABI sceGnmDrawIndexIndirect(uint32_t* cmdbuf, uint32_t size,
                                             uint32_t data_offset,
                                             uint32_t shader_stage,
                                             uint32_t vertex_sgpr_offset,
                                             uint32_t instance_sgpr_offset,
                                             uint32_t flags);

Emits an indirect indexed draw whose parameters are read from a GPU buffer at data_offset.

sceGnmDrawIndexIndirectCountMulti

int32_t PS4_SYSV_ABI sceGnmDrawIndexIndirectCountMulti(
    uint32_t* cmdbuf, uint32_t size, uint32_t data_offset, uint32_t max_count,
    uint64_t count_addr, uint32_t shader_stage, uint32_t vertex_sgpr_offset,
    uint32_t instance_sgpr_offset, uint32_t flags);

Emits multiple indirect indexed draws, with the actual count read from count_addr.

sceGnmDrawIndexIndirectMulti

int PS4_SYSV_ABI sceGnmDrawIndexIndirectMulti(uint32_t* cmdbuf, uint32_t size,
                                              uint32_t data_offset,
                                              uint32_t max_count,
                                              uint32_t shader_stage,
                                              uint32_t vertex_sgpr_offset,
                                              uint32_t instance_sgpr_offset,
                                              uint32_t flags);

Emits a fixed number (max_count) of indirect indexed draws.

sceGnmDrawIndexMultiInstanced

int PS4_SYSV_ABI sceGnmDrawIndexMultiInstanced(void);

Retail stub — no parameters available on retail firmware.

sceGnmDrawIndexOffset

int32_t PS4_SYSV_ABI sceGnmDrawIndexOffset(uint32_t* cmdbuf, uint32_t size,
                                           uint32_t index_offset,
                                           uint32_t index_count,
                                           uint32_t flags);

Emits an indexed draw with a dword offset into the currently bound index buffer.

sceGnmDrawIndirect

int32_t PS4_SYSV_ABI sceGnmDrawIndirect(uint32_t* cmdbuf, uint32_t size,
                                        uint32_t data_offset,
                                        uint32_t shader_stage,
                                        uint32_t vertex_sgpr_offset,
                                        uint32_t instance_sgpr_offset,
                                        uint32_t flags);

Emits a non-indexed indirect draw.

sceGnmDrawIndirectCountMulti

int PS4_SYSV_ABI sceGnmDrawIndirectCountMulti(void);

Retail stub — no parameters available on retail firmware.

sceGnmDrawIndirectMulti

int32_t PS4_SYSV_ABI sceGnmDrawIndirectMulti(uint32_t* cmdbuf, uint32_t size,
                                             uint32_t data_offset,
                                             uint32_t max_count,
                                             uint32_t shader_stage,
                                             uint32_t vertex_sgpr_offset,
                                             uint32_t instance_sgpr_offset,
                                             uint32_t flags);

Emits a fixed number (max_count) of non-indexed indirect draws.

sceGnmDrawOpaqueAuto

int PS4_SYSV_ABI sceGnmDrawOpaqueAuto(void);

Retail stub — no parameters available on retail firmware.


Dispatch Commands

Compute-dispatch functions that launch thread groups on the compute units.

sceGnmDispatchDirect

int32_t PS4_SYSV_ABI sceGnmDispatchDirect(uint32_t* cmdbuf, uint32_t size,
                                          uint32_t threads_x,
                                          uint32_t threads_y,
                                          uint32_t threads_z,
                                          uint32_t flags);

Dispatches a compute shader with explicit thread-group dimensions.

sceGnmDispatchIndirect

int32_t PS4_SYSV_ABI sceGnmDispatchIndirect(uint32_t* cmdbuf, uint32_t size,
                                            uint32_t data_offset,
                                            uint32_t flags);

Dispatches a compute shader whose dimensions are read from a GPU buffer.

sceGnmDispatchIndirectOnMec

int32_t PS4_SYSV_ABI sceGnmDispatchIndirectOnMec(uint32_t* cmdbuf,
                                                 uint32_t size,
                                                 uintptr_t args,
                                                 uint32_t modifier);

Dispatches indirectly on the MEC (Micro-Engine Compute) pipe.


Shader Set Commands

Functions that bind shader programs to specific pipeline stages.

sceGnmSetCsShader

int32_t PS4_SYSV_ABI sceGnmSetCsShader(uint32_t* cmdbuf, uint32_t size,
                                       const uint32_t* cs_regs);

Binds a compute shader.

sceGnmSetCsShaderWithModifier

int32_t PS4_SYSV_ABI sceGnmSetCsShaderWithModifier(uint32_t* cmdbuf,
                                                   uint32_t size,
                                                   const uint32_t* cs_regs,
                                                   uint32_t modifier);

Binds a compute shader with an additional modifier (e.g. trap present).

sceGnmSetEmbeddedPsShader

int32_t PS4_SYSV_ABI sceGnmSetEmbeddedPsShader(uint32_t* cmdbuf,
                                               uint32_t size,
                                               uint32_t shader_id,
                                               uint32_t shader_modifier);

Binds an embedded (firmware-provided) pixel shader by ID.

sceGnmSetEmbeddedVsShader

int32_t PS4_SYSV_ABI sceGnmSetEmbeddedVsShader(uint32_t* cmdbuf,
                                               uint32_t size,
                                               uint32_t shader_id,
                                               uint32_t modifier);

Binds an embedded (firmware-provided) vertex shader by ID.

sceGnmSetEsShader

int32_t PS4_SYSV_ABI sceGnmSetEsShader(uint32_t* cmdbuf, uint32_t size,
                                       const uint32_t* es_regs,
                                       uint32_t shader_modifier);

Binds an export shader (geometry-shader amplification path).

sceGnmSetGsRingSizes

int PS4_SYSV_ABI sceGnmSetGsRingSizes(void);

Retail stub — no parameters available on retail firmware.

sceGnmSetGsShader

int32_t PS4_SYSV_ABI sceGnmSetGsShader(uint32_t* cmdbuf, uint32_t size,
                                       const uint32_t* gs_regs);

Binds a geometry shader.

sceGnmSetHsShader

int32_t PS4_SYSV_ABI sceGnmSetHsShader(uint32_t* cmdbuf, uint32_t size,
                                       const uint32_t* hs_regs,
                                       uint32_t param4);

Binds a hull shader (tessellation control stage).

sceGnmSetLsShader

int32_t PS4_SYSV_ABI sceGnmSetLsShader(uint32_t* cmdbuf, uint32_t size,
                                       const uint32_t* ls_regs,
                                       uint32_t shader_modifier);

Binds a local shader (tessellation vertex-fetch / LS stage).

sceGnmSetPsShader

int32_t PS4_SYSV_ABI sceGnmSetPsShader(uint32_t* cmdbuf, uint32_t size,
                                       const uint32_t* ps_regs);

Binds a pixel shader.

sceGnmSetPsShader350

int32_t PS4_SYSV_ABI sceGnmSetPsShader350(uint32_t* cmdbuf, uint32_t size,
                                          const uint32_t* ps_regs);

Binds a pixel shader using the GFX 3.50 (Neo-enhanced) register layout.

sceGnmSetVsShader

int32_t PS4_SYSV_ABI sceGnmSetVsShader(uint32_t* cmdbuf, uint32_t size,
                                       const uint32_t* vs_regs,
                                       uint32_t shader_modifier);

Binds a vertex shader.


Shader Update Commands

Functions that update already-bound shader registers without a full re-bind. Useful for partial state changes (e.g. updating resource descriptors).

sceGnmUpdateGsShader

int32_t PS4_SYSV_ABI sceGnmUpdateGsShader(uint32_t* cmdbuf, uint32_t size,
                                          const uint32_t* gs_regs);

Updates the currently bound geometry shader registers.

sceGnmUpdateHsShader

int PS4_SYSV_ABI sceGnmUpdateHsShader(uint32_t* cmdbuf, uint32_t size,
                                      const uint32_t* ps_regs,
                                      uint32_t ls_hs_config);

Updates the currently bound hull shader registers.

sceGnmUpdatePsShader

int32_t PS4_SYSV_ABI sceGnmUpdatePsShader(uint32_t* cmdbuf, uint32_t size,
                                          const uint32_t* ps_regs);

Updates the currently bound pixel shader registers.

sceGnmUpdatePsShader350

int32_t PS4_SYSV_ABI sceGnmUpdatePsShader350(uint32_t* cmdbuf, uint32_t size,
                                             const uint32_t* ps_regs);

Updates the currently bound pixel shader registers (GFX 3.50 layout).

sceGnmUpdateVsShader

int32_t PS4_SYSV_ABI sceGnmUpdateVsShader(uint32_t* cmdbuf, uint32_t size,
                                          const uint32_t* vs_regs,
                                          uint32_t shader_modifier);

Updates the currently bound vertex shader registers.


Submit Commands

Functions that submit command buffers to the GPU for execution. The draw command buffer (DCB) contains draw/state packets; the constant command buffer (CCB) contains constant updates.

sceGnmAreSubmitsAllowed

int PS4_SYSV_ABI sceGnmAreSubmitsAllowed(void);

Returns whether command-buffer submission is currently permitted.

sceGnmRequestFlipAndSubmitDone

int PS4_SYSV_ABI sceGnmRequestFlipAndSubmitDone(void);

Retail stub — requests a flip and signals submit completion.

sceGnmRequestFlipAndSubmitDoneForWorkload

int PS4_SYSV_ABI sceGnmRequestFlipAndSubmitDoneForWorkload(void);

Retail stub — requests a flip and signals submit completion for a specific workload.

sceGnmSubmitAndFlipCommandBuffers

int PS4_SYSV_ABI sceGnmSubmitAndFlipCommandBuffers(
    uint32_t count, void* const dcb_gpu_addrs[],
    uint32_t* dcb_sizes_in_bytes, void* const ccb_gpu_addrs[],
    uint32_t* ccb_sizes_in_bytes, uint32_t vo_handle, uint32_t buf_idx,
    uint32_t flip_mode, int64_t flip_arg);

Submits command buffers and requests a display flip on completion.

sceGnmSubmitAndFlipCommandBuffersForWorkload

int PS4_SYSV_ABI sceGnmSubmitAndFlipCommandBuffersForWorkload(
    uint32_t workload, uint32_t count, void* const dcb_gpu_addrs[],
    uint32_t* dcb_sizes_in_bytes, void* const ccb_gpu_addrs[],
    uint32_t* ccb_sizes_in_bytes, uint32_t vo_handle, uint32_t buf_idx,
    uint32_t flip_mode, int64_t flip_arg);

Submits command buffers for a specific workload and requests a display flip.

sceGnmSubmitCommandBuffers

int32_t PS4_SYSV_ABI sceGnmSubmitCommandBuffers(
    uint32_t count, void* const dcb_gpu_addrs[],
    uint32_t* dcb_sizes_in_bytes, void* const ccb_gpu_addrs[],
    uint32_t* ccb_sizes_in_bytes);

Submits one or more draw/constant command-buffer pairs to the GPU.

sceGnmSubmitCommandBuffersForWorkload

int PS4_SYSV_ABI sceGnmSubmitCommandBuffersForWorkload(
    uint32_t workload, uint32_t count, void* const dcb_gpu_addrs[],
    uint32_t* dcb_sizes_in_bytes, void* const ccb_gpu_addrs[],
    uint32_t* ccb_sizes_in_bytes);

Submits command buffers associated with a specific workload stream.

sceGnmSubmitDone

int PS4_SYSV_ABI sceGnmSubmitDone(void);

Signals that all command-buffer submission for the current frame is complete.


Init / Default Hardware State

Functions that emit the initial hardware-state setup packets into a command buffer. These should be called once at the start of a command buffer before any draw or dispatch.

sceGnmDispatchInitDefaultHardwareState

uint32_t PS4_SYSV_ABI sceGnmDispatchInitDefaultHardwareState(uint32_t* cmdbuf,
                                                             uint32_t size);

Emits default compute hardware state into cmdbuf. Returns the number of dwords written.

sceGnmDrawInitDefaultHardwareState

uint32_t PS4_SYSV_ABI sceGnmDrawInitDefaultHardwareState(uint32_t* cmdbuf,
                                                         uint32_t size);

Emits default graphics hardware state into cmdbuf. Returns the number of dwords written.

sceGnmDrawInitDefaultHardwareState175

uint32_t PS4_SYSV_ABI sceGnmDrawInitDefaultHardwareState175(uint32_t* cmdbuf,
                                                            uint32_t size);

Emits default graphics state for GFX 1.75 (base PS4 GPU).

sceGnmDrawInitDefaultHardwareState200

uint32_t PS4_SYSV_ABI sceGnmDrawInitDefaultHardwareState200(uint32_t* cmdbuf,
                                                            uint32_t size);

Emits default graphics state for GFX 2.00.

sceGnmDrawInitDefaultHardwareState350

uint32_t PS4_SYSV_ABI sceGnmDrawInitDefaultHardwareState350(uint32_t* cmdbuf,
                                                            uint32_t size);

Emits default graphics state for GFX 3.50 (PS4 Pro / Neo).

sceGnmDrawInitToDefaultContextState

uint32_t PS4_SYSV_ABI sceGnmDrawInitToDefaultContextState(uint32_t* cmdbuf,
                                                          uint32_t size);

Emits packets that initialise the GPU context state to defaults.

sceGnmDrawInitToDefaultContextState400

uint32_t PS4_SYSV_ABI sceGnmDrawInitToDefaultContextState400(uint32_t* cmdbuf,
                                                             uint32_t size);

Emits packets that initialise the GPU context state to defaults (GFX 4.00 layout).

sceGnmDrawInitToDefaultContextStateInternalCommand

int PS4_SYSV_ABI sceGnmDrawInitToDefaultContextStateInternalCommand(
    uint32_t* cmdbuf, uint32_t size);

Emits the internal command portion of the default context-state initialisation.

sceGnmDrawInitToDefaultContextStateInternalSize

int PS4_SYSV_ABI sceGnmDrawInitToDefaultContextStateInternalSize(void);

Returns the size (in dwords) of the internal default-context-state command.


SDMA Commands

The SDMA (System DMA) engine performs asynchronous memory copies and fills independently of the graphics/compute pipes. All SDMA functions in this header are retail stubs.

sceGnmSdmaClose

int PS4_SYSV_ABI sceGnmSdmaClose(void);

Retail stub — closes the SDMA engine session.

sceGnmSdmaConstFill

int PS4_SYSV_ABI sceGnmSdmaConstFill(void);

Retail stub — fills a memory range with a constant value via SDMA.

sceGnmSdmaCopyLinear

int PS4_SYSV_ABI sceGnmSdmaCopyLinear(void);

Retail stub — copies linear memory via SDMA.

sceGnmSdmaCopyTiled

int PS4_SYSV_ABI sceGnmSdmaCopyTiled(void);

Retail stub — copies tiled memory via SDMA.

sceGnmSdmaCopyWindow

int PS4_SYSV_ABI sceGnmSdmaCopyWindow(void);

Retail stub — copies a rectangular window of memory via SDMA.

sceGnmSdmaFlush

int PS4_SYSV_ABI sceGnmSdmaFlush(void);

Retail stub — flushes pending SDMA operations.

sceGnmSdmaGetMinCmdSize

int PS4_SYSV_ABI sceGnmSdmaGetMinCmdSize(void);

Retail stub — returns the minimum SDMA command-buffer size.

sceGnmSdmaOpen

int PS4_SYSV_ABI sceGnmSdmaOpen(void);

Retail stub — opens an SDMA engine session.


Compute Queue Management

Functions for managing the ACE (Asynchronous Compute Engine) compute queues, including queue mapping, signalling, and waiting.

sceGnmComputeWaitOnAddress

int32_t PS4_SYSV_ABI sceGnmComputeWaitOnAddress(uint32_t* cmdbuf,
                                                uint32_t size,
                                                uintptr_t addr,
                                                uint32_t mask,
                                                uint32_t cmp_func,
                                                uint32_t ref);

Emits a compute-pipe wait on a memory address with a comparison function.

sceGnmComputeWaitSemaphore

int32_t PS4_SYSV_ABI sceGnmComputeWaitSemaphore(void);

Retail stub — emits a compute-pipe semaphore wait.

sceGnmDingDong

void PS4_SYSV_ABI sceGnmDingDong(uint32_t gnm_vqid, uint32_t next_offs_dw);

Signals a compute queue (VQ) that new work is available up to next_offs_dw.

sceGnmDingDongForWorkload

void PS4_SYSV_ABI sceGnmDingDongForWorkload(uint32_t gnm_vqid,
                                            uint32_t next_offs_dw,
                                            uint64_t workload_id);

Signals a compute queue for a specific workload.

sceGnmMapComputeQueue

int PS4_SYSV_ABI sceGnmMapComputeQueue(uint32_t pipe_id, uint32_t queue_id,
                                       uintptr_t ring_base_addr,
                                       uint32_t ring_size_dw,
                                       uint32_t* read_ptr_addr);

Maps a compute queue on the specified ACE pipe and queue slot.

sceGnmMapComputeQueueWithPriority

int PS4_SYSV_ABI sceGnmMapComputeQueueWithPriority(
    uint32_t pipe_id, uint32_t queue_id, uintptr_t ring_base_addr,
    uint32_t ring_size_dw, uint32_t* read_ptr_addr, uint32_t pipePriority);

Maps a compute queue with an explicit priority level.

sceGnmUnmapComputeQueue

int PS4_SYSV_ABI sceGnmUnmapComputeQueue(uint32_t vqid);

Unmaps a previously mapped compute queue.


VGT / Wave Control

Functions that configure the Vertex Grouper / Tessellator (VGT) and shader-wave scheduling.

sceGnmResetVgtControl

int32_t PS4_SYSV_ABI sceGnmResetVgtControl(uint32_t* cmdbuf, uint32_t size);

Resets VGT control registers to their default state.

sceGnmSetVgtControl

int32_t PS4_SYSV_ABI sceGnmSetVgtControl(uint32_t* cmdbuf, uint32_t size,
                                         uint32_t prim_group_sz_minus_one,
                                         uint32_t partial_vs_wave_mode,
                                         uint32_t wd_switch_only_on_eop_mode);

Configures VGT primitive-group size and wave-dispatch modes.

sceGnmSetWaveLimitMultiplier

int PS4_SYSV_ABI sceGnmSetWaveLimitMultiplier(void);

Retail stub — sets the global wave-limit multiplier.

sceGnmSetWaveLimitMultipliers

int PS4_SYSV_ABI sceGnmSetWaveLimitMultipliers(void);

Retail stub — sets per-pipe wave-limit multipliers.

sceGnmSetSpiEnableSqCounters

int PS4_SYSV_ABI sceGnmSetSpiEnableSqCounters(void);

Retail stub — enables SQ performance counters via the SPI block.

sceGnmSetSpiEnableSqCountersForUnitInstance

int PS4_SYSV_ABI sceGnmSetSpiEnableSqCountersForUnitInstance(void);

Retail stub — enables SQ counters for a specific unit/instance.


Validation

Functions for command-buffer validation. On devkits these perform runtime checks; on retail they are stubs.

sceGnmValidateCommandBuffers

int32_t PS4_SYSV_ABI sceGnmValidateCommandBuffers(void);

Retail stub — validates draw and constant command buffers before submission.

sceGnmValidateDisableDiagnostics

int PS4_SYSV_ABI sceGnmValidateDisableDiagnostics(void);

Retail stub — disables validation diagnostics.

sceGnmValidateDisableDiagnostics2

int PS4_SYSV_ABI sceGnmValidateDisableDiagnostics2(void);

Retail stub — disables validation diagnostics (variant 2).

sceGnmValidateDispatchCommandBuffers

int PS4_SYSV_ABI sceGnmValidateDispatchCommandBuffers(void);

Retail stub — validates compute-dispatch command buffers.

sceGnmValidateDrawCommandBuffers

int PS4_SYSV_ABI sceGnmValidateDrawCommandBuffers(void);

Retail stub — validates draw command buffers.

sceGnmValidateGetDiagnosticInfo

int PS4_SYSV_ABI sceGnmValidateGetDiagnosticInfo(void);

Retail stub — retrieves detailed validation diagnostic information.

sceGnmValidateGetDiagnostics

int PS4_SYSV_ABI sceGnmValidateGetDiagnostics(void);

Retail stub — retrieves validation diagnostics.

sceGnmValidateGetVersion

int PS4_SYSV_ABI sceGnmValidateGetVersion(void);

Retail stub — returns the validation engine version.

sceGnmValidateOnSubmitEnabled

bool PS4_SYSV_ABI sceGnmValidateOnSubmitEnabled(void);

Returns true if on-submit validation is enabled.

sceGnmValidateResetState

int PS4_SYSV_ABI sceGnmValidateResetState(void);

Retail stub — resets the validation engine state.

sceGnmValidationRegisterMemoryCheckCallback

int PS4_SYSV_ABI sceGnmValidationRegisterMemoryCheckCallback(void);

Retail stub — registers a memory-check callback for validation.


Resource Registration

Functions for registering GPU resources (buffers, textures, etc.) with the driver for tracking, debugging, and validation.

sceGnmFindResourcesPublic

int32_t PS4_SYSV_ABI sceGnmFindResourcesPublic(void);

Retail stub — finds publicly registered resources.

sceGnmFindResources

int PS4_SYSV_ABI sceGnmFindResources(void);

Retail stub — finds registered resources.

sceGnmGetResourceBaseAddressAndSizeInBytes

int PS4_SYSV_ABI sceGnmGetResourceBaseAddressAndSizeInBytes(void);

Retail stub — retrieves a resource's base address and size.

sceGnmGetResourceName

int PS4_SYSV_ABI sceGnmGetResourceName(void);

Retail stub — retrieves a resource's name string.

sceGnmGetResourceRegistrationBuffers

int PS4_SYSV_ABI sceGnmGetResourceRegistrationBuffers(void);

Retail stub — retrieves the resource-registration buffer pointers.

sceGnmGetResourceShaderGuid

int PS4_SYSV_ABI sceGnmGetResourceShaderGuid(void);

Retail stub — retrieves a resource's shader GUID.

sceGnmGetResourceType

int PS4_SYSV_ABI sceGnmGetResourceType(void);

Retail stub — retrieves a resource's type.

sceGnmGetResourceUserData

int PS4_SYSV_ABI sceGnmGetResourceUserData(void);

Retail stub — retrieves a resource's user-data pointer.

sceGnmQueryResourceRegistrationUserMemoryRequirements

int PS4_SYSV_ABI sceGnmQueryResourceRegistrationUserMemoryRequirements(void);

Retail stub — queries the memory requirements for resource-registration user memory.

sceGnmRegisterGdsResource

int PS4_SYSV_ABI sceGnmRegisterGdsResource(void);

Retail stub — registers a GDS (Global Data Share) resource.

sceGnmRegisterOwner

int32_t PS4_SYSV_ABI sceGnmRegisterOwner(void* handle, const char* name);

Registers a resource owner (e.g. a process or context) with the driver.

sceGnmRegisterOwnerForSystem

int PS4_SYSV_ABI sceGnmRegisterOwnerForSystem(void);

Retail stub — registers a system-level resource owner.

sceGnmRegisterResource

int32_t PS4_SYSV_ABI sceGnmRegisterResource(void* res_handle,
                                            void* owner_handle,
                                            const void* addr, size_t size,
                                            const char* name, int res_type,
                                            uint64_t user_data);

Registers a GPU-accessible resource with the driver for tracking.

sceGnmSetResourceRegistrationUserMemory

int PS4_SYSV_ABI sceGnmSetResourceRegistrationUserMemory(void);

Retail stub — sets user-memory buffers for resource registration.

sceGnmSetResourceUserData

int PS4_SYSV_ABI sceGnmSetResourceUserData(void);

Retail stub — sets user data on a registered resource.

sceGnmUnregisterAllResourcesForOwner

int PS4_SYSV_ABI sceGnmUnregisterAllResourcesForOwner(void);

Retail stub — unregisters all resources belonging to an owner.

sceGnmUnregisterOwnerAndResources

int PS4_SYSV_ABI sceGnmUnregisterOwnerAndResources(void);

Retail stub — unregisters an owner and all its resources.

sceGnmUnregisterResource

int PS4_SYSV_ABI sceGnmUnregisterResource(void);

Retail stub — unregisters a single resource.


Workload Management

Functions for creating and managing workload streams, which group related command-buffer submissions.

sceGnmBeginWorkload

int PS4_SYSV_ABI sceGnmBeginWorkload(uint32_t workload_stream,
                                      uint64_t* workload);

Begins a new workload within a workload stream. Returns a workload handle in *workload.

sceGnmCreateWorkloadStream

int PS4_SYSV_ABI sceGnmCreateWorkloadStream(uint64_t param1,
                                            uint32_t* workload_stream);

Creates a new workload stream. Returns a stream handle in *workload_stream.

sceGnmDestroyWorkloadStream

int PS4_SYSV_ABI sceGnmDestroyWorkloadStream(void);

Retail stub — destroys a workload stream.

sceGnmEndWorkload

int PS4_SYSV_ABI sceGnmEndWorkload(uint64_t workload);

Ends a previously begun workload.


Event Queue

Functions for managing GPU event-queue (EQ) notifications.

sceGnmAddEqEvent

int32_t PS4_SYSV_ABI sceGnmAddEqEvent(void* eq, uint64_t id, void* udata);

Adds an event to a kernel event queue. eq is an OrbisKernelEqueue (opaque void*).

sceGnmDeleteEqEvent

int32_t PS4_SYSV_ABI sceGnmDeleteEqEvent(void* eq, uint64_t id);

Deletes an event from a kernel event queue.

sceGnmGetEqEventType

int PS4_SYSV_ABI sceGnmGetEqEventType(const void* ev);

Returns the event type from a kernel event object. ev is an OrbisKernelEvent (opaque void*).

sceGnmGetEqTimeStamp

int PS4_SYSV_ABI sceGnmGetEqTimeStamp(void);

Retail stub — retrieves the timestamp from an EQ event.


Thread Trace / Sqtt

Software Queue Thread Trace (Sqtt) functions for GPU profiling. All Sqtt functions in this header are retail stubs.

sceGnmInsertThreadTraceMarker

int PS4_SYSV_ABI sceGnmInsertThreadTraceMarker(void);

Retail stub — inserts a thread-trace marker into the command stream.

sceGnmSqttFini

int PS4_SYSV_ABI sceGnmSqttFini(void);

Retail stub — finalises the Sqtt subsystem.

sceGnmSqttFinishTrace

int PS4_SYSV_ABI sceGnmSqttFinishTrace(void);

Retail stub — finishes an in-progress trace.

sceGnmSqttGetBcInfo

int PS4_SYSV_ABI sceGnmSqttGetBcInfo(void);

Retail stub — retrieves block-compressor info from the trace.

sceGnmSqttGetGpuClocks

int PS4_SYSV_ABI sceGnmSqttGetGpuClocks(void);

Retail stub — retrieves GPU clock snapshot from the trace.

sceGnmSqttGetHiWater

int PS4_SYSV_ABI sceGnmSqttGetHiWater(void);

Retail stub — retrieves the high-water mark of the trace buffer.

sceGnmSqttGetStatus

int PS4_SYSV_ABI sceGnmSqttGetStatus(void);

Retail stub — retrieves the current Sqtt status.

sceGnmSqttGetTraceCounter

int PS4_SYSV_ABI sceGnmSqttGetTraceCounter(void);

Retail stub — retrieves the trace counter value.

sceGnmSqttGetTraceWptr

int PS4_SYSV_ABI sceGnmSqttGetTraceWptr(void);

Retail stub — retrieves the trace buffer write pointer.

sceGnmSqttGetWrapCounts

int PS4_SYSV_ABI sceGnmSqttGetWrapCounts(void);

Retail stub — retrieves trace buffer wrap-around counts.

sceGnmSqttGetWrapCounts2

int PS4_SYSV_ABI sceGnmSqttGetWrapCounts2(void);

Retail stub — retrieves trace buffer wrap-around counts (variant 2).

sceGnmSqttGetWritebackLabels

int PS4_SYSV_ABI sceGnmSqttGetWritebackLabels(void);

Retail stub — retrieves writeback labels from the trace.

sceGnmSqttInit

int PS4_SYSV_ABI sceGnmSqttInit(void);

Retail stub — initialises the Sqtt subsystem.

sceGnmSqttSelectMode

int PS4_SYSV_ABI sceGnmSqttSelectMode(void);

Retail stub — selects the Sqtt trace mode.

sceGnmSqttSelectTarget

int PS4_SYSV_ABI sceGnmSqttSelectTarget(void);

Retail stub — selects the Sqtt trace target.

sceGnmSqttSelectTokens

int PS4_SYSV_ABI sceGnmSqttSelectTokens(void);

Retail stub — selects which Sqtt token types to capture.

sceGnmSqttSetCuPerfMask

int PS4_SYSV_ABI sceGnmSqttSetCuPerfMask(void);

Retail stub — sets the CU performance mask for tracing.

sceGnmSqttSetDceEventWrite

int PS4_SYSV_ABI sceGnmSqttSetDceEventWrite(void);

Retail stub — configures DCE event-write tracing.

sceGnmSqttSetHiWater

int PS4_SYSV_ABI sceGnmSqttSetHiWater(void);

Retail stub — sets the trace buffer high-water mark.

sceGnmSqttSetTraceBuffer2

int PS4_SYSV_ABI sceGnmSqttSetTraceBuffer2(void);

Retail stub — sets the secondary trace buffer.

sceGnmSqttSetTraceBuffers

int PS4_SYSV_ABI sceGnmSqttSetTraceBuffers(void);

Retail stub — sets the primary and secondary trace buffers.

sceGnmSqttSetUserData

int PS4_SYSV_ABI sceGnmSqttSetUserData(void);

Retail stub — sets user-data tokens for the trace.

sceGnmSqttSetUserdataTimer

int PS4_SYSV_ABI sceGnmSqttSetUserdataTimer(void);

Retail stub — sets a timer for user-data token emission.

sceGnmSqttStartTrace

int PS4_SYSV_ABI sceGnmSqttStartTrace(void);

Retail stub — starts a thread trace.

sceGnmSqttStopTrace

int PS4_SYSV_ABI sceGnmSqttStopTrace(void);

Retail stub — stops an in-progress thread trace.

sceGnmSqttSwitchTraceBuffer

int PS4_SYSV_ABI sceGnmSqttSwitchTraceBuffer(void);

Retail stub — switches to the alternate trace buffer.

sceGnmSqttSwitchTraceBuffer2

int PS4_SYSV_ABI sceGnmSqttSwitchTraceBuffer2(void);

Retail stub — switches to the alternate trace buffer (variant 2).

sceGnmSqttWaitForEvent

int PS4_SYSV_ABI sceGnmSqttWaitForEvent(void);

Retail stub — waits for an Sqtt event.


Performance Monitoring / Spm

Shader Performance Monitor (Spm) functions for hardware counter-based profiling. All Spm functions in this header are retail stubs.

sceGnmSpmEndSpm

int PS4_SYSV_ABI sceGnmSpmEndSpm(void);

Retail stub — ends Spm counter collection.

sceGnmSpmInit

int PS4_SYSV_ABI sceGnmSpmInit(void);

Retail stub — initialises the Spm subsystem.

sceGnmSpmInit2

int PS4_SYSV_ABI sceGnmSpmInit2(void);

Retail stub — initialises the Spm subsystem (variant 2).

sceGnmSpmSetDelay

int PS4_SYSV_ABI sceGnmSpmSetDelay(void);

Retail stub — sets the Spm sampling delay.

sceGnmSpmSetMuxRam

int PS4_SYSV_ABI sceGnmSpmSetMuxRam(void);

Retail stub — sets the Spm mux RAM configuration.

sceGnmSpmSetMuxRam2

int PS4_SYSV_ABI sceGnmSpmSetMuxRam2(void);

Retail stub — sets the Spm mux RAM configuration (variant 2).

sceGnmSpmSetSelectCounter

int PS4_SYSV_ABI sceGnmSpmSetSelectCounter(void);

Retail stub — selects an Spm counter.

sceGnmSpmSetSpmSelects

int PS4_SYSV_ABI sceGnmSpmSetSpmSelects(void);

Retail stub — sets Spm select registers.

sceGnmSpmSetSpmSelects2

int PS4_SYSV_ABI sceGnmSpmSetSpmSelects2(void);

Retail stub — sets Spm select registers (variant 2).

sceGnmSpmStartSpm

int PS4_SYSV_ABI sceGnmSpmStartSpm(void);

Retail stub — starts Spm counter collection.


Debugger

GPU debugger functions for hardware-level debugging (wavefront halting, GDS access, address watchpoints). All debugger functions in this header are retail stubs.

sceGnmDebugHardwareStatus

int PS4_SYSV_ABI sceGnmDebugHardwareStatus(void);

Retail stub — retrieves the current hardware debug status.

sceGnmDebugModuleReset

int PS4_SYSV_ABI sceGnmDebugModuleReset(void);

Retail stub — resets a debug module.

sceGnmDebugReset

int PS4_SYSV_ABI sceGnmDebugReset(void);

Retail stub — resets the entire debug subsystem.

sceGnmDebuggerGetAddressWatch

int PS4_SYSV_ABI sceGnmDebuggerGetAddressWatch(void);

Retail stub — retrieves an address-watchpoint configuration.

sceGnmDebuggerHaltWavefront

int PS4_SYSV_ABI sceGnmDebuggerHaltWavefront(void);

Retail stub — halts a wavefront for debugging.

sceGnmDebuggerReadGds

int PS4_SYSV_ABI sceGnmDebuggerReadGds(void);

Retail stub — reads from the Global Data Share.

sceGnmDebuggerReadSqIndirectRegister

int PS4_SYSV_ABI sceGnmDebuggerReadSqIndirectRegister(void);

Retail stub — reads an SQ indirect register.

sceGnmDebuggerResumeWavefront

int PS4_SYSV_ABI sceGnmDebuggerResumeWavefront(void);

Retail stub — resumes a halted wavefront.

sceGnmDebuggerResumeWavefrontCreation

int PS4_SYSV_ABI sceGnmDebuggerResumeWavefrontCreation(void);

Retail stub — resumes wavefront creation.

sceGnmDebuggerSetAddressWatch

int PS4_SYSV_ABI sceGnmDebuggerSetAddressWatch(void);

Retail stub — sets an address watchpoint.

sceGnmDebuggerWriteGds

int PS4_SYSV_ABI sceGnmDebuggerWriteGds(void);

Retail stub — writes to the Global Data Share.

sceGnmDebuggerWriteSqIndirectRegister

int PS4_SYSV_ABI sceGnmDebuggerWriteSqIndirectRegister(void);

Retail stub — writes an SQ indirect register.

sceGnmGetDbgGcHandle

int PS4_SYSV_ABI sceGnmGetDbgGcHandle(void);

Retail stub — retrieves the graphics-compute debug handle.


Razor

Razor GPU profiler/debugger exports. All Razor functions in this header are retail stubs.

sceRazorCaptureCommandBuffersOnlyImmediate

int PS4_SYSV_ABI sceRazorCaptureCommandBuffersOnlyImmediate(void);

Retail stub — triggers an immediate Razor capture of command buffers only.

sceRazorCaptureCommandBuffersOnlySinceLastFlip

int PS4_SYSV_ABI sceRazorCaptureCommandBuffersOnlySinceLastFlip(void);

Retail stub — triggers a Razor capture of command buffers since the last flip.

sceRazorCaptureImmediate

int PS4_SYSV_ABI sceRazorCaptureImmediate(void);

Retail stub — triggers an immediate Razor capture.

sceRazorCaptureSinceLastFlip

int PS4_SYSV_ABI sceRazorCaptureSinceLastFlip(void);

Retail stub — triggers a Razor capture of all work since the last flip.

sceRazorIsLoaded

bool PS4_SYSV_ABI sceRazorIsLoaded(void);

Returns true if the Razor profiler is loaded.


Markers

Functions that insert debug markers into the command stream for profiling and debugging tools.

sceGnmInsertDingDongMarker

int32_t PS4_SYSV_ABI sceGnmInsertDingDongMarker(uint32_t* cmdbuf,
                                                uint32_t size);

Inserts a ding-dong (compute-signal) marker into the command buffer.

sceGnmInsertPopMarker

int32_t PS4_SYSV_ABI sceGnmInsertPopMarker(uint32_t* cmdbuf, uint32_t size);

Pops the current debug marker scope.

sceGnmInsertPushColorMarker

int32_t PS4_SYSV_ABI sceGnmInsertPushColorMarker(uint32_t* cmdbuf,
                                                 uint32_t size,
                                                 const char* marker,
                                                 uint32_t color);

Pushes a new coloured debug marker scope.

sceGnmInsertPushMarker

int32_t PS4_SYSV_ABI sceGnmInsertPushMarker(uint32_t* cmdbuf, uint32_t size,
                                            const char* marker);

Pushes a new debug marker scope.

sceGnmInsertSetColorMarker

int PS4_SYSV_ABI sceGnmInsertSetColorMarker(void);

Retail stub — sets a coloured marker without pushing a scope.

sceGnmInsertSetMarker

int32_t PS4_SYSV_ABI sceGnmInsertSetMarker(uint32_t* cmdbuf, uint32_t size,
                                           const char* marker);

Sets a debug marker without pushing a scope.

sceGnmInsertWaitFlipDone

int32_t PS4_SYSV_ABI sceGnmInsertWaitFlipDone(uint32_t* cmdbuf, uint32_t size,
                                              int32_t vo_handle,
                                              uint32_t buf_idx);

Inserts a wait-for-flip-completion command into the command buffer.


Coredump / Misc

Miscellaneous driver query and control functions.

sceGnmFlushGarlic

void PS4_SYSV_ABI sceGnmFlushGarlic(void);

Flushes the Garlic (GPU-visible CPU) memory bus.

sceGnmGetCoredumpAddress

int PS4_SYSV_ABI sceGnmGetCoredumpAddress(void);

Retail stub — retrieves the GPU coredump buffer address.

sceGnmGetCoredumpMode

int PS4_SYSV_ABI sceGnmGetCoredumpMode(void);

Retail stub — retrieves the current coredump mode.

sceGnmGetCoredumpProtectionFaultTimestamp

int PS4_SYSV_ABI sceGnmGetCoredumpProtectionFaultTimestamp(void);

Retail stub — retrieves the timestamp of the last protection fault.

sceGnmGetDebugTimestamp

int PS4_SYSV_ABI sceGnmGetDebugTimestamp(void);

Retail stub — retrieves a debug timestamp.

sceGnmGetGpuBlockStatus

int PS4_SYSV_ABI sceGnmGetGpuBlockStatus(void);

Retail stub — retrieves the GPU block status.

sceGnmGetGpuCoreClockFrequency

uint32_t PS4_SYSV_ABI sceGnmGetGpuCoreClockFrequency(void);

Returns the current GPU core clock frequency in Hz.

sceGnmGetGpuInfoStatus

int PS4_SYSV_ABI sceGnmGetGpuInfoStatus(void);

Retail stub — retrieves the GPU info status.

sceGnmGetLastWaitedAddress

int PS4_SYSV_ABI sceGnmGetLastWaitedAddress(void);

Retail stub — retrieves the last memory address the GPU waited on.

sceGnmGetNumTcaUnits

int PS4_SYSV_ABI sceGnmGetNumTcaUnits(void);

Retail stub — returns the number of TCA (Texture Cache Array) units.

sceGnmGetOffChipTessellationBufferSize

int PS4_SYSV_ABI sceGnmGetOffChipTessellationBufferSize(void);

Retail stub — returns the off-chip tessellation buffer size.

sceGnmGetOwnerName

int PS4_SYSV_ABI sceGnmGetOwnerName(void);

Retail stub — retrieves a resource owner's name.

sceGnmGetPhysicalCounterFromVirtualized

int PS4_SYSV_ABI sceGnmGetPhysicalCounterFromVirtualized(void);

Retail stub — maps a virtualised performance counter to its physical index.

sceGnmGetProtectionFaultTimeStamp

uint32_t PS4_SYSV_ABI sceGnmGetProtectionFaultTimeStamp(void);

Returns the timestamp of the last GPU protection fault.

sceGnmGetShaderProgramBaseAddress

int PS4_SYSV_ABI sceGnmGetShaderProgramBaseAddress(void);

Retail stub — retrieves the base address of a shader program.

sceGnmGetShaderStatus

int PS4_SYSV_ABI sceGnmGetShaderStatus(void);

Retail stub — retrieves the status of a shader program.

sceGnmGetTheTessellationFactorRingBufferBaseAddress

uintptr_t
sceGnmGetTheTessellationFactorRingBufferBaseAddress(void) PS4_SYSV_ABI;

Returns the base address of the tessellation factor ring buffer.

sceGnmIsCoredumpValid

int PS4_SYSV_ABI sceGnmIsCoredumpValid(void);

Retail stub — checks whether the current coredump is valid.

sceGnmRaiseUserExceptionEvent

int PS4_SYSV_ABI sceGnmRaiseUserExceptionEvent(void);

Retail stub — raises a user exception event on the GPU.


Driver Internal

Internal driver interface retrieval and capture-control functions.

sceGnmDriverCaptureInProgress

bool PS4_SYSV_ABI sceGnmDriverCaptureInProgress(void);

Returns true if a driver capture is in progress.

sceGnmDriverInternalRetrieveGnmInterface

uint32_t PS4_SYSV_ABI sceGnmDriverInternalRetrieveGnmInterface(void);

Retrieves the internal GNM interface function table.

sceGnmDriverInternalRetrieveGnmInterfaceForGpuDebugger

uint32_t PS4_SYSV_ABI
sceGnmDriverInternalRetrieveGnmInterfaceForGpuDebugger(void);

Retrieves the GNM interface function table for the GPU debugger.

sceGnmDriverInternalRetrieveGnmInterfaceForGpuException

uint32_t PS4_SYSV_ABI
sceGnmDriverInternalRetrieveGnmInterfaceForGpuException(void);

Retrieves the GNM interface function table for GPU exception handling.

sceGnmDriverInternalRetrieveGnmInterfaceForHDRScopes

uint32_t PS4_SYSV_ABI
sceGnmDriverInternalRetrieveGnmInterfaceForHDRScopes(void);

Retrieves the GNM interface function table for HDR scopes.

sceGnmDriverInternalRetrieveGnmInterfaceForReplay

uint32_t PS4_SYSV_ABI sceGnmDriverInternalRetrieveGnmInterfaceForReplay(void);

Retrieves the GNM interface function table for replay.

sceGnmDriverInternalRetrieveGnmInterfaceForResourceRegistration

uint32_t PS4_SYSV_ABI
sceGnmDriverInternalRetrieveGnmInterfaceForResourceRegistration(void);

Retrieves the GNM interface function table for resource registration.

sceGnmDriverInternalRetrieveGnmInterfaceForValidation

uint32_t PS4_SYSV_ABI
sceGnmDriverInternalRetrieveGnmInterfaceForValidation(void);

Retrieves the GNM interface function table for validation.

sceGnmDriverInternalVirtualQuery

int PS4_SYSV_ABI sceGnmDriverInternalVirtualQuery(void);

Retail stub — performs an internal virtual-memory query.

sceGnmDriverTraceInProgress

bool PS4_SYSV_ABI sceGnmDriverTraceInProgress(void);

Returns true if a driver trace is in progress.

sceGnmDriverTriggerCapture

int PS4_SYSV_ABI sceGnmDriverTriggerCapture(void);

Retail stub — triggers a driver capture.

sceGnmRegisterGnmLiveCallbackConfig

void PS4_SYSV_ABI sceGnmRegisterGnmLiveCallbackConfig(void);

Retail stub — registers a GNM live-callback configuration.


Logical CU / GPU PA

Functions for logical-to-physical compute-unit mapping and GPU Performance Analysis (PA) debug callbacks.

sceGnmGpuPaDebugEnter

void PS4_SYSV_ABI sceGnmGpuPaDebugEnter(void);

Retail stub — enters a GPU PA debug session.

sceGnmGpuPaDebugLeave

void PS4_SYSV_ABI sceGnmGpuPaDebugLeave(void);

Retail stub — leaves a GPU PA debug session.

sceGnmIsUserPaEnabled

bool PS4_SYSV_ABI sceGnmIsUserPaEnabled(void);

Returns true if user performance analysis is enabled.

sceGnmLogicalCuIndexToPhysicalCuIndex

int PS4_SYSV_ABI sceGnmLogicalCuIndexToPhysicalCuIndex(void);

Retail stub — converts a logical CU index to a physical CU index.

sceGnmLogicalCuMaskToPhysicalCuMask

int32_t PS4_SYSV_ABI sceGnmLogicalCuMaskToPhysicalCuMask(int64_t,
                                                         int32_t logical_cu_mask);

Converts a logical CU bitmask to a physical CU bitmask.

sceGnmLogicalTcaUnitToPhysical

int PS4_SYSV_ABI sceGnmLogicalTcaUnitToPhysical(void);

Retail stub — converts a logical TCA unit to a physical TCA unit.

sceGnmPaDisableFlipCallbacks

int PS4_SYSV_ABI sceGnmPaDisableFlipCallbacks(void);

Retail stub — disables PA flip callbacks.

sceGnmPaEnableFlipCallbacks

int PS4_SYSV_ABI sceGnmPaEnableFlipCallbacks(void);

Retail stub — enables PA flip callbacks.

sceGnmPaHeartbeat

int PS4_SYSV_ABI sceGnmPaHeartbeat(void);

Retail stub — sends a PA heartbeat signal.


Mip Stats

Functions for per-mip-level statistics reporting.

sceGnmDisableMipStatsReport

int PS4_SYSV_ABI sceGnmDisableMipStatsReport(void);

Retail stub — disables mip-level statistics reporting.

sceGnmRequestMipStatsReportAndReset

int PS4_SYSV_ABI sceGnmRequestMipStatsReportAndReset(void);

Retail stub — requests a mip-stats report and resets counters.

sceGnmSetupMipStatsReport

int PS4_SYSV_ABI sceGnmSetupMipStatsReport(void);

Retail stub — sets up mip-level statistics reporting.


NID-only Stubs

The following functions are exported by the gnmdriver module but have no publicly known names — they are referenced only by their NID (a 64-bit hash of the symbol name). They are all retail stubs with void parameter lists.

NID Symbol Signature
Func_063D065A2D6359C3 int PS4_SYSV_ABI Func_063D065A2D6359C3(void);
Func_0CABACAFB258429D int PS4_SYSV_ABI Func_0CABACAFB258429D(void);
Func_150CF336FC2E99A3 int PS4_SYSV_ABI Func_150CF336FC2E99A3(void);
Func_17CA687F9EE52D49 int PS4_SYSV_ABI Func_17CA687F9EE52D49(void);
Func_1870B89F759C6B45 int PS4_SYSV_ABI Func_1870B89F759C6B45(void);
Func_26F9029EF68A955E int PS4_SYSV_ABI Func_26F9029EF68A955E(void);
Func_301E3DBBAB092DB0 int PS4_SYSV_ABI Func_301E3DBBAB092DB0(void);
Func_30BAFE172AF17FEF int PS4_SYSV_ABI Func_30BAFE172AF17FEF(void);
Func_3E6A3E8203D95317 int PS4_SYSV_ABI Func_3E6A3E8203D95317(void);
Func_40FEEF0C6534C434 int PS4_SYSV_ABI Func_40FEEF0C6534C434(void);
Func_416B9079DE4CBACE int PS4_SYSV_ABI Func_416B9079DE4CBACE(void);
Func_4774D83BB4DDBF9A int PS4_SYSV_ABI Func_4774D83BB4DDBF9A(void);
Func_50678F1CCEEB9A00 int PS4_SYSV_ABI Func_50678F1CCEEB9A00(void);
Func_54A2EC5FA4C62413 int PS4_SYSV_ABI Func_54A2EC5FA4C62413(void);
Func_5A9C52C83138AE6B int PS4_SYSV_ABI Func_5A9C52C83138AE6B(void);
Func_5D22193A31EA1142 int PS4_SYSV_ABI Func_5D22193A31EA1142(void);
Func_725A36DEBB60948D int PS4_SYSV_ABI Func_725A36DEBB60948D(void);
Func_8021A502FA61B9BB int PS4_SYSV_ABI Func_8021A502FA61B9BB(void);
Func_9D002FE0FA40F0E6 int PS4_SYSV_ABI Func_9D002FE0FA40F0E6(void);
Func_9D297F36A7028B71 int PS4_SYSV_ABI Func_9D297F36A7028B71(void);
Func_A2D7EC7A7BCF79B3 int PS4_SYSV_ABI Func_A2D7EC7A7BCF79B3(void);
Func_AA12A3CB8990854A int PS4_SYSV_ABI Func_AA12A3CB8990854A(void);
Func_ADC8DDC005020BC6 int PS4_SYSV_ABI Func_ADC8DDC005020BC6(void);
Func_B0A8688B679CB42D int PS4_SYSV_ABI Func_B0A8688B679CB42D(void);
Func_B489020B5157A5FF int PS4_SYSV_ABI Func_B489020B5157A5FF(void);
Func_BADE7B4C199140DD int PS4_SYSV_ABI Func_BADE7B4C199140DD(void);
Func_C4C328B7CF3B4171 int PS4_SYSV_ABI Func_C4C328B7CF3B4171(void);
Func_D1511B9DCFFB3DD9 int PS4_SYSV_ABI Func_D1511B9DCFFB3DD9(void);
Func_D53446649B02E58E int PS4_SYSV_ABI Func_D53446649B02E58E(void);
Func_D8B6E8E28E1EF0A3 int PS4_SYSV_ABI Func_D8B6E8E28E1EF0A3(void);
Func_D93D733A19DD7454 int PS4_SYSV_ABI Func_D93D733A19DD7454(void);
Func_DE995443BC2A8317 int PS4_SYSV_ABI Func_DE995443BC2A8317(void);
Func_DF6E9528150C23FF int PS4_SYSV_ABI Func_DF6E9528150C23FF(void);
Func_ECB4C6BA41FE3350 int PS4_SYSV_ABI Func_ECB4C6BA41FE3350(void);
Func_1C43886B16EE5530 int PS4_SYSV_ABI Func_1C43886B16EE5530(void);
Func_81037019ECCD0E01 int PS4_SYSV_ABI Func_81037019ECCD0E01(void);
Func_BFB41C057478F0BF int PS4_SYSV_ABI Func_BFB41C057478F0BF(void);
Func_E51D44DB8151238C int PS4_SYSV_ABI Func_E51D44DB8151238C(void);
Func_F916890425496553 int PS4_SYSV_ABI Func_F916890425496553(void);

sceGnmDriver* Packet Builders

Internal PM4 packet-builder wrappers. On Orbis these delegate to the firmware's sceGnm* functions. On the generic (non-Orbis) build path they emit PM4 packets directly. These match the original driver.h API surface and are called by drawcommandbuffer.c.

sceGnmDriverDrawInitDefaultHardwareState350

int32_t sceGnmDriverDrawInitDefaultHardwareState350(
    uint32_t* cmd, uint32_t numdwords
);

Emits the GFX 3.50 default-hardware-state init packet into cmd.

sceGnmDriverDrawIndex

int32_t sceGnmDriverDrawIndex(
    uint32_t* cmd, uint32_t numdwords, uint32_t indexcount,
    const void* indexaddr, SceGnmDrawFlags flags
);

Builds an indexed-draw PM4 packet.

sceGnmDriverDrawIndexAuto

int32_t sceGnmDriverDrawIndexAuto(
    uint32_t* cmd, uint32_t numdwords, uint32_t indexcount,
    SceGnmDrawFlags flags
);

Builds an auto-indexed-draw PM4 packet.

sceGnmDriverDrawIndexIndirect

int32_t sceGnmDriverDrawIndexIndirect(
    uint32_t* cmd, uint32_t numdwords, uint32_t dataoffset, uint32_t stage,
    uint8_t vertexoffusgpr, uint8_t instanceoffusgpr, SceGnmDrawFlags flags
);

Builds an indirect-indexed-draw PM4 packet.

sceGnmDriverDrawIndirect

int32_t sceGnmDriverDrawIndirect(
    uint32_t* cmd, uint32_t numdwords, uint32_t dataoffset, uint32_t stage,
    uint8_t vertexoffusgpr, uint8_t instanceoffusgpr, SceGnmDrawFlags flags
);

Builds an indirect (non-indexed) draw PM4 packet.

sceGnmDriverDrawIndexIndirectMulti

int32_t sceGnmDriverDrawIndexIndirectMulti(
    uint32_t* cmd, uint32_t numdwords, uint32_t dataoffset, uint32_t maxcount,
    uint32_t stage, uint8_t vertexoffusgpr, uint8_t instanceoffusgpr,
    SceGnmDrawFlags flags
);

Builds a multi-indirect-indexed-draw PM4 packet.

sceGnmDriverDrawIndirectMulti

int32_t sceGnmDriverDrawIndirectMulti(
    uint32_t* cmd, uint32_t numdwords, uint32_t dataoffset, uint32_t maxcount,
    uint32_t stage, uint8_t vertexoffusgpr, uint8_t instanceoffusgpr,
    SceGnmDrawFlags flags
);

Builds a multi-indirect (non-indexed) draw PM4 packet.

sceGnmDriverDrawIndexIndirectCountMulti

int32_t sceGnmDriverDrawIndexIndirectCountMulti(
    uint32_t* cmd, uint32_t numdwords, uint32_t dataoffset, uint32_t maxcount,
    uint64_t countaddr, uint32_t stage, uint8_t vertexoffusgpr,
    uint8_t instanceoffusgpr, SceGnmDrawFlags flags
);

Builds a count-multi-indirect-indexed-draw PM4 packet.

sceGnmDriverSetVsShader

int32_t sceGnmDriverSetVsShader(
    uint32_t* cmd, uint32_t numdwords, const void* vsregs,
    uint32_t shadermodifier
);

Builds a vertex-shader bind PM4 packet.

sceGnmDriverSetPsShader

int32_t sceGnmDriverSetPsShader(
    uint32_t* cmd, uint32_t numdwords, const void* psregs
);

Builds a pixel-shader bind PM4 packet.

sceGnmDriverSetPsShader350

int32_t sceGnmDriverSetPsShader350(
    uint32_t* cmd, uint32_t numdwords, const void* psregs
);

Builds a pixel-shader bind PM4 packet (GFX 3.50 layout).

sceGnmDriverSetEmbeddedVsShader

int32_t sceGnmDriverSetEmbeddedVsShader(
    uint32_t* cmd, uint32_t numdwords, int32_t shaderid, uint32_t shadermodifier
);

Binds an embedded (built-in) vertex shader. Uses runtime HLE detection: on real hardware, emits the PM4 register-write sequence locally using the embedded fullscreen VS register blob and pads with PKT3_NOP (avoids the FW 9.00 crash in firmware shader-set helpers); on HLE emulators, forwards to sceGnmSetEmbeddedVsShader. Only GNM_EMBEDDED_VSH_FULLSCREEN is supported; any other ID returns GNM_ERROR_INTERNAL_FAILURE. The shadermodifier encodes the fetch shader configuration (see sceGnmVsRegsSetFetchShaderModifier).

sceGnmDriverSetEmbeddedPsShader

int32_t sceGnmDriverSetEmbeddedPsShader(
    uint32_t* cmd, uint32_t numdwords, int32_t shaderid
);

Binds an embedded (built-in) pixel shader. Uses runtime HLE detection: on real hardware, emits the PM4 register-write sequence locally using the embedded dummy PS register blob (standard or RG32 variant by ID) and pads the reserved 40-dword space with PKT3_NOP (avoids the FW 9.00 crash in firmware shader-set helpers); on HLE emulators, forwards to sceGnmSetEmbeddedPsShader. Supports GNM_EMBEDDED_PSH_DUMMY and GNM_EMBEDDED_PSH_DUMMY_RG32; any other ID returns GNM_ERROR_INTERNAL_FAILURE.

sceGnmDriverInsertWaitFlipDone

int32_t sceGnmDriverInsertWaitFlipDone(
    uint32_t* cmd, uint32_t numdwords, int32_t videohandle,
    uint32_t displaybufidx
);

Builds a wait-for-flip-done PM4 packet.


See Also

  • GPU Address API — surface tiling, decompression, and address computation
  • Helpers API — direct memory, VideoOut, texture/render-target creation, shader metadata
  • API Index — complete function listing across all headers