Content deleted Content added
m →History: The projects were actually merged with the best parts of both being combined into better system. I was the lead developer of NGPT team. |
m HTTP to HTTPS for SourceForge |
||
(14 intermediate revisions by 10 users not shown) | |||
Line 2:
==History==
Before the 2.6 version of the [[Linux kernel]], processes were the schedulable entities, and there were no special facilities for [[Thread (computer science)|threads]].<ref>[https://web.archive.org/web/20210929083526/https://man7.org/linux/man-pages/man7/pthreads.7.html pthreads(7) — Linux manual page]</ref>
However, it did have a [[system call]] — To improve upon LinuxThreads, it was clear that some kernel support and a new threading library would be required. Two competing projects were started to address the requirement: [[NGPT]] (Next Generation POSIX Threads) worked on by a team which included developers from [[IBM]], and NPTL by developers at [[Red Hat]]. The NGPT team collaborated closely with the NPTL team and combined the best features of both implementations into NPTL. The NGPT project was subsequently abandoned in mid-2003 after merging
NPTL was first released in Red Hat Linux 9. Old-style Linux POSIX threading is known for having trouble with threads that refuse to yield to the system occasionally, because it does not take the opportunity to preempt them when it arises, something that Windows was known to do better at the time. Red Hat claimed that NPTL fixed this problem in an article on the [[Java (programming language)|Java]] website about Java on Red Hat Linux 9.<ref>[https://web.archive.org/web/20110604035631/http://java.sun.com/developer/technicalArticles/JavaTechandLinux/RedHat/ Red Hat Linux 9 and Java 2 Platform, Standard Edition 1.4.2: A Winning Combination]</ref>
NPTL has been part of [[Red Hat Enterprise Linux]] since version 3, and in the Linux kernel since version 2.6. It is now a fully integrated part of the [[GNU C Library]].<ref>[http://lists.gnu.org/archive/html/info-gnu/2004-08/msg00002.html GNU C Library version 2.3.3 release]</ref>
There exists a tracing tool for NPTL, called [
==Design==
Like LinuxThreads, NPTL is a 1:1 threads library. Threads created by the library (via ''pthread_create'') correspond one-to-one with schedulable entities in the kernel (''processes'', in the Linux case).<ref name="lsp-love">{{Cite book |title=Linux System Programming |author=Robert Love |edition=2nd |isbn=978-1449339531 |date=2013|publisher=O'Reilly Media, Incorporated }}</ref>{{rp|226}} This is the simplest of the three [[Thread (computing)#Threading models|threading models]] (1:1, N:1, and M:N).<ref name="lsp-love"></ref>{{rp|215–216}} New threads are created with the clone() [[system call]] called through the NPTL library. NPTL relies on kernel support for [[futex]]es to more efficiently implement user-space locks.<ref name="lsp-love"></ref>{{rp|182}}
==See also==
{{Portal|Free and open-source software}}
* [[LinuxThreads]]
Line 30 ⟶ 27:
==External links==
* [
▲* [http://nptltracetool.sourceforge.net/ NPTL Trace Tool] OpenSource tool to trace and debug multithreaded applications using the NPTL.
{{Linux}}
|