NSMBW-Decomp
A decompilation of New Super Mario Bros. Wii
Loading...
Searching...
No Matches
ut_LockedCache.h
1#ifndef NW4R_UT_LOCKED_CACHE_H
2#define NW4R_UT_LOCKED_CACHE_H
3#include <nw4r/types_nw4r.h>
4
5#include <revolution/OS.h>
6
7namespace nw4r {
8namespace ut {
9namespace LC {
10
11void Enable();
12void Disable();
13
14bool Lock();
15void Unlock();
16
17void LoadBlocks(void* pDst, void* pSrc, ulong blocks);
18void StoreBlocks(void* pDst, void* pSrc, ulong blocks);
19void StoreData(void* pDst, void* pSrc, ulong size);
20
21inline void* GetBase() {
22 return reinterpret_cast<void*>(OS_CACHE_BASE);
23}
24
25inline void QueueWait(ulong len) {
26 LCQueueWait(len);
27}
28
29inline void QueueWaitEx(ulong len) {
30 while (LCQueueLength() != len) {
31 OSYieldThread();
32 }
33}
34
35} // namespace LC
36} // namespace ut
37} // namespace nw4r
38
39#endif
Debugging library which includes various utilities used by the rest of nw4r.
Definition ut_list.cpp:4