// jhc_rts_header.h #include #include #include #include #include #include #include #include #include #include #ifndef __WIN32__ #include #endif #include // #define our options #define _JHC_GC_NONE 0 #define _JHC_JGC 1 #define _JHC_GC_BOEHM 2 #ifndef _JHC_GC #define _JHC_GC _JHC_GC_NONE #endif #ifndef _JHC_PROFILE #define _JHC_PROFILE 0 #endif #ifndef _JHC_DEBUG #ifdef NDEBUG #define _JHC_DEBUG 0 #else #define _JHC_DEBUG 1 #endif #endif // GNU attributes #ifdef __GNUC__ #define A_ALIGNED __attribute__ ((aligned)) #define A_CONST __attribute__ ((const)) #define A_MALLOC __attribute__ ((malloc)) #define A_MAYALIAS __attribute__ ((__may_alias__)) #define A_NORETURN __attribute__ ((noreturn)) #define A_PURE __attribute__ ((pure)) #define A_UNUSED __attribute__ ((unused)) #ifdef __i386__ #define A_REGPARM __attribute__ ((fastcall)) #else #define A_REGPARM #endif #define A_STD A_REGPARM #else #define A_ALIGNED #define A_CONST #define A_MALLOC #define A_MAYALIAS #define A_NORETURN #define A_PURE #define A_UNUSED #define A_STD #endif // these should be enabled with newer versions of gcc #define A_HOT #define A_COLD #define A_FALIGNED #define STR(s) #s #define XSTR(s) STR(s) #define ALIGN(a,n) ((n) - 1 + ((a) - ((n) - 1) % (a)))