[Discuss] Unix date beyond 2057
Alan W. Irwin
irwin at beluga.phys.uvic.ca
Fri Feb 29 00:38:31 PST 2008
On 2008-02-28 14:25-0800 pw wrote:
> pw wrote:
>> Hello,
>>
>> Does anyone know if there is a patch for
>> unix date to allow dates beyond 2057?
>>
>> Thanks
>>
>> Peter
>
> Actually that should be 2037 not 2057.
>
> The date function doesn't complain about
> dates beyond 2038 through 2057 but it generates
> dates that are wrong beyond 01/19/2038.
Yes, on 32-bit Linux boxes time is currently stored as _signed_ 32 bit
integer number of seconds since epoch (1970 or so) which works out to a
range of approximately +/- 68 years from the epoch. However, on 64-bit
Linux machines, the valid date range grows to +/- 300 billion years!
That is an illustration of Eric Raymond's point that there is no conceivable
need for machines with word lengths larger than 64 bits so he predicts the
current transition from 32-bit to 64-bit that is going on is probably the
last such transition for the human race. Normally, I pooh-pooh any such
conclusion about limits for computers because so many have been so wrong
about that before, but nevertheless, a 128-bit machine would have integer
ranges that are 2^{64} times larger than a current 64-bit machine, and it
really is hard to conceive of any practical software application that would
overflow such a huge integer range.
Alan
__________________________
Alan W. Irwin
Astronomical research affiliation with Department of Physics and Astronomy,
University of Victoria (astrowww.phys.uvic.ca).
Programming affiliations with the FreeEOS equation-of-state implementation
for stellar interiors (freeeos.sf.net); PLplot scientific plotting software
package (plplot.org); the libLASi project (unifont.org/lasi); the Loads of
Linux Links project (loll.sf.net); and the Linux Brochure Project
(lbproject.sf.net).
__________________________
Linux-powered Science
__________________________
More information about the Discuss
mailing list