--- a/boehm-gc/include/private/gc_locks.h +++ b/boehm-gc/include/private/gc_locks.h @@ -282,7 +282,9 @@ # define GC_TEST_AND_SET_DEFINED # endif # ifdef MIPS -# ifdef LINUX +# if (__GNUC__>4)||((__GNUC__==4)&&(__GNUC_MINOR__>=4)) +# define GC_test_and_set(addr) __sync_lock_test_and_set (addr, 1) +# elif defined(LINUX) # include # define GC_test_and_set(addr) _test_and_set((int *) addr,1) # define GC_TEST_AND_SET_DEFINED --- a/boehm-gc/include/private/gcconfig.h +++ b/boehm-gc/include/private/gcconfig.h @@ -1373,10 +1373,9 @@ /* needs to be tweaked for workstation class machines. */ # define OS_TYPE "LINUX" # define DYNAMIC_LOADING +# define SEARCH_FOR_DATA_START extern int _end[]; # define DATAEND (_end) - extern int __data_start[]; -# define DATASTART ((ptr_t)(__data_start)) # ifdef _MIPS_SZPTR # define CPP_WORDSZ _MIPS_SZPTR # define ALIGNMENT (_MIPS_SZPTR/8)