mirror of
https://gitea.wildfiregames.com/0ad/0ad
synced 2026-06-19 06:43:58 -07:00
lib/sysdep: clean up by moving OS and cpu-arch folders into "os" and "arch" folders This was SVN commit r6162.
25 lines
958 B
C
25 lines
958 B
C
/**
|
|
* =========================================================================
|
|
* File : wcpu.h
|
|
* Project : 0 A.D.
|
|
* Description : Windows backend of os_cpu
|
|
* =========================================================================
|
|
*/
|
|
|
|
// license: GPL; see lib/license.txt
|
|
|
|
#ifndef INCLUDED_WCPU
|
|
#define INCLUDED_WCPU
|
|
|
|
#include "win.h"
|
|
|
|
// "affinity" and "processorNumber" are what Windows sees.
|
|
// "processorMask" and "processor" are the idealized representation we expose
|
|
// to users. the latter insulates them from process affinity restrictions by
|
|
// defining IDs as indices of the nonzero bits within the process affinity.
|
|
// these routines are provided for the benefit of wnuma.
|
|
|
|
extern DWORD_PTR wcpu_AffinityFromProcessorMask(DWORD_PTR processAffinity, uintptr_t processorMask);
|
|
extern uintptr_t wcpu_ProcessorMaskFromAffinity(DWORD_PTR processAffinity, DWORD_PTR affinity);
|
|
|
|
#endif // #ifndef INCLUDED_WCPU
|