#define __pure__
#define __attribute__(x)

#define RECMEM_SIZE (8*1024*1024)
//#define memalign(x,y) _aligned_malloc(y,64)
#include "bram.h"
#define malloc(x) balloc(x)
#define free(x) bfree(x)
//#define memalign(x,y) malloc(y)
#define memalign(x,y) balloc(y)


#if !defined(__CRTDECL)
#if defined(_M_CEE_PURE)
#define __CRTDECL
#else
#define __CRTDECL   __cdecl
#endif
#endif

#define __asm__ __asm
#define __volatile__ volatile 
//#define PLUSTARD 1
#define WHERESTR  "[file %s, line %d]: "
#define WHEREARG  __FILE__, __LINE__
#define DEBUGPRINT2(...)       SysPrintf( __VA_ARGS__)
//#define PSXBIOS_LOG(_fmt, ...)  DEBUGPRINT2(WHERESTR _fmt, WHEREARG, __VA_ARGS__)

#define usleep(x)	Sleep(x/1000)