|
|
Subscribe / Log in / New account

System call conversion for year 2038

System call conversion for year 2038

Posted May 12, 2015 9:14 UTC (Tue) by arnd (subscriber, #8866)
In reply to: System call conversion for year 2038 by Karellen
Parent article: System call conversion for year 2038

Well, as was discussed in the email thread, anything that deals with inode time stamps has to use a 64-bit seconds value, and that is good enough for all practical uses. Using sub-nanosecond values for the fractional seconds would add very noticeable overhead with little benefit.

For interfaces that deal with timeouts (e.g. clock_nanosleep()), or current time (e.g. clock_gettime()), using unsigned 64-bit nanoseconds gives us until 2554, over 500 years before we have to come up with something else. If we can gain a noticeable performance improvement using the nanosecond based interface until then, it should be worth the effort.


to post comments

System call conversion for year 2038

Posted May 13, 2015 3:08 UTC (Wed) by eternaleye (guest, #67051) [Link]

That would seem to militate in favor of separate time formats for "point time" (timespec) and "interval time" (u64 ns) - as has occurred in more modern date/time libraries, such as Joda Time.

Furthermore, at that point "now" could be defined in an offset-ish way - use point time for "when we booted" and interval time for "...and how long has it been since then?"

But that'd be an even more drastic API change, and thus deeply unlikely.


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