Hi, Alan, On Feb 6, 2010, at 12:23 , Alan W. Irwin wrote:
> my understanding from > http://en.wikipedia.org/wiki/Reentrant_(subroutine) is reentrancy > implies > thread safety. I'm not sure about that. I think a function could utilize thread local storage in a non-reentrant way (i.e. thread safe but not reentrant). Also if a function's reentrancy is dependent on a certain value/consistency of a global variable it would not necessarily be thread safe (i.e. somewhat reentrant, but not thread safe). Both of these cases are somewhat impure, but so is the real world! :-) If a function has no side effects and no external dependencies, then I would agree that it is both reentrant and thread safe. Having no side effects is relatively easy to verify/ensure, but having no external dependencies is harder since any parameter passed by reference represents an external dependency which could put the function's thread safety in the hands of the caller(s). Dave ------------------------------------------------------------------------------ The Planet: dedicated and managed hosting, cloud storage, colocation Stay online with enterprise data centers and the best network in the business Choose flexible plans and management services without long-term contracts Personal 24x7 support from experience hosting pros just a phone call away. http://p.sf.net/sfu/theplanet-com _______________________________________________ Plplot-devel mailing list Plplot-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/plplot-devel