libitm: Fix privatization safety during upgrades to serial mode.
authorTorvald Riegel <triegel@redhat.com>
Sat, 24 Dec 2011 01:42:35 +0000 (01:42 +0000)
committerTorvald Riegel <torvald@gcc.gnu.org>
Sat, 24 Dec 2011 01:42:35 +0000 (01:42 +0000)
commit610e39013598f4f3bc66c117c3402c07b517cfa0
treefd0ffc4afe2a926dc6676559d466c9ae7fad9c2b
parent799142bf743cb04f3a86df85c69481a3c44c1ad9
libitm: Fix privatization safety during upgrades to serial mode.

libitm/
* beginend.cc (GTM::gtm_thread::restart): Add and handle
finish_serial_upgrade parameter.
* libitm.h (GTM::gtm_thread::restart): Adapt declaration.
* config/linux/rwlock.cc (GTM::gtm_rwlock::write_lock_generic):
Don't unset reader flag.
(GTM::gtm_rwlock::write_upgrade_finish): New.
* config/posix/rwlock.cc: Same.
* config/linux/rwlock.h (GTM::gtm_rwlock::write_upgrade_finish):
Declare.
* config/posix/rwlock.h: Same.
* method-serial.cc (GTM::gtm_thread::serialirr_mode): Unset reader
flag after commit or after rollback when restarting.

From-SVN: r182675
libitm/ChangeLog
libitm/beginend.cc
libitm/config/linux/rwlock.cc
libitm/config/linux/rwlock.h
libitm/config/posix/rwlock.cc
libitm/config/posix/rwlock.h
libitm/libitm_i.h
libitm/method-serial.cc