This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc 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: [PATCH v4] Make bindresvport() function to multithread-safe


On Wed, Oct 24, 2012 at 10:38 PM, Peng Haitao <penght@cn.fujitsu.com> wrote:
>>> (a) Mutex
>>> - Decreased concurrency.
>>> - Every program increase .data by sizeof(mutex) (maybe 40-50 bytes).
>>> - Function is now thread safe.
>>
>> Isn't there some internal lock type that's only 4 or 8 bytes rather
>> than a whole pthread_mutex_t?
>>
>
> Using __libc_lock_lock(NAME) is OK?
> Just as patch v2: http://sourceware.org/ml/libc-alpha/2012-09/msg00507.html

What is the performance difference between (a) Mutex i.e. v2 patch and
(b) __thread solution?

Is __thread significantly faster?

Would you be happy with a mutex solution?

Thank you for bearing with us here.

Please understand that your issue touches on a question of policy and
analysis that we have not had before.

Cheers,
Carlos.


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