Reentrancy support for multiprocessor systems

J. Johnston jjohnstn@redhat.com
Tue Mar 18 20:27:00 GMT 2003


Hmm.  It was intended that a system would override the function by substituting
its own implementation in the sys directory when multithreading was supported.

If you don't have a system file to replace it, just gut the file for now
so it has nothing inside it.

-- Jeff J.

Likely, Grant wrote:
> Okay, I've compiled the library with __DYNAMIC_REENT__ defined, but the
> function __getreent() in libc/reent/getreent.c is still being compiled in
> because there is no way to conditionally remove it.  I'm going to patch it
> out in my source tree as a work around, but I'm wondering if it should not
> compiled in when __DYNAMIC_REENT__ is set.
> 
> Thanks,
> g.
> 
> --> This is already done for you in libc/include/sys/reent.h.  If you set
> the
> 
>>__DYNAMIC_REENT__
>>flag on while compiling newlib, then all references to _REENT will call a
>>function __getreent().  You will need to supply a version of this function
>>that
>>can figure out which thread it is running under and pass back the
>>appropriate
>>reentrancy structure.
> 




More information about the Newlib mailing list