extern inline int __compare_and_swap(long * p, long oldval, long newval)
__compare_and_swap (long int *p, long int oldval, long int newval)
extern inline int __compare_and_swap(long * p, long oldval, long newval){  long ret;  __asm__ __volatile__ (	"/* Inline compare & swap */\n\t"	".set\tmips2\n"	"1:\tll\t%0,%4\n\t"	".set\tnoreorder\n\t"	"bne\t%0,%2,2f\n\t"	"move\t%0,%3\n\t"	".set\treorder\n\t"	"sc\t%0,%1\n\t"	"beqz\t%0,1b\n"	"2:\t.set\tmips0\n\t"	"/* End compare & swap */"	: "=&r"(ret), "=m"(*p)	: "r"(oldval), "r"(newval), "m"(*p));  return ret;}