(WiiU) Implement __clear_cache

This seems to maybe be a libgcc builtin and even explicit calls to it 
are removed.. so we have a Makefile workaround!
This commit is contained in:
Ash Logan 2022-06-07 01:07:01 +10:00
parent 148f5f7499
commit d6250fd58c

View file

@ -142,6 +142,15 @@ long sysconf(int name) {
}
}
/**
* Intended to replace libgcc's __clear_cache builtin.
* For cores that need it, add -D__clear_cache=wiiu_clear_cache to CFLAGS.
*/
void wiiu_clear_cache (char *beg, char *end) {
DCFlushRange(beg, (uint32_t)(end - beg));
ICInvalidateRange(beg, (uint32_t)(end - beg));
}
/**
* Implementation of getifaddrs() and freeifaddrs() for WiiU.
*/