ir: clock: use value in cycles instead of ns
authorPhilippe Proulx <eeppeliteloop@gmail.com>
Tue, 16 Feb 2016 01:13:02 +0000 (20:13 -0500)
committerJérémie Galarneau <jeremie.galarneau@efficios.com>
Fri, 19 Feb 2016 22:21:34 +0000 (17:21 -0500)
commite1e30a8c4db03e39b614e97479a3f0aeb1ceadc7
treed7479d77ddad34a83e1570cd32e2ae92740f7f45
parent586411e520c7cb71f6b0d8a4763bde72d637915e
ir: clock: use value in cycles instead of ns

The value of a clock in CTF is in cycles, not in nanoseconds.
Here, bt_ctf_clock_get_time() and bt_ctf_clock_set_time() are left
as utilities to converter from/to the clock value in cycles.
Note that this conversion, unless the frequency is exactly 1 GHz,
implies casting 64-bit integers to doubles so it is possible to
lose accuracy.

Signed-off-by: Philippe Proulx <eeppeliteloop@gmail.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
formats/ctf/ir/clock.c
include/babeltrace/ctf-ir/clock-internal.h
include/babeltrace/ctf-ir/clock.h
tests/lib/test_ctf_writer.c
This page took 0.025423 seconds and 4 git commands to generate.