Tempest
Tempest copied to clipboard
Device-lost crash-logging
Vulkan VK_EXT_device_fault
Metal: https://developer.apple.com/documentation/metal/mtlcommandbuffer/1443040-error?language=objc
_MTL_ENUM(NS::UInteger, CommandBufferError) {
CommandBufferErrorNone = 0,
CommandBufferErrorInternal = 1,
CommandBufferErrorTimeout = 2,
CommandBufferErrorPageFault = 3,
CommandBufferErrorBlacklisted = 4,
CommandBufferErrorAccessRevoked = 4,
CommandBufferErrorNotPermitted = 7,
CommandBufferErrorOutOfMemory = 8,
CommandBufferErrorInvalidResource = 9,
CommandBufferErrorMemoryless = 10,
CommandBufferErrorDeviceRemoved = 11,
CommandBufferErrorStackOverflow = 12,
};
// Settings that determine which information the command buffer records about execution errors, and how it does it.
MTL::CommandBufferErrorOption MTL::CommandBuffer::errorOptions();
// A description of an error when the GPU encounters an issue as it runs the command buffer
NS::Error* MTL::CommandBuffer::error() const;
DirectX12: https://microsoft.github.io/DirectX-Specs/d3d/DeviceRemovedExtendedData.html
Can't quite test DX12 - unable to get it to crash, even on purpose. Leaving minimal implementation of DRED for now.
Page-fault logging on Mac:
---crashlog(DeviceLostException(Error Domain=MTLCommandBufferErrorDomain Code=3 "Caused GPU Address Fault Error (0000000b:kIOGPUCommandBuff)---
GPU: Apple M1
---gpulog begin---
<errorState: MTLCommandEncoderErrorStateCompleted, label: Visibility, debugSignposts: (null)>
<errorState: MTLCommandEncoderErrorStateCompleted, label: (null), debugSignposts: (null)>
<errorState: MTLCommandEncoderErrorStateCompleted, label: (null), debugSignposts: (null)>
<errorState: MTLCommandEncoderErrorStateCompleted, label: (null), debugSignposts: (null)>
<errorState: MTLCommandEncoderErrorStateCompleted, label: HiZ-occluders, debugSignposts: (null)>
<errorState: MTLCommandEncoderErrorStateCompleted, label: HiZ-mip, debugSignposts: (null)>
<errorState: MTLCommandEncoderErrorStateCompleted, label: Visibility, debugSignposts: (null)>
<errorState: MTLCommandEncoderErrorStateFaulted, label: (null), debugSignposts: (null)>
<errorState: MTLCommandEncoderErrorStateFaulted, label: ShadowMap #0, debugSignposts: (null)>
<errorState: MTLCommandEncoderErrorStateFaulted, label: ShadowMap #1, debugSignposts: (null)>
<errorState: MTLCommandEncoderErrorStateCompleted, label: Exposure, debugSignposts: (null)>
<errorState: MTLCommandEncoderErrorStateCompleted, label: DirectSunLight, debugSignposts: (null)>
<errorState: MTLCommandEncoderErrorStateCompleted, label: Stash scene, debugSignposts: (null)>
<errorState: MTLCommandEncoderErrorStateAffected, label: GWater, debugSignposts: (null)>
<errorState: MTLCommandEncoderErrorStateAffected, label: Sun&Moon, debugSignposts: (null)>
<errorState: MTLCommandEncoderErrorStateCompleted, label: Reflections, debugSignposts: (null)>
<errorState: MTLCommandEncoderErrorStateCompleted, label: Tonemapping, debugSignposts: (null)>
<errorState: MTLCommandEncoderErrorStateCompleted, label: UI, debugSignposts: (null)>
---gpulog end ---