> ## Documentation Index
> Fetch the complete documentation index at: https://devdocs.xbox.com/llms.txt
> Use this file to discover all available pages before exploring further.

# IDStorageFactoryX::SetCpuAffinity

> IDStorageFactoryX::SetCpuAffinity

# IDStorageFactoryX::SetCpuAffinity

DirectStorage에 대한 CPU 선호도 마스크를 설정합니다.

## 구문

```cpp theme={null}
HRESULT SetCpuAffinity(  
         UINT64 affinity  
)  
```

### 매개 변수

*affinity*\
형식: UINT64

CPU 선호도 마스크입니다.

### 반환 값

형식: HRESULT

표준 HRESULT 오류 코드입니다.

## 설명

DirectStorage는 일반적으로 호출한 스레드에서 작업을 수행합니다. 그러나 일부 작업은 호출한 스레드에서 수행할 수 없습니다. 이러한 작업을 지정된 CPU 코어 집합으로 제한하려면 CPU 선호도 마스크를 설정합니다.

자세한 내용은 [DirectStorage 개요](/build/console-features/storage/directstorage/directstorage-overview)의 "IDStorageFileX" 섹션 내 "SetCPUAffinity"를 참조하세요.

## 요구 사항

**헤더:** dstorage\_xs.h

**라이브러리:** dstorage\_xs.lib

**지원되는 플랫폼:** XBOX Series 콘솔

## 함께 보기

[IDStorageFactoryX](/reference/system/dstorage/interfaces/IDStorageFactoryX/idstoragefactoryx)\
[DStorage](/reference/system/dstorage/dstorage_members)


## Related topics

- [IDStorageFactoryX::SetDebugFlags](/ko/reference/system/dstorage/interfaces/IDStorageFactoryX/methods/idstoragefactoryx_setdebugflags.md)
- [IDStorageFactoryX::SetStagingBufferSize](/ko/reference/system/dstorage/interfaces/IDStorageFactoryX/methods/idstoragefactoryx_setstagingbuffersize.md)
- [IDStorageFactoryX](/ko/reference/system/dstorage/interfaces/IDStorageFactoryX/idstoragefactoryx.md)
- [DirectStorage 개요](/ko/build/console-features/storage/directstorage/directstorage-overview.md)
- [IDStorageFactoryX::CreateQueue](/ko/reference/system/dstorage/interfaces/IDStorageFactoryX/methods/idstoragefactoryx_createqueue.md)
