Re: ["Matthias Urlichs" <smurf@work.smurf.noris.de>] POSIX vs "right" time difference

Date: Thu, 22 May 1997 15:06:40 +0200 (Funky) From: "Matthias Urlichs" <smurf@work.smurf.noris.de> the POSIX time zone files ignore leap seconds, i.e. are based on GMT, while the 'right' timezone take leap seconds into account. The base difference between those, according to "date", is 20 seconds (soon to be 21). That's wrong. The difference between UTC and TAI ("atomic time") is actually 30 (soon to be 31) seconds; the 10 seconds come from the fact that UTC and TAI were initially synchronized in 1958, and in 1972 it was realized that they've drifted apart... instant 10-second insertion. That's not what happened. There was no 10-second insertion in 1972. The atomic timekeepers didn't wake up from a 14-year sleep and notice that the world's clocks had drifted! Here's a more accurate description of what happened. Before 1972, UTC was adjusted continuously, without using leap seconds. At the moment of the POSIX Epoch (1970-01-01 00:00:00 UTC), UTC and TAI differed, not by an integral number of seconds, but by a fractional number. The difference between UTC and TAI did not become an integer until 1972, when the leap second regime was introduced. Therefore, it is impossible, on a system with integral time_t, to simultaneously support both "right" and POSIX times accurately before 1972. In some sense, the "right" approach yields undefined times before 1972, since the "right" approach assumes leap seconds. But we could attempt to extend the "right" approach by guessing what it would have been like had it existed. That is, with an integral time_t, we could _approximate_ "right" times before 1972 by consulting historical tables of the difference between UTC and TAI, and rounding to the nearest integer. This is unsatisfactory (not least because such tables understandably do not go back to times before atomic clocks were introduced!), but it is probably the best that we can do with the "right" approach assuming integral time_t. I view this improvement as a low-priority task since very few people use the "right" approach these days; the people who care about leap seconds are using other interfaces. Furthermore, the philosophy of the tz package is to describe times as they actually appeared at the time; it's hard to combine this with the notion of gedanken atomic clocks ticking away in, say, 1901.
participants (1)
-
Paul Eggert