<div dir="ltr"><div>A custom trace event class emits "begin" and "end" events in its constructor and destructor respectively. So I do not think this is due to conditional path.</div><div><br></div>Sequence of commands to capture a snapshot are:<div><div>lttng create --snapshot</div><div>lttng enable-event --userspace --all</div><div>lttng add-context --userspace -t vpid -t vtid</div><div>lttng start<br></div><div>lttng stop</div><div>lttng snapshot record</div></div><div dir="ltr"><div dir="ltr"><div><br></div><div>We create a new session for each snapshot to make sure that the buffer does not have any left-over events from the previous session. But I am curious if lttng shares buffers between sessions or re-uses buffers from an old session without flushing?</div><div><br></div><div>Note that I am using the defaultĀ LTTNG_BUFFER_PER_UID mode. All processes for our application run under one UID, and only one tracing session is active at a time.</div><div><br></div><div><div class="gmail_quote"><div dir="ltr">On Wed, Nov 7, 2018 at 12:09 PM Jonathan Rajotte-Julien <<a href="mailto:jonathan.rajotte-julien@efficios.com" target="_blank">jonathan.rajotte-julien@efficios.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi Alok,<br>
<br>
On Wed, Nov 07, 2018 at 11:53:25AM -0800, Alok Priyadarshi wrote:<br>
> Hi Jonathan,<br>
> <br>
> Thanks for your response.<br>
> <br>
> We are tracing function scopes. Each scope emits two events - begin and<br>
> end. We noticed that some begin events did not have corresponding end<br>
> events in the trace.<br>
<br>
Seems like a solid ground as long as the corresponding ending event is not<br>
inside any conditional paths. I'm sure you already validated that but we never<br>
know.<br>
<br>
> <br>
> I have the trace with this problem available. Would that provide any clue?<br>
<br>
It could help but I presume it might contains confidential or sensible<br>
information. Let's define the scenario first and we will go back to actual<br>
trace data if needed.<br>
<br>
> If not, I will try to extract a small reproducer.<br>
<br>
That would be best. In the meantime, could you provide the exact lttng commands<br>
used to setup everything and describe subsequent lttng commands used for<br>
snapshot etc.<br>
<br>
You can omit event name or replace them with dummy name if necessary.<br>
<br>
Cheers<br>
<br>
-- <br>
Jonathan Rajotte-Julien<br>
EfficiOS<br>
</blockquote></div></div></div></div></div>