nptl - is it beneficial and is it worth it?


Recommended Posts

Hey,

I've been doing some reading lately and I just found out about nptl. Unfortunately, the details for it are a little technical. What I'm wondering, is if its beneficial? If so, what are the benefits? I see that it allows the kernel to do all the scheduling and that parts of it have been optimized - is this noticable on the desktop?

Also, I'm wondering if its worth it - will I need to recompile much of my system in order to use nptl? Also, are there certain apps that don't work with nptl?

Thanks much

My system is so fast with NPTL. It is much more responsive than before. As another Gentoo user said, there is as much of a difference between going from non-nptl to nptl as there is when going from 2.4 to 2.6, and I think that is true. It does require the 2.6 kernel headers which are masked, but all you have to do is add your arch to the KEYWORDS in the ebuild. I did find that...uhhh...I'd say about 2 apps didn't compile the first time with NPTL, but they were easy fixes IIRC. I did do a complete reinstall of Gentoo for NPTL, but then again I have a lot of time on my hands. People have said that they just do glibc and I think gcc and it worked. Pretty much any app that has the nptl use flag should be reconfigured. "emerge -epv world | grep nptl" to see what you should recompile. Play around with it!

Well, since i've recompiled glibc, gcc, and binutils, as well as upgrading to an mm-patched 2.6.2-pre kernel, and prelinked everything, my box is flying, but I can't really say exactly which one of these has made the difference (to be honest, its not a massive difference, but this box was fairly snappy to begin with).

So yeah, I'd recommend it... just be careful to recompile your base stuff (glibc, gcc, binutils) and make sure you're running a recent kernel, because before i finished doing that, some of my apps were segfaulting on me.

From my understanding the big advantage is when you are running lots of threads. More usefull for servers than the desktop. It scales better and creates threads faster. Still a good idea if you are desktop user because it doesn't hurt anything and its kinda cool.

Awesome, performance upgrades are always nice, even if they only work with some Java apps (like I read on the gentoo forums, thanks for pointing me there static void :) ). I'll be installing this later.... just gotta recompile kernel with nptl, install linux-headers, add nptl to use flags, emerge glibc, gcc, binutils, wine as far as I can tell... I'll leave it on overnight.

Rezza, your post reminded me of something that's been bugging me for a while. I've tried using prelink according to the gentoo prelink guide on their site (prelink -afmR) and it runs for a few minutes, erroring on every single kde binary, but it *appears* to be working on other binaries. Unfortunately though, I don't notice the speed increase in startup time. I've left my prelink.conf file to be auto-generated by portage as it tells me to. Is this just happening because prelinking just doesn't work well/isn't very noticable on my computer, or am I doing something wrong?

Thanks for the help you guys =)

yeah MG-Cloud, I had the same thing happen the first time I used it... now I just make sure it doesn't try to preling anything from /opt or anything to do with KDE. It does improve startup times of some apps, but not by all that much. Firebird/thunderbird, abiword, xchat-2, etc are a few which are a bit quicker to open.

Ah, I see. Thanks rezza. I probably just didn't notice the improvement (because I prelinked right after school, a few hours after I had looked at my computer last... it probably felt the same, but was just a little faster).

Also, I think my project for tonight's gonna be nptl then, because frikkin mozilla-firebird-cvs refuses to work :D

Just a quick couple of questions though -

Do i recompile the kernel with nptl support first? If so, do I need to reboot with the updated kernel (and will it work even though my glibc/gcc is not nptl enabled?). Eg. Which comes first?

If it doesn't work, all I need to do is revert back to the old kernel and recompile gcc glibc and binutils without nptl, correct?

Thanks much

erroring on every single kde binary
that's because you gotta re-compile it with -fPIC in your cflags.
Two questions: 1) What's nptl and 2) What does it do?

1) Native POSIX Thread Library

2) Long story very short: It manages threads

A thread is like a task.

Thanks goalie - I'll keep that in mind for my next emerge of kde (i don't really use kde all that much, it's only installed for me to toy around with :p). Is the -fPIC flag smart to use with other packages as well?

Oh, and just wondering about any answers to my questions above :D Doh, I know it hasn't been long since I posted, but I'm bored atm ;)

Thanks !

Well, got mozilla-firebird-cvs working. Awesome. It's much better than 0.7 =)

Was doing a little more research on nptl and found out that ... basically, I apparently don't even need to recompile my kernel. I was sure I saw an NPTL option in there before, but I just took a look at it and couldn't find it again.

So basically then, i just need to install linux-headers, glibc, gcc, binutils w/ nptl, nvidia-glx (heard that you need to re-emerge it), and various stuff that has the nptl USE flag. This seems about right to me, but am I missing something? ;)

Also, it's possible to revert without damaging too much stuff, is it not?

Thanks guys. Sorry for asking so many questions ;)

Well i can't really tellyou any thing other than I use it :-P. Why? well i used Foedora Core 1 and it is used in there, could some one PLEASE tell me why i should use it and if i should use it when i upgrade my Kernel to (from Foedra Default) to 2.6.2

If it's already enabled, you should keep it enabled. If you want a technical explanation of nptl (maybe you will have more luck with it than I did), you can try: http://people.redhat.com/drepper/nptl-design.pdf

Well, I went ahead and took the plunge... recompiled glibc, gcc, binutils with the nptl useflags enabled, as well as any other packages that have the flag. Rebooted, and everything seems to be working fine. Is there any indication I can use to check to see if it's actually working though? ;-)

Thanks!

EDIT:

Thought I'd add this:

U I [ Found these USE variables in : sys-libs/glibc-2.3.3_pre20040117 ]
 + + nls   : unknown
 - - pic   : unknown
 - - build : !!internal use only!! DO NOT SET THIS FLAG YOURSELF!, used for creating build images and the first half of bootstrapping.
 + + nptl  : unknown

This topic is now closed to further replies.
  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Posts

    • Indeed. But note that this has Wifi7, HDMI 2.1, BlueTooth 5.4, and 5G Ethernet, so even in the additional features list this bundle blows the Steam Machine away. And, with the money saved, one could improve this dramatically.
    • One of the strangest galaxies in our Universe could help answer some long overdue questions by Sayan Sen Image by Pixabay via Pexels | Not representative An international team of astronomers led by the Department of Astronomy at Tsinghua University has discovered an unusually metal-poor galaxy that may contain signs of first-generation star formation. The galaxy, named Metal-Pristine Galaxy COSMOS Redshift 3 (MPG-CR3), or CR3, was identified using observations from the James Webb Space Telescope (JWST), the Very Large Telescope (VLT), and the Subaru Telescope. The findings, published in The Astrophysical Journal Letters, describe CR3 as the most metal-poor galaxy known from the period known as "cosmic noon," around 11.5 billion years ago. Cosmic noon refers to a period when the universe was producing stars at its highest rate and galaxies were growing rapidly. In astronomy, "metals" refers to all elements heavier than helium, including oxygen, carbon, and iron. Because CR3 contains so few of these heavier elements, researchers say it closely resembles what scientists expect the earliest galaxies in the universe may have looked like. The discovery is significant because it could offer clues about Population III (Pop III) stars, the first generation of stars thought to have formed after the Big Bang. These stars are believed to have formed from gas made almost entirely of hydrogen and helium, before heavier elements were created inside stars and spread across the universe through supernova explosions. Hence this is why CR3 has been referred to as a "living fossil." Scientists have long believed that Population III stars existed only in the very early universe. As more generations of stars formed and died, they enriched surrounding gas with heavier elements, making the conditions needed for metal-free star formation increasingly rare. Because of this, researchers expected the formation of such stars to have largely ended after the epoch of reionization, a period when radiation from the first stars and galaxies transformed the neutral hydrogen filling the universe and made it largely transparent to ultraviolet light. CR3 appears to challenge that idea. The galaxy was observed at a redshift of z = 3.193 ± 0.016. Redshift measures how much light from a distant object has been stretched as the universe expands and helps astronomers determine how far back in time they are looking. In this case, the redshift corresponds to roughly 11.5 billion years ago during cosmic noon. Although the universe was already several billion years old by that point, CR3 shows characteristics more commonly associated with much earlier galaxies. Observations revealed exceptionally strong emissions from hydrogen and helium, including Lyα, Hα, and He I λ10830. Lyα, or Lyman-alpha emission, is a specific wavelength of light produced by hydrogen and is widely used to study distant galaxies. Hα emission is another hydrogen signature commonly used to trace active star formation, while He I λ10830 is produced by helium and can indicate the presence of very hot, young stars. The measured equivalent widths of EW₀(Lyα) = 822 ± 101 Å and EW₀(Hα) = 2814 ± 327 Å are among the highest ever observed in star-forming galaxies. Equivalent width is a measure of the strength of an emission line relative to the surrounding light, and such large values are typically associated with intense and very recent star formation. At the same time, researchers found no statistically significant detections of metal emission lines, including [O III] λλ4959, 5007 and C IV λλ1548, 1550. Emission lines act as chemical fingerprints that reveal which elements are present in a galaxy. Oxygen and carbon lines are commonly seen in galaxies that have already undergone significant chemical enrichment. Their absence in CR3 suggests an unusually pristine environment. Using abundance calibration methods developed with JWST observations, the team placed a 2σ upper limit on the galaxy's gas-phase metallicity of 12+log(O/H)<6.52, corresponding to less than 0.7% of the Sun's metallicity (Z < 7 × 10⁻³ Z⊙). Gas-phase metallicity measures the abundance of heavy elements in a galaxy's gas. A 2σ upper limit indicates that the true value is very unlikely to be higher than the quoted threshold. Even when accounting for uncertainties in the calibration methods, the most conservative limit remains 12+log(O/H)<6.95, making CR3 the most metal-poor galaxy identified at cosmic noon. The galaxy also appears to contain very little dust. Researchers measured a Lyα/Hα flux ratio of 13.9 ± 2.5, a result that suggests negligible dust attenuation, meaning very little of the galaxy's light is being absorbed or scattered by cosmic dust. Because dust is usually produced by earlier generations of stars, this finding further supports the idea that CR3 has experienced very little chemical enrichment. Further analysis using spectral energy distribution modelling, a technique that compares observed light with theoretical models, suggests that CR3 contains an extremely young stellar population only around 2 million years old. The modelling, which used Population III stellar templates, also indicates the galaxy has a stellar mass of approximately 6.1 × 10⁵ M⊙. The symbol M⊙ represents one solar mass, or the mass of the Sun. One of the key questions raised by the discovery is how such a chemically primitive galaxy could exist in a universe that had already spent billions of years producing heavier elements. To investigate this, the researchers examined CR3's surroundings. Their analysis suggests the galaxy may lie in a slightly underdense environment, with a density contrast of roughly δ ≈ −0.12. An underdense region contains less matter and fewer galaxies than average. The team suggests that this relative isolation may have helped preserve pockets of pristine gas. Metal-rich material expelled from nearby galaxies may never have reached CR3, while the lower rate of galaxy mergers and interactions could have slowed the mixing of enriched gas into the system. If future observations confirm these findings, CR3 could provide some of the strongest evidence yet that first-generation star formation continued well after the epoch of reionization. Such a result would challenge the conventional view that pristine star formation ended by z ≳ 6 and suggest that small pockets of metal-free gas survived much longer than previously thought. Researchers stress that more observations will be needed to determine the galaxy's true nature. Future spectroscopic studies with higher resolution and better signal quality could help confirm whether CR3 is genuinely hosting Population III star formation. The discovery is also expected to encourage searches for other similar galaxies, which could help astronomers better understand how the first stars formed and how galaxies evolved in the early universe. Source: Tsinghua University, IOPscience This article was generated with some help from AI and reviewed by an editor. Under Section 107 of the Copyright Act 1976, this material is used for the purpose of news reporting. Fair use is a use permitted by copyright statute that might otherwise be infringing.
    • "I think in the immediate absence of a partner to apply relief" In the words of Sterling Archer... "Phrasing!"
    • For me, the fundamental problems with these "smartglasses" is that they really don't work well for people with significant prescriptions and massively up the price if you use attached lenses if they have displays, and if they don't, then they're not actually "smart" anything, rather just connecting to your phone and relaying voice to an AI. In a few cases like this, they throw in small cameras to feed video to the AI. All around, these feel like both a solution looking for a problem, and the problems it tries to solve seem more easily solved by different approaches and designs. Oddly, if the rumours are true, Apple may actually have invented something for once and it kind of does this right: put cameras in ear buds and manage the interface to AI exactly as most of us do: tapping on an ear bud and saying "Hey Google" or "Hey Siri." That makes them compatible with almost everyone, can double up as a hearing assist device, an impaired vision assist device, a "smart" device... and answer your phone and play music. That just seems like a better solution all around.
  • Recent Achievements

    • Dedicated
      HidekoYamamoto94 earned a badge
      Dedicated
    • One Month Later
      timbobit earned a badge
      One Month Later
    • One Month Later
      nates earned a badge
      One Month Later
    • Week One Done
      Almohandis earned a badge
      Week One Done
    • Rookie
      dorf went up a rank
      Rookie
  • Popular Contributors

    1. 1
      +primortal
      454
    2. 2
      +Edouard
      161
    3. 3
      PsYcHoKiLLa
      107
    4. 4
      Michael Scrip
      84
    5. 5
      Steven P.
      71
  • Tell a friend

    Love Neowin? Tell a friend!