mirror of git://gcc.gnu.org/git/gcc.git
natUnsafe.cc (spinlock contructor): Call sched_yield().
2009-01-12 Andrew Haley <aph@redhat.com> * sun/misc/natUnsafe.cc (spinlock contructor): Call sched_yield(). From-SVN: r143302
This commit is contained in:
parent
2842bb86fd
commit
406c72ce52
|
@ -1,3 +1,7 @@
|
||||||
|
2009-01-12 Andrew Haley <aph@redhat.com>
|
||||||
|
|
||||||
|
* sun/misc/natUnsafe.cc (spinlock contructor): Call sched_yield().
|
||||||
|
|
||||||
2009-01-11 Matthias Klose <doko@ubuntu.com>
|
2009-01-11 Matthias Klose <doko@ubuntu.com>
|
||||||
|
|
||||||
* Makefile.am (ecjx_LDADD): Add $(extra_ldflags).
|
* Makefile.am (ecjx_LDADD): Add $(extra_ldflags).
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
// natUnsafe.cc - Implementation of sun.misc.Unsafe native methods.
|
// natUnsafe.cc - Implementation of sun.misc.Unsafe native methods.
|
||||||
|
|
||||||
/* Copyright (C) 2006
|
/* Copyright (C) 2006, 2007
|
||||||
Free Software Foundation
|
Free Software Foundation
|
||||||
|
|
||||||
This file is part of libgcj.
|
This file is part of libgcj.
|
||||||
|
@ -32,7 +32,7 @@ public:
|
||||||
spinlock ()
|
spinlock ()
|
||||||
{
|
{
|
||||||
while (! compare_and_swap (&lock, 0, 1))
|
while (! compare_and_swap (&lock, 0, 1))
|
||||||
;
|
_Jv_ThreadYield ();
|
||||||
}
|
}
|
||||||
~spinlock ()
|
~spinlock ()
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue