os namespace
Namespaces
- namespace detail
Classes
- struct ConditionVariableType
- union CpuRegister
- struct EventType
- union FpuRegister
- Armv8 NEON register.
- struct LightEventType
- struct MessageQueueType
- class Mutex
- struct MutexType
- struct SemaphoreType
- struct SystemEvent
- struct SystemEventType
- struct ThreadType
- struct TlsSlot
- struct UserExceptionInfo
Enums
Typedefs
- using ThreadFunction = void(*)(void*)
- using Tick = u64
- using Event = EventType
Functions
- void InitializeMutex(MutexType*, bool, s32)
- void FinalizeMutex(MutexType*)
- void LockMutex(MutexType*)
- auto TryLockMutex(MutexType*) -> bool
- void UnlockMutex(MutexType*)
- auto IsMutexLockedByCurrentThread(const MutexType*) -> bool
- void SetHostArgc(s32)
- auto GetHostArgc() -> s32
- void SetHostArgv(char**)
- auto GetHostArgv() -> char**
- void InitializeVirtualAddressMemory()
- auto AllocateAddressRegion(u64*, u64) -> Result
- auto AllocateMemory(u64*, u64) -> Result
- auto AllocateMemoryPages(u64, u64) -> Result
- void AllocateMemoryBlock(u64*, u64)
- void FreeMemoryBlock(u64, u64)
- void SetMemoryHeapSize(u64)
-
void InitializeMessageQueue(nn::
os:: MessageQueueType*, u64* buf, u64 queueCount) -
void FinalizeMessageQueue(nn::
os:: MessageQueueType*) - auto TrySendMessageQueue(MessageQueueType*, u64) -> bool
- void SendMessageQueue(MessageQueueType*, u64)
-
auto TimedSendMessageQueue(MessageQueueType*,
u64,
nn::
TimeSpan) -> bool - auto TryReceiveMessageQueue(u64* out, MessageQueueType*) -> bool
- void ReceiveMessageQueue(u64* out, MessageQueueType*)
-
auto TimedReceiveMessageQueue(u64* out,
MessageQueueType*,
nn::
TimeSpan) -> bool - auto TryPeekMessageQueue(u64*, MessageQueueType const*) -> bool
- void PeekMessageQueue(u64*, MessageQueueType const*)
- auto TimedPeekMessageQueue(u64*, MessageQueueType const*) -> bool
-
auto TryJamMessageQueue(nn::
os:: MessageQueueType*, u64) -> bool -
void JamMessageQueue(nn::
os:: MessageQueueType*, u64) -
auto TimedJamMessageQueue(nn::
os:: MessageQueueType*, u64, nn:: TimeSpan) -> bool - void InitializeConditionVariable(ConditionVariableType*)
- void FinalizeConditionVariable(ConditionVariableType*)
- void SignalConditionVariable(ConditionVariableType*)
- void BroadcastConditionVariable(ConditionVariableType*)
- void WaitConditionVariable(ConditionVariableType*)
-
auto TimedWaitConditionVariable(ConditionVariableType*,
nn::
os:: MutexType*, nn:: TimeSpan) -> u8 -
auto CreateThread(nn::
os:: ThreadType*, void(*)(void*), void* arg, void* srcStack, u64 stackSize, s32 priority, s32 coreNum) -> Result -
auto CreateThread(nn::
os:: ThreadType*, void(*)(void*), void* arg, void* srcStack, u64 stackSize, s32 priority) -> Result -
void DestroyThread(nn::
os:: ThreadType*) -
void StartThread(nn::
os:: ThreadType*) -
void SetThreadName(nn::
os:: ThreadType*, char const* threadName) -
void SetThreadNamePointer(nn::
os:: ThreadType*, char const*) -
auto GetThreadNamePointer(nn::
os:: ThreadType const*) -> char* -
auto GetCurrentThread() -> nn::
os:: ThreadType* -
void GetCurrentStackInfo(uintptr_t* stack_addr,
size_
t* stack_size) -
auto ChangeThreadPriority(nn::
os:: ThreadType* thread, s32 priority) -> s32 -
auto GetThreadPriority(nn::
os:: ThreadType const* thread) -> s32 -
auto GetThreadId(const nn::
os:: ThreadType* thread) -> u64 - void YieldThread()
-
void SuspendThread(nn::
os:: ThreadType*) -
void ResumeThread(nn::
os:: ThreadType*) -
void SleepThread(nn::
TimeSpan) -
void WaitThread(nn::
os:: ThreadType*) -
void SetThreadCoreMask(nn::
os:: ThreadType*, int, u64 mask) - void InitializeEvent(EventType*, bool initiallySignaled, EventClearMode eventClearMode)
- void FinalizeEvent(EventType*)
- void SignalEvent(EventType*)
- void WaitEvent(EventType*)
- auto TryWaitEvent(EventType*) -> bool
-
auto TimedWaitEvent(EventType*,
nn::
TimeSpan) -> bool - void ClearEvent(EventType*)
- void InitializeLightEvent(LightEventType*, bool initiallySignaled, EventClearMode eventClearMode)
- void FinalizeLightEvent(LightEventType*)
- void SignalLightEvent(LightEventType*)
- void WaitLightEvent(LightEventType*)
-
auto TimedWaitLightEvent(LightEventType*,
nn::
TimeSpan) -> bool - void ClearLightEvent(LightEventType*)
- auto ConvertToTimeSpan(Tick ticks) -> TimeSpan
- void InitializeSemaphore(SemaphoreType* semaphore, s32 initial_count, s32 max_count)
- void FinalizeSemaphore(SemaphoreType* semaphore)
- void AcquireSemaphore(SemaphoreType* semaphore)
- auto TryAcquireSemaphore(SemaphoreType* semaphore) -> bool
- void ReleaseSemaphore(SemaphoreType* semaphore)
- void SetUserExceptionHandler(void(*)(UserExceptionInfo*), void*, ulong, UserExceptionInfo*)
- void GenerateRandomBytes(void*, u64)
-
auto GetSystemTick() -> nn::
os:: Tick -
auto GetSystemTickFrequency() -> nn::
os:: Tick - auto GetThreadAvailableCoreMask() -> u64
- auto AllocateTlsSlot(TlsSlot* slot_out, void(*)(u64)) -> Result
- void FreeTlsSlot(TlsSlot slot)
- auto GetTlsValue(TlsSlot slot) -> u64
- void SetTlsValue(TlsSlot slot, u64 value)
- auto GetCurrentCoreNumber() -> u32
Enum documentation
enum nn:: os:: ConditionVariableStatus
#include <nn/os/os_ConditionVariableCommon.h>
enum nn:: os:: EventClearMode
#include <nn/os.h>
Typedef documentation
typedef void(*nn:: os:: ThreadFunction)(void*)
#include <nn/os/os_ThreadCommon.h>
Function documentation
void nn:: os:: InitializeMutex(MutexType*,
bool,
s32)
#include <nn/os/os_Mutex.h>
void nn:: os:: FinalizeMutex(MutexType*)
#include <nn/os/os_Mutex.h>
void nn:: os:: LockMutex(MutexType*)
#include <nn/os/os_Mutex.h>
bool nn:: os:: TryLockMutex(MutexType*)
#include <nn/os/os_Mutex.h>
void nn:: os:: UnlockMutex(MutexType*)
#include <nn/os/os_Mutex.h>
bool nn:: os:: IsMutexLockedByCurrentThread(const MutexType*)
#include <nn/os/os_Mutex.h>
void nn:: os:: SetHostArgc(s32)
#include <nn/os.h>
s32 nn:: os:: GetHostArgc()
#include <nn/os.h>
void nn:: os:: SetHostArgv(char**)
#include <nn/os.h>
char** nn:: os:: GetHostArgv()
#include <nn/os.h>
void nn:: os:: InitializeVirtualAddressMemory()
#include <nn/os.h>
Result nn:: os:: AllocateAddressRegion(u64*,
u64)
#include <nn/os.h>
Result nn:: os:: AllocateMemory(u64*,
u64)
#include <nn/os.h>
Result nn:: os:: AllocateMemoryPages(u64,
u64)
#include <nn/os.h>
void nn:: os:: AllocateMemoryBlock(u64*,
u64)
#include <nn/os.h>
void nn:: os:: FreeMemoryBlock(u64,
u64)
#include <nn/os.h>
void nn:: os:: SetMemoryHeapSize(u64)
#include <nn/os.h>
void nn:: os:: InitializeMessageQueue(nn:: os:: MessageQueueType*,
u64* buf,
u64 queueCount)
#include <nn/os.h>
void nn:: os:: FinalizeMessageQueue(nn:: os:: MessageQueueType*)
#include <nn/os.h>
bool nn:: os:: TrySendMessageQueue(MessageQueueType*,
u64)
#include <nn/os.h>
void nn:: os:: SendMessageQueue(MessageQueueType*,
u64)
#include <nn/os.h>
bool nn:: os:: TimedSendMessageQueue(MessageQueueType*,
u64,
nn:: TimeSpan)
#include <nn/os.h>
bool nn:: os:: TryReceiveMessageQueue(u64* out,
MessageQueueType*)
#include <nn/os.h>
void nn:: os:: ReceiveMessageQueue(u64* out,
MessageQueueType*)
#include <nn/os.h>
bool nn:: os:: TimedReceiveMessageQueue(u64* out,
MessageQueueType*,
nn:: TimeSpan)
#include <nn/os.h>
bool nn:: os:: TryPeekMessageQueue(u64*,
MessageQueueType const*)
#include <nn/os.h>
void nn:: os:: PeekMessageQueue(u64*,
MessageQueueType const*)
#include <nn/os.h>
bool nn:: os:: TimedPeekMessageQueue(u64*,
MessageQueueType const*)
#include <nn/os.h>
bool nn:: os:: TryJamMessageQueue(nn:: os:: MessageQueueType*,
u64)
#include <nn/os.h>
void nn:: os:: JamMessageQueue(nn:: os:: MessageQueueType*,
u64)
#include <nn/os.h>
bool nn:: os:: TimedJamMessageQueue(nn:: os:: MessageQueueType*,
u64,
nn:: TimeSpan)
#include <nn/os.h>
void nn:: os:: InitializeConditionVariable(ConditionVariableType*)
#include <nn/os.h>
void nn:: os:: FinalizeConditionVariable(ConditionVariableType*)
#include <nn/os.h>
void nn:: os:: SignalConditionVariable(ConditionVariableType*)
#include <nn/os.h>
void nn:: os:: BroadcastConditionVariable(ConditionVariableType*)
#include <nn/os.h>
void nn:: os:: WaitConditionVariable(ConditionVariableType*)
#include <nn/os.h>
u8 nn:: os:: TimedWaitConditionVariable(ConditionVariableType*,
nn:: os:: MutexType*,
nn:: TimeSpan)
#include <nn/os.h>
Result nn:: os:: CreateThread(nn:: os:: ThreadType*,
void(*)(void*),
void* arg,
void* srcStack,
u64 stackSize,
s32 priority,
s32 coreNum)
#include <nn/os.h>
Result nn:: os:: CreateThread(nn:: os:: ThreadType*,
void(*)(void*),
void* arg,
void* srcStack,
u64 stackSize,
s32 priority)
#include <nn/os.h>
void nn:: os:: DestroyThread(nn:: os:: ThreadType*)
#include <nn/os.h>
void nn:: os:: StartThread(nn:: os:: ThreadType*)
#include <nn/os.h>
void nn:: os:: SetThreadName(nn:: os:: ThreadType*,
char const* threadName)
#include <nn/os.h>
void nn:: os:: SetThreadNamePointer(nn:: os:: ThreadType*,
char const*)
#include <nn/os.h>
char* nn:: os:: GetThreadNamePointer(nn:: os:: ThreadType const*)
#include <nn/os.h>
nn:: os:: ThreadType* nn:: os:: GetCurrentThread()
#include <nn/os.h>
void nn:: os:: GetCurrentStackInfo(uintptr_t* stack_addr,
size_ t* stack_size)
#include <nn/os.h>
s32 nn:: os:: ChangeThreadPriority(nn:: os:: ThreadType* thread,
s32 priority)
#include <nn/os.h>
s32 nn:: os:: GetThreadPriority(nn:: os:: ThreadType const* thread)
#include <nn/os.h>
u64 nn:: os:: GetThreadId(const nn:: os:: ThreadType* thread)
#include <nn/os.h>
void nn:: os:: YieldThread()
#include <nn/os.h>
void nn:: os:: SuspendThread(nn:: os:: ThreadType*)
#include <nn/os.h>
void nn:: os:: ResumeThread(nn:: os:: ThreadType*)
#include <nn/os.h>
void nn:: os:: SleepThread(nn:: TimeSpan)
#include <nn/os.h>
void nn:: os:: WaitThread(nn:: os:: ThreadType*)
#include <nn/os.h>
void nn:: os:: SetThreadCoreMask(nn:: os:: ThreadType*,
int,
u64 mask)
#include <nn/os.h>
void nn:: os:: InitializeEvent(EventType*,
bool initiallySignaled,
EventClearMode eventClearMode)
#include <nn/os.h>
void nn:: os:: FinalizeEvent(EventType*)
#include <nn/os.h>
void nn:: os:: SignalEvent(EventType*)
#include <nn/os.h>
bool nn:: os:: TryWaitEvent(EventType*)
#include <nn/os.h>
bool nn:: os:: TimedWaitEvent(EventType*,
nn:: TimeSpan)
#include <nn/os.h>
void nn:: os:: ClearEvent(EventType*)
#include <nn/os.h>
void nn:: os:: InitializeLightEvent(LightEventType*,
bool initiallySignaled,
EventClearMode eventClearMode)
#include <nn/os.h>
void nn:: os:: FinalizeLightEvent(LightEventType*)
#include <nn/os.h>
void nn:: os:: SignalLightEvent(LightEventType*)
#include <nn/os.h>
void nn:: os:: WaitLightEvent(LightEventType*)
#include <nn/os.h>
bool nn:: os:: TimedWaitLightEvent(LightEventType*,
nn:: TimeSpan)
#include <nn/os.h>
void nn:: os:: ClearLightEvent(LightEventType*)
#include <nn/os.h>
TimeSpan nn:: os:: ConvertToTimeSpan(Tick ticks)
#include <nn/os.h>
void nn:: os:: InitializeSemaphore(SemaphoreType* semaphore,
s32 initial_count,
s32 max_count)
#include <nn/os.h>
void nn:: os:: FinalizeSemaphore(SemaphoreType* semaphore)
#include <nn/os.h>
void nn:: os:: AcquireSemaphore(SemaphoreType* semaphore)
#include <nn/os.h>
bool nn:: os:: TryAcquireSemaphore(SemaphoreType* semaphore)
#include <nn/os.h>
void nn:: os:: ReleaseSemaphore(SemaphoreType* semaphore)
#include <nn/os.h>
void nn:: os:: SetUserExceptionHandler(void(*)(UserExceptionInfo*),
void*,
ulong,
UserExceptionInfo*)
#include <nn/os.h>
void nn:: os:: GenerateRandomBytes(void*,
u64)
#include <nn/os.h>
nn:: os:: Tick nn:: os:: GetSystemTick()
#include <nn/os.h>
nn:: os:: Tick nn:: os:: GetSystemTickFrequency()
#include <nn/os.h>
u64 nn:: os:: GetThreadAvailableCoreMask()
#include <nn/os.h>
Result nn:: os:: AllocateTlsSlot(TlsSlot* slot_out,
void(*)(u64))
#include <nn/os.h>
void nn:: os:: FreeTlsSlot(TlsSlot slot)
#include <nn/os.h>
u64 nn:: os:: GetTlsValue(TlsSlot slot)
#include <nn/os.h>
void nn:: os:: SetTlsValue(TlsSlot slot,
u64 value)
#include <nn/os.h>
u32 nn:: os:: GetCurrentCoreNumber()
#include <nn/os.h>