[M3devel] ease of switching between pthreads and userthreads?
Tony Hosking
hosking at cs.purdue.edu
Thu Apr 28 16:22:36 CEST 2011
On Apr 28, 2011, at 3:29 AM, Olaf Wagner wrote:
> Quoting Tony Hosking <hosking at cs.purdue.edu>:
>
>> On Apr 27, 2011, at 3:05 AM, Jay K wrote:
>>
>>> About inlining LOCK I was more echoing your past sentiment
>>> than giving my own, and I provided a mitigation:
>>> a) specifically the suggestion that the switchability be an option;
>>> it'd probably be on by default but people that want to squeeze
>>> out the extra performance could enable the inlining
>>> and lose the switchability
>>
>> It is expected that LOCK will be implemented using CAS (and equivalents) in the very near future. I have a student working on it. This will be incompatible with the current user-threads implementation of LOCK. It will be too painful to support both using a compiler switch.
>
> Couldn't we change the existing user threads to use CAS for locks, too,
> in order to gain runtime switching of thread implementations?
> I have neither thought much about it nor looked at the implementation
> in recent years, so I hope it's no stupid question.
Hmm. Yes, I suppose we could. It might degrade performance of the user-level (uniprocessor) threads implementation.
>
> Olaf
> --
> Olaf Wagner -- elego Software Solutions GmbH
> Gustav-Meyer-Allee 25 / Gebäude 12, 13355 Berlin, Germany
> phone: +49 30 23 45 86 96 mobile: +49 177 2345 869 fax: +49 30 23 45 86 95
> http://www.elegosoft.com | Geschäftsführer: Olaf Wagner | Sitz: Berlin
> Handelregister: Amtsgericht Charlottenburg HRB 77719 | USt-IdNr: DE163214194
>
More information about the M3devel
mailing list