From owner-freebsd-hackers Wed Aug 19 20:34:50 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id UAA03576 for freebsd-hackers-outgoing; Wed, 19 Aug 1998 20:34:50 -0700 (PDT) (envelope-from owner-freebsd-hackers@FreeBSD.ORG) Received: from mail1.its.rpi.edu (mail1.its.rpi.edu [128.113.100.7]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id UAA03569 for ; Wed, 19 Aug 1998 20:34:49 -0700 (PDT) (envelope-from drosih@rpi.edu) Received: from [128.113.24.147] (lucky.dynamic.rpi.edu [128.113.24.147]) by mail1.its.rpi.edu (8.8.8/8.8.6) with ESMTP id XAA09870; Wed, 19 Aug 1998 23:34:25 -0400 Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" X-Sender: drosih@pop1.rpi.edu Message-Id: In-Reply-To: <199808192249.RAA14808@detlev.UUCP> References: (message from Garance A Drosihn on Wed, 19 Aug 1998 14:57:20 -0400) Date: Wed, 19 Aug 1998 23:38:22 -0400 To: joelh@gnu.org From: Garance A Drosihn Subject: Re: proposal to not change time_t Cc: hackers@FreeBSD.ORG Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG At 5:49 PM -0500 8/19/98, Joel Ray Holveck wrote: > Garance wrote: >> I do think it's useful to have time resolution be better than >> 1 second. > > I still haven't heard why this is a useful filesystem addition. > (Please no flame wars!) Back in the 80's, I worked on a mainframe OS which also stored lastdatachangetime in seconds. It also had make. It also ran on multiprocessors, which can make things just a little more interesting. Occasionally we would see situations where a make would not "work as desired", because two files would have the same timestamp to within a second. FileA was really older than FileB, and FileB needed to be remade when FileA changed, but it wouldn't be remade because they both seemed to have the same timestamp. It didn't happen all that often, but when it did it would be really irritating to figure out why things weren't working. We updated that operating system to keep filechange timestamps to greater than a second resolution. My guess is that as personal computers get faster and faster, the same sort of thing can and will happen. Just think, before we see the year 2039, we'll be seeing multi-processor Mckinley-class machines selling for $800 from insight... :-) (reference to some dual-processor PPro machines I just bought...) Of course, there is one very significant difference with most personal computers. There is usually only one person making system-level changes on a given machine at a time. If I remember the problem on the mainframe correctly, it tended to come up because one systems-programmer person was installing changes to some system-include library at the same time another systems-programmer was recompiling pieces of the system... >> We currently have the 32-bit time_t, and the 32 bits stolen to give >> us nanosecond timestamps. Just how weird would it be to make it a >> 64-bit time field which was 1024'ths of a second? To get a valid >> time_t (in seconds) you'd have to shift the value a few bits, and >> you could provide that value in a 64-bit number if you want. > > Ugh. At least make it a multiple of 8 bits, ie 255ths of a second. Well, that would be nicer. I think IBM used 1024's of a second, and (whatever they did use) I always thought it was an odd choice... I should see if I can dig up an old 370/XA-architecture manual and get the right details. Actually, I think it'd be fine to split the extra 32 bits in half. Use 16 bits to extend the range of time_t, and sixteen bits to increase the resolution of timestamps in the filesystem. If time_t were 48 bits, when would we be running into *that* limit? --- Garance Alistair Drosehn = gad@eclipse.its.rpi.edu Senior Systems Programmer or drosih@rpi.edu Rensselaer Polytechnic Institute To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message