---
title: Resource fundamentals
framework: metal
role: collectionGroup
role_heading: API Collection
path: metal/resource-fundamentals
---

# Resource fundamentals

Control the common attributes of all Metal memory resources, including buffers and textures, and how to configure their underlying memory.

## Overview

Overview A resource is a memory asset, such as an MTLBuffer or MTLTexture, that a GPU can access (see Buffers and Textures). You can either allocate a resource from an MTLDevice instance or an MTLHeap instance (see Memory heaps). Metal sets a resource’s hazardTrackingMode property to MTLHazardTrackingMode.default if you don’t select another tracking mode. The default value depends on what Metal instance creates the resource. important: The value of an MTLResource instance’s hazardTrackingMode property has no effect on the work you submit to an MTL4CommandQueue (see Resource synchronization) or resources that commands access through an argument buffer. Each resource your app creates typically uses one of these storage modes: Private mode resources give your app optimization opportunities that shared mode resources don’t. Managed mode resources also give your app the same opportunities and allow your to app access them from the CPU.

## Topics

### Resource management

- [Setting resource storage modes](metal/setting-resource-storage-modes.md)
- [Choosing a resource storage mode for Apple GPUs](metal/choosing-a-resource-storage-mode-for-apple-gpus.md)
- [Choosing a resource storage mode for Intel and AMD GPUs](metal/choosing-a-resource-storage-mode-for-intel-and-amd-gpus.md)
- [Copying data to a private resource](metal/copying-data-to-a-private-resource.md)
- [Synchronizing a managed resource in macOS](metal/synchronizing-a-managed-resource-in-macos.md)
- [Transferring data between connected GPUs](metal/transferring-data-between-connected-gpus.md)
- [Reducing the memory footprint of Metal apps](metal/reducing-the-memory-footprint-of-metal-apps.md)

### Residency sets

- [Simplifying GPU resource management with residency sets](metal/simplifying-gpu-resource-management-with-residency-sets.md)
- [MTLResidencySet](metal/mtlresidencyset.md)
- [MTLResidencySetDescriptor](metal/mtlresidencysetdescriptor.md)

### View pools

- [MTLResourceViewPool](metal/mtlresourceviewpool.md)
- [MTLResourceViewPoolDescriptor](metal/mtlresourceviewpooldescriptor.md)
- [MTLTextureViewPool](metal/mtltextureviewpool.md)
- [MTLTextureViewDescriptor](metal/mtltextureviewdescriptor.md)

### Tensors

- [MTLTensor](metal/mtltensor.md)
- [MTLTensorDescriptor](metal/mtltensordescriptor.md)
- [MTLTensorExtents](metal/mtltensorextents.md)
- [MTLTensorReferenceType](metal/mtltensorreferencetype.md)
- [MTLTensorUsage](metal/mtltensorusage.md)
- [MTLTensorDomain](metal/mtltensordomain.md)
- [MTLTensorBinding](metal/mtltensorbinding.md)
- [MTLTensorError](metal/mtltensorerror-swift.struct.md)
- [MTLTensorError.Code](metal/mtltensorerror-swift.struct/code.md)
- [MTLTensorDataType](metal/mtltensordatatype.md)
- [MTLTensorDomain](metal/mtltensordomain.md)
- [MTL_TENSOR_MAX_RANK](metal/mtl_tensor_max_rank.md)

### Sparse resources

- [MTLBufferSparseTier](metal/mtlbuffersparsetier.md)
- [MTL4CopySparseBufferMappingOperation](metal/mtl4copysparsebuffermappingoperation.md)
- [MTL4UpdateSparseBufferMappingOperation](metal/mtl4updatesparsebuffermappingoperation.md)
- [MTLTextureSparseTier](metal/mtltexturesparsetier.md)
- [MTL4CopySparseTextureMappingOperation](metal/mtl4copysparsetexturemappingoperation.md)
- [MTL4UpdateSparseTextureMappingOperation](metal/mtl4updatesparsetexturemappingoperation.md)

### Common resource functionality

- [MTLGPUAddress](metal/mtlgpuaddress.md)
- [MTLAllocation](metal/mtlallocation.md)
- [MTLResource](metal/mtlresource.md)
- [MTLResourceOptions](metal/mtlresourceoptions.md)
- [MTLResourceUsage](metal/mtlresourceusage.md)
- [MTLResourceID](metal/mtlresourceid.md)

## See Also

### Resources

- [Buffers](metal/buffers.md)
- [Textures](metal/textures.md)
- [Memory heaps](metal/memory-heaps.md)
- [Resource loading](metal/resource-loading.md)
- [Resource synchronization](metal/resource-synchronization.md)
