From: Steven Rostedt <rostedt@goodmis.org>
To: Jason Behmer <jbehmer@google.com>
Cc: tom.zanussi@linux.intel.com, linux-kernel@vger.kernel.org
Subject: Re: Nested events with zero deltas, can use absolute timestamps instead?
Date: Fri, 24 May 2019 11:00:48 -0400 [thread overview]
Message-ID: <20190524110048.142efd44@gandalf.local.home> (raw)
In-Reply-To: <CAMmhGq+8XKBB9GA3J0pwZ6X6Qb1syxKVqNU6i6digtyjMrGyWw@mail.gmail.com>
On Fri, 24 May 2019 07:17:15 -0700
Jason Behmer <jbehmer@google.com> wrote:
> Hi Steven,
> Your other email reminded me of this thread. The easy "fix" we
> decided to pursue was to simply turn on absolute timestamps for all
> events and use up the extra space, which in our particular application
> isn't a huge deal. We haven't yet gotten around to trying to send a
> patch for plumbing user-configurable absolute timestamps, but as noted
> immediately above, the configuration for timestamp_mode is actually a
> bit tricky to implement with the existing histogram ref counting. The
> way I was thinking about dealing with that was to have a separate bool
> to indicate the state the user has indicated they want, and then you
> have to work through all the possible combinations of behavior:
>
> If user absolute timestamps is false, all behavior is exactly as today.
> If user absolute timestamps is true, histogram refs transitioning 0->1
> is a no-op, as is histogram refs transitioning 1->0.
> If histogram refs are 0 and user absolute timestamps transition
> false->true or true->false, they get what they want.
> If histogram refs are >0 and user absolute timestamps transition
> false->true, it's a no-op.
>
> And the confusing one:
> If histogram refs are >0 and user absolute timestamps transitions
> true->false we can't turn off absolute timestamps and screw up the
> histograms, so we return an error. But user absolute timestamps is
> now false, which means when histogram refs transitions back to 0, it
> will turn off absolute timestamps.
>
> What do you think of that?
I don't think that's confusing if its well documented. Have the user
flag called "force_absolute_timestamps", that way it's not something
that the user will think that we wont have absolute timestamps if it is
zero. Have the documentation say:
Various utilities within the tracing system require that the ring
buffer uses absolute timestamps. But you may force the ring buffer to
always use it, which will give you unique timings with nested tracing
at the cost of more usage in the ring buffer.
-- Steve
next prev parent reply other threads:[~2019-05-24 15:00 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <CAMmhGqKc27W03roONYXhmwB0dtz5Z8nGoS2MLSsKJ3Zotv5-JA@mail.gmail.com>
2019-03-29 16:52 ` Steven Rostedt
2019-04-01 22:54 ` Jason Behmer
2019-04-02 2:20 ` Steven Rostedt
2019-04-02 4:42 ` Jason Behmer
2019-05-24 14:17 ` Jason Behmer
2019-05-24 15:00 ` Steven Rostedt [this message]
2019-05-24 15:11 ` Jason Behmer
2019-05-24 15:24 ` Steven Rostedt
2019-05-24 15:48 ` Jason Behmer
2019-05-24 15:54 ` Steven Rostedt
2019-05-24 15:58 ` Steven Rostedt
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20190524110048.142efd44@gandalf.local.home \
--to=rostedt@goodmis.org \
--cc=jbehmer@google.com \
--cc=linux-kernel@vger.kernel.org \
--cc=tom.zanussi@linux.intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®