[詳解]
32 #ifndef _AK_TOOLS_COMMON_AKPLATFORMFUNCS_H
33 #define _AK_TOOLS_COMMON_AKPLATFORMFUNCS_H
41 #if defined(AK_NULL_PLATFORM)
47 #elif defined (AK_XBOX)
50 #elif defined (AK_APPLE)
52 #include <AK/Tools/POSIX/AkPlatformFuncs.h>
54 #elif defined( AK_ANDROID ) || defined ( AK_LINUX_AOSP )
57 #elif defined ( AK_HARMONY )
60 #elif defined (AK_PS4)
63 #elif defined (AK_PS5)
66 #elif defined (AK_EMSCRIPTEN)
69 #elif defined (AK_LINUX)
71 #include <AK/Tools/POSIX/AkPlatformFuncs.h>
73 #elif defined (AK_QNX)
74 #include <AK/Tools/QNX/AkPlatformFuncs.h>
75 #include <AK/Tools/POSIX/AkPlatformFuncs.h>
81 #error AkPlatformFuncs.h: Undefined platform
84 #ifndef AkPrefetchZero
85 #define AkPrefetchZero(___Dest, ___Size)
88 #ifndef AkPrefetchZeroAligned
89 #define AkPrefetchZeroAligned(___Dest, ___Size)
92 #ifndef AkZeroMemAligned
93 #define AkZeroMemAligned(___Dest, ___Size) AKPLATFORM::AkMemSet(___Dest, 0, ___Size);
95 #ifndef AkZeroMemLarge
96 #define AkZeroMemLarge(___Dest, ___Size) AKPLATFORM::AkMemSet(___Dest, 0, ___Size);
98 #ifndef AkZeroMemSmall
99 #define AkZeroMemSmall(___Dest, ___Size) AKPLATFORM::AkMemSet(___Dest, 0, ___Size);
103 #if defined (__clang__)
104 #if __has_builtin( __builtin_alloca_with_align )
105 #define AkAllocaSIMD( _size_ ) __builtin_alloca_with_align( _size_, 128 )
108 #define AkAllocaSIMD( _size_ ) (void*)( ( ( uintptr_t )AkAlloca( _size_ + 16 ) + 0xF ) & ~0xF )
111 #define AkAllocaSIMD( _size_ ) AkAlloca( _size_ )
115 #ifndef AK_THREAD_INIT_CODE
116 #define AK_THREAD_INIT_CODE(_threadProperties)
120 #ifndef AK_FORCE_CRASH
121 #define AK_FORCE_CRASH \
126 #ifndef AK_PLATFORM_MEMCPY
132 memcpy(pDest, pSrc, uSize);
137 memmove(pDest, pSrc, uSize);
142 memset(pDest, iVal, uSize);
145 #endif // AK_PLATFORM_MEMCPY
147 #if !defined(AK_NULL_PLATFORM)
158 #if !defined(AK_LIMITEDSPINFORZERO)
177 if (currentTime > endSpinTime)
209 if (currentTime > endSpinTime)
215 #endif // !defined(AK_LIMITEDSPINFORZERO)
245 #ifndef AK_PERF_RECORDING_RESET
246 #define AK_PERF_RECORDING_RESET()
248 #ifndef AK_PERF_RECORDING_START
249 #define AK_PERF_RECORDING_START( __StorageName__, __uExecutionCountStart__, __uExecutionCountStop__ )
251 #ifndef AK_PERF_RECORDING_STOP
252 #define AK_PERF_RECORDING_STOP( __StorageName__, __uExecutionCountStart__, __uExecutionCountStop__ )
255 #endif // _AK_TOOLS_COMMON_AKPLATFORMFUNCS_H
AkForceInline void AkMemMove(void *pDest, const void *pSrc, AkUInt32 uSize)
int nPriority
Thread priority
Platform-dependent helpers
int32_t AkInt32
Signed 32-bit integer
void PerformanceCounter(AkInt64 *out_piLastTime)
Platform Independent Helper
AkForceInline void AkMemCpy(void *pDest, const void *pSrc, AkUInt32 uSize)
Platform Independent Helper for memcpy/memmove/memset
AkForceInline void AkGetDefaultThreadProperties(AkThreadProperties &out_threadProperties)
Platform Independent Helper
void AkLimitedSpinForZero(AkAtomic32 *in_pVal)
bool AkLimitedSpinToAcquire(AkAtomic32 *in_pVal, AkInt32 in_proposed, AkInt32 in_expected)
void AkGetDefaultHighPriorityThreadProperties(AkThreadProperties &out_threadProperties)
int64_t AkInt64
Signed 64-bit integer
void AkSpinToAcquire(AkAtomic32 *in_pVal, AkInt32 in_proposed, AkInt32 in_expected)
void AkSpinWaitForZero(AkAtomic32 *in_pVal)
uint32_t AkUInt32
Unsigned 32-bit integer
AkForceInline void AkMemSet(void *pDest, AkInt32 iVal, AkUInt32 uSize)
あなたのプロジェクトについて教えてください。ご不明な点はありませんか。
プロジェクトを登録していただくことで、ご利用開始のサポートをいたします。
Wwiseからはじめよう