signals and _REENT
Thu Feb 26 23:45:00 GMT 2015
On February 26, 2015 5:31:53 PM EST, Jeff Johnston <email@example.com> wrote:
>----- Original Message -----
>> From: "Freddie Chopin" <firstname.lastname@example.org>
>> To: email@example.com
>> Sent: Thursday, February 26, 2015 4:55:00 PM
>> Subject: Re: signals and _REENT
>> On 02/26/2015 10:41 PM, Jeff Johnston wrote:
>> > Actually I did miss something. Since we are using the global list,
>> > we have to thread protect it with locking and unlocking. The
>> > would be
>> > to add two new locks: __sigfunc_lock_acquire() and
>> > which
>> > are needed if not single threaded. This will cause some breakage
>> > builds that
>> > use threads until they define these locks. Perhaps a single global
>> > lock might
>> > be helpful.
>> In that case maybe it would be a good idea to "reuse" the lock that
>> used with _GLOBAL_REENT in stdio? Or do you think separate lock for
>> signals and separate lock for stdio would be a better option (smaller
>> chance of congestion)?
>I had thought of that. I'm ok with using the _newlib_sfp_lock_start
>_newlib_sfp_lock_end macros as they are defined in stdio/local.h. If
>objects, I can do that at least for now.
How many locks does newlib require? Is there a per thread factor?
>-- Jeff J.
More information about the Newlib