This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [trans-mem] Move state from gtm_thread to gtm_transaction


On 08/04/2011 09:22 AM, Torvald Riegel wrote:
> On Thu, 2011-08-04 at 08:43 -0700, Richard Henderson wrote:
>> On 08/03/2011 04:04 AM, Torvald Riegel wrote:
>>>     Move local_tid from gtm_thread to gtm_transaction.
>>>     
>>>     	* config/generic/tls.h (gtm_thread): Move local_tid from here ...
>>>     	* libitm_i.h (local_tid): ... to here.
>>>     	* beginend.cc (GTM::gtm_transaction::begin_transaction): Same.
>>>     	(GTM::gtm_transaction::operator new): Set up gtm_thread if necessary.
>>
>> This seems very wrong.  Why?
> 
> What seems wrong?
> 
> local_tid is per thread and there is one gtm_transaction object per
> thread, so moving it is correct, or not?
> The purpose of this is to not having to access gtm_thread anymore in
> begin. And it's a step towards merging gtm_thread and gtm_transaction
> completely.
> 
> Do you agree?

If you're going to merge gtm_thread and gtm_transaction, why
are you moving things away from gtm_thread?

As for "not having to access gtm_thread", the non-glibc case
for accessing gtm_txn is to pull the value out of gtm_thread.

So I think you're moving data in the wrong direction.


r~


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]