public:
using cycles_t = uint64_t;
using scycles_t = int64_t;
+ using cuptr = std::unique_ptr<const clock_class>;
const std::string name;
const std::string description;
_gid{egid},
_app_tracer_version{.major = major, .minor = minor},
_tracing_id{tracing_id},
+ _clock{lttng::make_unique<lsu::clock_class>()},
_metadata_generating_visitor{lttng::make_unique<ls::tsdl::trace_class_visitor>(abi,
[this](const std::string& fragment) {
_append_metadata_fragment(fragment);
void lsu::registry_session::_accept_on_clock_classes(lst::trace_class_visitor& visitor) const
{
ASSERT_LOCKED(_lock);
- _clock.accept(visitor);
+ _clock->accept(visitor);
}
void lsu::registry_session::_accept_on_stream_classes(lst::trace_class_visitor& visitor) const
{
lttng::pthread::lock_guard registry_lock(_lock);
+ /* Resample the clock */
+ _clock = lttng::make_unique<lsu::clock_class>();
+
_metadata_version++;
_reset_metadata();
_generate_metadata();
/* The id of the parent session. */
const ltt_session::id_t _tracing_id;
- lttng::sessiond::ust::clock_class _clock;
+ lttng::sessiond::ust::clock_class::cuptr _clock;
const lttng::sessiond::trace::trace_class_visitor::cuptr _metadata_generating_visitor;
};