30 #import "../../idlib/precompiled.h"
32 #import <Foundation/Foundation.h>
34 #import <mach/vm_map.h>
37 #define CD_MOUNT_NAME "DOOM"
47 return "/Library/DOOM";
51 static long size_save;
58 kr = vm_allocate(mach_task_self(),
59 (vm_address_t *)&buffer,
77 vm_deallocate(mach_task_self(),
78 (vm_address_t)pointer,
89 size +=
sizeof(
int );
90 kr = vm_allocate(mach_task_self(),
91 (vm_address_t *)&buffer,
113 vm_deallocate(mach_task_self(), (vm_address_t)ptr, size);
116 static inline void __eieio(
void)
121 static inline void __sync(
void)
126 static inline void __isync(
void)
131 static inline void __dcbf(
void *base,
unsigned long offset)
133 __asm__ (
"dcbf %0, %1"
135 :
"r" (base),
"r" (offset)
139 static inline void __dcbst(
void *base,
unsigned long offset)
141 __asm__ (
"dcbst %0, %1"
143 :
"r" (base),
"r" (offset)
147 static inline void __dcbz(
void *base,
unsigned long offset)
149 __asm__ (
"dcbz %0, %1"
151 :
"r" (base),
"r" (offset)
158 for(i = 0; i < bytes; i+= 32) {
166 *(
volatile unsigned long *)(base + i);
GLsizei const GLvoid * pointer
void * osxAllocateMemoryNV(long size, float readFrequency, float writeFrequency, float priority)
void osxFreeMemoryNV(void *pointer)
void osxFreeMemory(void *pointer)
const char * macosx_scanForLibraryDirectory(void)
void Sys_FlushCacheMemory(void *base, int bytes)
void * osxAllocateMemory(long size)