00001 #ifndef _QORE_MACHINE_MACROS_H
00002
00003 #define _QORE_MACHINE_MACROS_H
00004
00005
00006 #if !defined(__LP64__)
00007
00008 #define STACK_DIRECTION_UP 1
00009
00010 #ifdef __GNUC__
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022 #define HAVE_CHECK_STACK_POS
00023
00024 static inline size_t get_stack_pos() {
00025 size_t addr;
00026 __asm__("copy %%sp,%0" : "=r" (addr) );
00027 return addr;
00028 }
00029
00030 #endif
00031
00032 #ifdef __HP_aCC
00033
00034
00035
00036
00037
00038
00039
00040 #define HAVE_CHECK_STACK_POS
00041
00042 extern "C" size_t get_stack_pos();
00043
00044 #endif
00045
00046 #endif
00047
00048 #endif