#include #include // randomx (pulled in by monero's proof-of-work code) calls the compiler-rt // builtin __clear_cache from its AArch64 JIT. libSystem exports it on macOS and // the simulator, but not on iOS devices, so provide the same implementation // compiler-rt uses on Darwin. void __clear_cache(void *start, void *end) { sys_icache_invalidate(start, (size_t)((char *)end - (char *)start)); }