Re: Timers and timing, was: MySQL Performance 6.0rc1

From: David Xu (davidxu_at_freebsd.org)
Date: 10/28/05

  • Next message: Marcin Jessa: "Re: WARNING: attempt to net_add_domain(netgraph) after domainfinalize()"
    Date: Fri, 28 Oct 2005 21:25:03 +0800
    To: ticso@cicely.de
    
    

    Bernd Walter wrote:

    >On Fri, Oct 28, 2005 at 06:43:10PM +0800, David Xu wrote:
    >
    >
    >>Poul-Henning Kamp wrote:
    >>
    >>
    >>>In message <4361FDBE.7000500@freebsd.org>, David Xu writes:
    >>>
    >>>
    >>>the correct way to optimize this would be to add a time(2) systemcall
    >>>which returns the value of the kernel global time_second.
    >>>
    >>>
    >>>
    >>Can we make a page in kernel address space which is readable my user
    >>code? put the variable in the page, I know read an integer is atomic-op,
    >>needn't lock, so syscall is not needed.
    >>
    >>
    >
    >Don't whink it is importent for 1s intervalls, but atomic != coherent.
    >
    >
    >
    That's just an idea. :-)
    As robert said, add a lower resolution CLOCK_ type may work well.
    Another thing I just though of, if reading timercounter is so slow, won't
    gettimeofday hardly block cpu too many cycles ? the cpu is just stucked
    there by a slow clock in hardware signals.

    _______________________________________________
    freebsd-current@freebsd.org mailing list
    http://lists.freebsd.org/mailman/listinfo/freebsd-current
    To unsubscribe, send any mail to "freebsd-current-unsubscribe@freebsd.org"


  • Next message: Marcin Jessa: "Re: WARNING: attempt to net_add_domain(netgraph) after domainfinalize()"