|
|
Subscribe / Log in / New account

When will nanosleep(2) be rewrtten?

When will nanosleep(2) be rewrtten?

Posted Sep 22, 2005 14:21 UTC (Thu) by NAR (subscriber, #1313)
Parent article: A new approach to kernel timers

If I understand well, the changes described in the article only affect the kernel. I guess the applications don't use the kernel interface directly for timers, they use calls like nanosleep(2), so they can only use this interface if glibc is updated. I wonder how long does this whole process take, from implementing a kernel patch, to integrate it, patch glibc, upgrade the libc packages of the distributions. Maybe a followup article next year would be interesting.

Bye,NAR


to post comments

When will nanosleep(2) be rewrtten?

Posted Sep 22, 2005 14:30 UTC (Thu) by corbet (editor, #1) [Link] (3 responses)

Actually, nanosleep() is a system call. The ktimer patch includes a nanosleep reimplementation, so everything should be in place. You'll need the extra, high-resolution bits (arch-specific timer code) to actually get nanosecond-resolution sleeps, of course.

When will nanosleep(2) be rewrtten?

Posted Sep 22, 2005 18:11 UTC (Thu) by tglx (subscriber, #31301) [Link] (2 responses)

Same applies to itimers and all posix timer interfaces. Once the additional bits for high resolution timers are in place it will work out of the box with no changes to glibc and application code required.

When will nanosleep(2) be rewrtten?

Posted Sep 29, 2005 6:31 UTC (Thu) by goaty (guest, #17783) [Link] (1 responses)

Ironically I think there will be a handful of applications which assume the old, broken behaviour of nanosleep and will misbehave with the new nanosleep. Last time I checked nanosleep rounded the requested delay up to the next tick and then added another tick for good measure. Actually sleeping the requested amount will undoubtedly expose some application bugs.

When will nanosleep(2) be rewrtten?

Posted Oct 1, 2005 17:43 UTC (Sat) by renox (guest, #23785) [Link]

Well given that the tick has changed from 10ms to 1ms to 4ms, I think that the buggy applications must already have been fixed..


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