Re: About thread-safety information in library functions' man-pages

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Michael,

> Thanks. That looks promising. Could you elaborate on the meanings of
> the headings, and also explain how you came up with the lists?
> 

Because we have classified lots of the functions into following 
classifications: Unsafe, Safe, Safe with Exceptions, MT-Safe, 
MT-Safe with Exceptions.

The classifications are Based on the thread-safety levels defined in  
Solaris operating system, the meanings are as follows:

- Unsafe: The function contains global or static data that is not 
protected. Accesses by multiple threads will produce unpredictable 
(and probably incorrect) results.

- Safe: The function can be called by multiple threads and will return 
correct results. The function is still allowed to have global effects 
that are seen by all threads, however. It is also allowed to serialize 
all accesses, by protecting the entire function with a lock.

- Safe with Exceptions: The function is safe, except under certain 
circumstances.

- MT-Safe: The function is fully prepared for multi-threaded access. 
All global and static data is protected with locks, and some degree 
of concurrency can be achieved within the function.

- MT-Safe with Exceptions: The function is MT-Safe, except under 
certain circumstances.

-- 
Best Regards,
Peng Haitao

--
To unsubscribe from this list: send the line "unsubscribe linux-man" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Kernel Documentation]     [Netdev]     [Linux Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux