Torvald Riegel
bc8da6ba25
libitm: Use ml_wt as default TM methods for >1 thread.
...
libitm/
* retry.cc (GTM::gtm_thread::number_of_threads_changed): Change
default dispatch for more than 1 thread to ml_wt.
From-SVN: r184547
2012-02-24 11:05:37 +00:00
Torvald Riegel
a19db3f2e3
libitm: Fix race condition in dispatch choice at transaction begin.
...
libitm/
* beginend.cc (GTM::gtm_thread::begin_transaction): Move serial lock
acquisition to ...
* retry.cc (GTM::gtm_thread::decide_begin_dispatch): ... here.
(default_dispatch): Make atomic.
(GTM::gtm_thread::set_default_dispatch): Access atomically.
(GTM::gtm_thread::decide_retry_strategy): Access atomically and
use decide_begin_dispatch() if default_dispatch might have changed.
(GTM::gtm_thread::number_of_threads_changed): Initialize
default_dispatch here.
From-SVN: r184392
2012-02-20 13:06:07 +00:00
Torvald Riegel
31772c9507
libitm: Add multi-lock, write-through TM method.
...
libitm/
* libitm_i.h (GTM::gtm_rwlog_entry): New.
(GTM::gtm_thread): Add read and write logs.
(GTM::dispatch_ml_wt): Declare.
* retry.cc (parse_default_method): Support ml_wt.
* method-ml.cc: New file.
* Makefile.am: Add method-ml.cc.
* Makefile.in: Regenerate.
From-SVN: r184212
2012-02-14 13:14:27 +00:00
Torvald Riegel
5b9cf5d2bf
libitm: Improve method reinit and choice.
...
libitm/
* dispatch.h (GTM::abi_dispatch::supports): New.
(GTM::method_group::reinit): New.
* retry.cc (GTM::gtm_thread::decide_retry_strategy): Use reinit().
(GTM::gtm_thread::number_of_threads_changed): Check that the method
supports the current situation.
From-SVN: r184211
2012-02-14 13:14:12 +00:00
Aldy Hernandez
0a35513e4e
Merge from transactional-memory branch.
...
From-SVN: r181154
2011-11-08 11:13:41 +00:00