Path: utzoo!utgpu!news-server.csri.toronto.edu!torsqnt!lethe!yunexus!davecb From: davecb@yunexus.YorkU.CA (David Collier-Brown) Newsgroups: comp.arch Subject: Re: 64 bits for times.... Message-ID: <14423@yunexus.YorkU.CA> Date: 29 Aug 90 12:28:24 GMT References: <11187@alice.UUCP> <3300165@m.cs.uiuc.edu> <2470@crdos1.crd.ge.COM> Organization: York U. Computing Services Lines: 42 >In article <3300165@m.cs.uiuc.edu> gillies@m.cs.uiuc.edu writes: > [ strong statement on stupidity of ns dating ] >| Also, tell me when it will be possible to synchronize all the computer >| clocks with a nano-second accuracy atomic clock. How will such a >| clock be reset later? > I guess the first question is when will there be a benefit from doing >so? And how long will it stay in sync? >| >| My conclusion: ISO should specify a nanosecond relative timer, and a >| much coaser absolute timer (like milliseconds). davidsen@crdos1.crd.ge.COM (Wm E Davidsen Jr) writes: > The timer should not be more accurate than the accuracy of the >setting. Unless there's a good way to set such a timer within a ms >*repeatably* then why worry about how accurately you can measure it? The >relative timer is important, the absolute timer leads people to believe >they have accuracy they don't. Er, this is a solved problem in software engineering... You have an architecture-specific constant that tells you how may bits are significant to the ``right'' of the decimal point ,and a function that returns only those bits non-zero. The application can use a constant-size time variable, and discover how much of it is significant when necessary. If I were writing this in an object-oriented language (:-)), I'd define it thusly: declare clock_$absolute_machine_time entry() fixed decimal (72,36), clock_$accuracy entry() fixed binary (6); --dave (pardon me if I got the PL/1 wrong, but I couldn't resist bring up the 1970s ``state of practice'' solution) c-b -- David Collier-Brown, | davecb@Nexus.YorkU.CA, ...!yunexus!davecb or 72 Abitibi Ave., | {toronto area...}lethe!dave Willowdale, Ontario, | "And the next 8 man-months came up like CANADA. 416-223-8968 | thunder across the bay" --david kipling