Yeah, and Tom barely scratches the surface. Just handling the occasional leap second is quite the feat and can push all kinds of systems over the cliff. Just look at Five different ways to handle leap seconds with NTP.

Imagine, for example, you are running a livestream (audio, video, doesn't matter). Syncronization depends on knowing the server time and the client time. If they are off, the stream might skip (forwards or backwards).

If time slewing is in effect, audio might fail altogether, because the sample rate of audio (as is handled on the network and in software based on system time) might differ from the sample rate in your hardware (as defined by some crystal oszilator).

And if time slewing is NOT used, the livestream may fall altogether, because the software might not be able to handle 61 seconds in a minute and crash with an error.

More reads, because, yes, handling leap seconds is complicated, expensive, and a science in itself:

And this is just one small aspect of horology (or chronometry). Remember, if you want exact time calculations, you even have to keep track of earthquakes: (NASA scientists) also found the earthquake decreased the length of day by 2.68 microseconds.

PerlMonks XP is useless? Not anymore: XPD - Do more with your PerlMonks XP
Also check out my sisters artwork and my weekly webcomics

In reply to Re^3: A Very Fast 64–Bit Date Algorithm by cavac
in thread A Very Fast 64–Bit Date Algorithm by mldvx4

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.