posix-threads.cc (park): Rewrite code to handle time.
authorAndrew Haley <aph@redhat.com>
Tue, 17 Nov 2009 18:05:00 +0000 (18:05 +0000)
committerAndrew Haley <aph@gcc.gnu.org>
Tue, 17 Nov 2009 18:05:00 +0000 (18:05 +0000)
commit6bab0284947ba4c0e4028ea7703d90a8fba932b2
tree20d1549cdc546ec2d35dc2b1c11cf122162ef5db
parent37740cd3af83c312403d90defa95b2832dbc582a
posix-threads.cc (park): Rewrite code to handle time.

2009-11-17  Andrew Haley  <aph@redhat.com>

* posix-threads.cc (park): Rewrite code to handle time.
Move mutex lock before the call to compare_and_swap to avoid a
race condition.
Add some assertions.
(unpark): Add an assertion.
(init): Move here from posix-threads.h.
* include/posix-threads.h (destroy): removed.

From-SVN: r154265
libjava/ChangeLog
libjava/include/posix-threads.h
libjava/posix-threads.cc