This is the mail archive of the systemtap@sourceware.org mailing list for the systemtap project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Out of order timings of gettimeofday_us()


"Nathan A. Debardeleben" <ndebard@lanl.gov> writes:

> I have a very simple script which seems to demonstrate time values
> coming out of gettimeofday_us() being out of order.  [...]  Is the
> us() timing just too fine grained?  If it's acting like this here I
> question its values in other places.

In the absence of another suitable kernel facility, systemtap's
timestamping functions use the CPU TSC.  If there is more than one
CPU, they have imperfect TSC synchronization, and if a task gets moved
between CPUs between the moments you are taking a snapshot, then this
sort of thing would be expected.  Does this resemble your scenario?

- FChE


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]