<!--
{
  "availability" : [
    "iOS: 14.0.0 -",
    "iPadOS: 14.0.0 -",
    "macCatalyst: 14.0.0 -",
    "macOS: 11.0.0 -",
    "tvOS: 14.0.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "Metal",
  "identifier" : "/documentation/Metal/MTLCommandBufferErrorOption",
  "metadataVersion" : "0.1.0",
  "role" : "Structure",
  "symbol" : {
    "kind" : "Structure",
    "modules" : [
      "Metal"
    ],
    "preciseIdentifier" : "c:@E@MTLCommandBufferErrorOption"
  },
  "title" : "MTLCommandBufferErrorOption"
}
-->

# MTLCommandBufferErrorOption

Options for reporting errors from a command buffer.

```
struct MTLCommandBufferErrorOption
```

## Topics

### Buffer error options

[`MTLCommandBufferErrorOptionNone`](/documentation/Metal/MTLCommandBufferErrorOption/MTLCommandBufferErrorOptionNone)

An option that clears a command buffer’s error options.

[`encoderExecutionStatus`](/documentation/Metal/MTLCommandBufferErrorOption/encoderExecutionStatus)

An option that instructs a command buffer to save additional details about a GPU runtime error.

### Protocol support

[`init(rawValue:)`](/documentation/Metal/MTLCommandBufferErrorOption/init(rawValue:))

Creates a set of error options from a raw integer value.



---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)