---
title: commit()
framework: metal
role: symbol
role_heading: Instance Method
path: metal/mtlresidencyset/commit()
---

# commit()

Applies any pending additions to and removals from the residency set.

## Declaration

```swift
func commit()
```

## Mentioned in

Simplifying GPU resource management with residency sets

## Discussion

Discussion Call the method when have no other changes to stage, such as with addAllocation(_:), removeAllocation(_:), and their sibling methods.
