<!--
{
  "availability" : [
    "iOS: 26.0.0 -",
    "iPadOS: 26.0.0 -",
    "macCatalyst: 26.0.0 -",
    "macOS: 26.0.0 -",
    "tvOS: 26.0.0 -",
    "visionOS: 26.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "Metal",
  "identifier" : "/documentation/Metal/MTLFunctionOptions/pipelineIndependent",
  "metadataVersion" : "0.1.0",
  "role" : "Type Property",
  "symbol" : {
    "kind" : "Type Property",
    "modules" : [
      "Metal"
    ],
    "preciseIdentifier" : "c:@E@MTLFunctionOptions@MTLFunctionOptionPipelineIndependent"
  },
  "title" : "pipelineIndependent"
}
-->

# pipelineIndependent

An option that generates the same function handle across all pipeline states that link a function, which lets you share function tables across pipeline states.

```
static var pipelineIndependent: MTLFunctionOptions { get }
```

## Discussion

By default, when you link an [`MTLFunction`](/documentation/Metal/MTLFunction) into a pipeline state, Metal generates a function handle that points to that function’s location in the pipeline’s executable code.
Because different pipeline states place functions at different memory addresses, Metal generates different function handles for the same function in each pipeline state.
You insert function handles into an [`MTLIntersectionFunctionTable`](/documentation/Metal/MTLIntersectionFunctionTable) or [`MTLVisibleFunctionTable`](/documentation/Metal/MTLVisibleFunctionTable) instance, which means you need separate function tables for each pipeline state by default.

When you compile a function with this option, Metal generates the same function handle for the function across all pipeline states that link it.
This consistency lets you create a single function table and use it with multiple pipeline states, which reduces memory overhead and simplifies function table management.

> Note: This option only works with functions that you compile with the ``doc://com.apple.metal/documentation/Metal/MTLFunctionOptions/compileToBinary`` option.

---

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)