[TUHS] Date madness

Chris Torek torek at elf.torek.net
Thu Dec 14 10:24:35 AEST 2017


The 780 had only the Time Of Day Register (mfpr $TODR,reg),
but it covered more than a year's worth of "time of day":

    http://h41379.www4.hpe.com/wizard/wiz_1450.html
    http://rbur004.github.io/MacVAX/VAX-IPR/IPL_CLOCK.html

so the standard trick was to assume that the computer had
been booted within a year or so, and use the file system time
plus the TODR value to compute the correct time.

Various MicroVAXen may have added CMOS clock chips, and I vaguely
recall dealing wth BCD-encoded time on another VAX, perhaps the
8800.  I wrote some clock-chip driver code for the 4BSD SPARC port
and tried to consolidate the general issues of dealing with
multiple chip registers, two and four digit year encoding, BCD vs
decimal, and so on.

Chris


More information about the TUHS mailing list