Port-vax archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: PSA: Clock drift and pkgin



On Thu, 14 Dec 2023, Johnny Billquist wrote:

> As for the high frequency clock in the VAX, I'm not sure it is used at all by
> NetBSD. But it's been quite a while since I was digging around, and if someone
> knows it is being used, I'd be happy to hear. But I think we have several
> problems that should be sorted. And for me, the first one would be to
> understand how on earth we can be spending so much time in system mode when we
> do anything.

 If we don't use the high frequency clock, then I recommend that we to.

 I've double-checked the KA60 spec now and we have the DIAGTIMU/DIAGTIMM 
high resolution timer register pair available in the chipset, which gives 
us 1.017us resolution over the period of 68.26s.  It is more than enough 
to provide reasonable timekeeping for a machine of KA60's performance, and 
then the timer tick interrupt can be used to track high resolution timer 
wraparounds only, i.e. to produce the carry to higher bits maintained 
entirely in software (in addition to task scheduling, of course).  It will 
not be critical at all then for timekeeping if the timer tick interrupt 
has variable delivery latency or if a tick gets lost altogether.  Or a 
dozen.

 Of course switching to the high resolution timer won't sort out other 
issues, such as possibly spending too much time in the kernel mode with 
lower-priority interrupts disabled, causing their sources to starve.

  Maciej


Home | Main Index | Thread Index | Old Index