зеркало из https://github.com/mozilla/pjs.git
Reverting last change.
This commit is contained in:
Родитель
d0c3a704c2
Коммит
47d1d132c3
|
@ -93,24 +93,6 @@ js_CompareAndSwap(jsword *w, jsword ov, jsword nv)
|
|||
}
|
||||
}
|
||||
|
||||
#elif defined(__GNUC__) && defined(__i386__) && !defined(NSPR_LOCK)
|
||||
|
||||
/* Note: This fails on 386 cpus, cmpxchgl is a >= 486 instruction */
|
||||
JS_INLINE int
|
||||
js_CompareAndSwap(jsword *w, jsword ov, jsword nv)
|
||||
{
|
||||
unsigned int res;
|
||||
|
||||
__asm__ __volatile__ (
|
||||
"lock cmpxchgl %2, (%1)\n"
|
||||
"sete %%al\n"
|
||||
"andl $1, %%eax\n"
|
||||
: "=a" (res)
|
||||
: "r" (w), "r" (nv), "a" (ov)
|
||||
: "cc", "memory");
|
||||
return res;
|
||||
}
|
||||
|
||||
#elif defined(SOLARIS) && defined(sparc) && !defined(NSPR_LOCK)
|
||||
|
||||
#ifndef ULTRA_SPARC
|
||||
|
|
|
@ -159,8 +159,7 @@ extern JSBool js_IsScopeLocked(JSScope *scope);
|
|||
JS_LOCK_RUNTIME_VOID(_rt, e); \
|
||||
JS_END_MACRO
|
||||
|
||||
#if defined(JS_USE_ONLY_NSPR_LOCKS) || \
|
||||
!( (defined(_WIN32) && defined(_M_IX86)) || defined(SOLARIS) || defined(AIX) || (defined(__GNUC__) && defined(__i386__)) )
|
||||
#if defined(JS_USE_ONLY_NSPR_LOCKS) || !(defined(_WIN32) || defined(SOLARIS) || defined(AIX))
|
||||
|
||||
#undef JS_LOCK0
|
||||
#undef JS_UNLOCK0
|
||||
|
|
Загрузка…
Ссылка в новой задаче