Multiple time offsets in trace.dat file

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

 



Hi Steven,
When tracing host and guest machines, in order to overcome the drift
between the times in both contexts, we need to use multiple (at least
2) time offsets. In addition, we need the local time stamp, related to
each offset:
  (ts_offset1, ts_local1), (ts_offset2, ts_local2), ....
 where ts_local1 is the time when the offset ts_offset1 was measured.
This information should be stored somehow in trace.dat file, which
currently supports only one TRACECMD_OPTION_OFFSET option.
There are two possible approaches to do it, please suggest which one to choose:

 1. Use the existing TRACECMD_OPTION_OFFSET, written 2 times in the
trace.dat file. Extract the ts_local1 and ts_local2 times from the
file, as ts_local1 is the time of the first event and ts_local2 is the
time of the last event. There are few  cons of this approach:
        - we can use only 2 offsets, before and after the trace.
        - mapping ts_local1 and ts_local2 to the times of the first
and last event is not accurate, as these are not the actual times when
the time stamps were calculated.
         - Finding first and last event from the trace.dat file will
require one extra parsing of the whole file, as the events there are
not sorted.

 2. Introduce a new TRACECMD_OPTION_ option, which will hold all
ts_offsets together with ts_local times.

-- 
Tzvetomir (Ceco) Stoyanov
VMware Open Source Technology Center




[Index of Archives]     [Linux USB Development]     [Linux USB Development]     [Linux Audio Users]     [Yosemite Hiking]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux