View previous topic :: View next topic |
Author |
Message |
bos_mindwarp Apprentice
Joined: 19 Oct 2002 Posts: 275 Location: stockholm, sweden
|
Posted: Thu Apr 03, 2003 1:44 pm Post subject: NPTL |
|
|
Since gentoo has glibc > 2.3 should it have NPTL(native POSIX thread library)?
Or is there a way of enabling it somehow? |
|
Back to top |
|
|
CoronaLover Retired Dev
Joined: 20 Jun 2002 Posts: 163 Location: Rosh-ha'ayin, Israel
|
Posted: Thu Apr 03, 2003 6:52 pm Post subject: |
|
|
Gentoo has NPTL support in the unstable branch, just make sure you have "nptl" in USE. |
|
Back to top |
|
|
skuld n00b
Joined: 13 Oct 2002 Posts: 69
|
Posted: Thu Apr 03, 2003 7:46 pm Post subject: |
|
|
What are the prerequisitives to use NPTL ?
I'm trying to compile glibc with nptl support, and I get this :
Code: |
>>> md5 ;-) nptl-0.29.tar.bz2
* You have "nptl" in your USE, but your kernel version or
* architecture do not support it!
>>> Unpacking source...
|
If I bypass this warning, may I break my system ? |
|
Back to top |
|
|
CoronaLover Retired Dev
Joined: 20 Jun 2002 Posts: 163 Location: Rosh-ha'ayin, Israel
|
Posted: Thu Apr 03, 2003 8:31 pm Post subject: |
|
|
To use NPTL you need:
1. GCC 3.2.2-r2.
2. running Linux >=2.5.50.
3. /usr/src/linux symlink pointing to >=2.5.50 kernel sources. |
|
Back to top |
|
|
Rhino Apprentice
Joined: 12 Feb 2003 Posts: 177
|
Posted: Thu Apr 03, 2003 8:32 pm Post subject: |
|
|
skuld wrote: | What are the prerequisitives to use NPTL ?
I'm trying to compile glibc with nptl support, and I get this :
Code: |
>>> md5 ;-) nptl-0.29.tar.bz2
* You have "nptl" in your USE, but your kernel version or
* architecture do not support it!
>>> Unpacking source...
|
If I bypass this warning, may I break my system ? |
a 2.5.x kernel and gcc-3.2.2-r2 or r3. _________________ With sufficient thrust, pigs fly just fine.
[ RFC 1925 ] |
|
Back to top |
|
|
bos_mindwarp Apprentice
Joined: 19 Oct 2002 Posts: 275 Location: stockholm, sweden
|
Posted: Thu Apr 03, 2003 9:57 pm Post subject: |
|
|
cool thx =) |
|
Back to top |
|
|
bos_mindwarp Apprentice
Joined: 19 Oct 2002 Posts: 275 Location: stockholm, sweden
|
Posted: Fri Apr 04, 2003 2:23 am Post subject: |
|
|
Ok, i installed mm-sources kernel, and re-emerged glibc.
The weird thing is I can spawn 256 threads with NPTL, and I could spawn 1024 threads with the old library? |
|
Back to top |
|
|
skuld n00b
Joined: 13 Oct 2002 Posts: 69
|
Posted: Fri Apr 04, 2003 5:56 am Post subject: |
|
|
Rhino wrote: | a 2.5.x kernel and gcc-3.2.2-r2 or r3. |
OK, thanks.
I just have to wait for 2.6 kernel |
|
Back to top |
|
|
bos_mindwarp Apprentice
Joined: 19 Oct 2002 Posts: 275 Location: stockholm, sweden
|
Posted: Fri Apr 04, 2003 8:00 am Post subject: |
|
|
ok I found it (stupid me)
max thread count depends on following:
- the value in /proc/sys/kernel/threads-max
- amount of RAM
- stack size (default 8MB i think, tunable with: ulimit -s 64, for 64K stack size, toy with value for reaching your optimal) |
|
Back to top |
|
|
asimon l33t
Joined: 27 Jun 2002 Posts: 979 Location: Germany, Old Europe
|
Posted: Fri Apr 04, 2003 8:51 am Post subject: |
|
|
skuld wrote: |
I just have to wait for 2.6 kernel |
The kernel from Red Hat 9 -- which is based on 2.4.20 -- should do fine (although the glibc ebuild has to be changed for this because it checks for kernel version >= 2.5.50 and there is no ebuild yet for this kernel). |
|
Back to top |
|
|
barlad l33t
Joined: 22 Feb 2003 Posts: 673
|
Posted: Fri Apr 04, 2003 10:13 am Post subject: |
|
|
Is there any profit in using NPTL? improved performances? |
|
Back to top |
|
|
asimon l33t
Joined: 27 Jun 2002 Posts: 979 Location: Germany, Old Europe
|
Posted: Fri Apr 04, 2003 10:33 am Post subject: |
|
|
barlad wrote: | Is there any profit in using NPTL? improved performances? |
Yes, much better performance (among other things), especially on multi-processor machines. But most applications will not enjoy any better performance. Only those which utilize Posix threads. See the NPTL design draft for more information. |
|
Back to top |
|
|
knittel n00b
Joined: 29 Nov 2002 Posts: 50
|
Posted: Fri Apr 04, 2003 1:37 pm Post subject: |
|
|
As asked in another post - for the 2.4 Kernel people, what about adding NGPT ? |
|
Back to top |
|
|
|