[go-nuts] High precision timer data?

2018-03-01 Thread James Chacon
I know the time package includes support for using the cycle timer on the machine (if available) to get high precision monotonic time measurements. But...calling time.Now() appears to have a lot of overhead. Measuring the delay between 2 consecutive calls gives me anywhere from 150ns to 900+ns dep

Re: [go-nuts] High precision timer data?

2018-03-01 Thread James Chacon
On Thu, Mar 1, 2018 at 10:13 AM, Ian Lance Taylor wrote: > On Thu, Mar 1, 2018 at 8:56 AM, James Chacon > wrote: > > > > I know the time package includes support for using the cycle timer on the > > machine (if available) to get high precision monotonic time measurement

Re: [go-nuts] High precision timer data?

2018-03-02 Thread James Chacon
On Thu, Mar 1, 2018 at 11:07 PM, James Chacon wrote: > > > On Thu, Mar 1, 2018 at 10:13 AM, Ian Lance Taylor wrote: > >> On Thu, Mar 1, 2018 at 8:56 AM, James Chacon >> wrote: >> > >> > I know the time package includes support for using the cycle time

Re: [go-nuts] High precision timer data?

2018-03-03 Thread James Chacon
On Thu, Mar 1, 2018 at 11:59 PM, James Chacon wrote: > > > On Thu, Mar 1, 2018 at 11:07 PM, James Chacon > wrote: > >> >> >> On Thu, Mar 1, 2018 at 10:13 AM, Ian Lance Taylor >> wrote: >> >>> On Thu, Mar 1, 2018 at 8:56 AM, James Chacon &

Re: [go-nuts] High precision timer data?

2018-03-04 Thread James Chacon
Mar 3, 2018 at 5:23 AM, Donovan Hide wrote: > Looks like you may have hit this: > > https://github.com/golang/go/issues/22601 > > On 3 March 2018 at 09:30, James Chacon wrote: > >> >> >> On Thu, Mar 1, 2018 at 11:59 PM, James Chacon >> wrote: >> >

Re: [go-nuts] High precision timer data?

2018-03-06 Thread James Chacon
I have a hard time believing that will have anywhere near < 100ns granularity considering time.Sleep has microsecond only in testing. James On Mon, Mar 5, 2018 at 5:00 AM, Frederic Landais wrote: > Hello, > > have you considered using time.NewTicker > ?