LWN.net Logo

Stable kernel 2.8? No, wait!

Stable kernel 2.8? No, wait!

Posted Feb 28, 2012 5:01 UTC (Tue) by pr1268 (subscriber, #24648)
Parent article: Stable kernel 3.2.8

I thought I read "Stable kernel 2.8" as this article's title. Didn't Linus jump to 3.0? Oh, wait, I missed the "3." in the title. Whew!

;-)

P.S. I also thought that the kernel didn't do any floating-point math or data (in the interest of performance), instead relegating that to userspace. Just curious, what's the FP issue fixed by this upgrade?


(Log in to post comments)

Stable kernel 2.8? No, wait!

Posted Feb 28, 2012 5:52 UTC (Tue) by dlang (✭ supporter ✭, #313) [Link]

Floating point is not used much in the kernel, because any use of floating point requires that the kernel first save the entire state of the floating point system, set it up for the kernel use, and then restore the prior state.

This makes floating point extremely slow and expensive, as a result, the shorthand version is "you aren't allowed to use floating point in the kernel"

But as always in IT, for every rule there is an exception :-)

Stable kernel 2.8? No, wait!

Posted Feb 28, 2012 7:02 UTC (Tue) by slashdot (guest, #22014) [Link]

You can, provided you call the appropriate functions before and after it.

Stable kernel 2.8? No, wait!

Posted Feb 29, 2012 15:50 UTC (Wed) by jengelh (subscriber, #33263) [Link]

And mdraid making heavy use of SSE is one model citizen for this!

Stable kernel 2.8? No, wait!

Posted Feb 28, 2012 11:00 UTC (Tue) by cesarb (subscriber, #6266) [Link]

These changes are from 3.3, so read Linus' explanation at https://lwn.net/Articles/482405/ :

> This time the reason for the delay is that we spent several days chasing down a nasty floating point state corruption that happens on 32-bit x86 - but only if you have a modern CPU (why are you using 32-bit kernels?) that supports the AES-NI instructions. And then you have to enable support for them *and* use a wireless driver that uses it. The most likely reason for that is using the mac80211 infrastructure with WPA with AES encryption (ie usually WPA2).

As you can see, it is not actually floating-point math. It is another instruction which probably uses the same register set. Other places in the kernel can also use that register set; for instance, AFAIR the RAID code can use SSE.

Copyright © 2013, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds