Instance Property

kernelStartTime

The host time, in seconds, when the CPU began scheduling this command buffer for execution.

Required.

Declaration

var kernelStartTime: CFTimeInterval { get }

Discussion

This value can be used with the kernelEndTime property to obtain optional timestamp reflection data. Both properties are typically queried in the addScheduledHandler(_:) callback, or after a call to the waitUntilScheduled() method.

This value is 0.0 if the CPU has not yet scheduled the command buffer for execution. The default value is 0.0.

See Also

Obtaining Status and Timestamps

var status: MTLCommandBufferStatus

The current stage in the lifetime of the command buffer.

Required.

enum MTLCommandBufferStatus

The stages in the lifetime of the command buffer.

var error: Error?

The error that occurred when the command buffer was executed.

Required.

struct MTLCommandBufferError

Error codes that indicate why the execution of the command buffer has failed.

let MTLCommandBufferErrorDomain: String

The error domain used by MTLCommandBuffer when returning command buffer execution errors.

enum MTLCommandBufferError.Code

Error codes that indicate why the execution of the command buffer has failed. The error property contains the error code.

var kernelEndTime: CFTimeInterval

The host time, in seconds, when the CPU finished scheduling this command buffer for execution.

Required.

var gpuStartTime: CFTimeInterval

The host time, in seconds, when the GPU began executing this command buffer.

Required.

var gpuEndTime: CFTimeInterval

The host time, in seconds, when the GPU finished executing this command buffer.

Required.