Re: Understading of User trace output

Mathieu Desnoyers <[email protected]> Thu, 9 Aug 2007 15:33:54 -0400
Newsgroups gmane.linux.kernel.tracing
Message-ID <20070809193354.GD25599@Krystal>
* Srinivasa Reddy ([email protected]) wrote:
> Hi Mathieu,
> 
> I am working on user trace. I am able to execute all the commands as per
> the Readme and everything is working fine.
> 
> I am getting the following output when I execute the lttv -m
> textDump...... command.
> 
> But I am not able to understand what does it mean?
> 
> Could you please explain me how can we use the usetrace?
> 

The c files in the usertrace package are examples. sample-printf.c is
less than 10 lines and looks a lot like a normal printf, but outputs the
data in the trace buffers. Each of these lines are an event from your
trace, just like standard kernel events, but they come from userspace.

By using this, you can correlate user-space events with kernel events in
a trace.

More elaborated features are explained in the readme.

Mathieu
> 
> user_generic.string: 42962540.300034178
> (/home/rrao/NFS/NFS_test/home/sreddy/usrtrace3/cpu_0), 327, 327,
> ./sample-tata, UNBRANDED, 268, 0x0, SYSCALL { "Hello world! Have a nice
> day." }
> 
> user_generic.slow_printf: 42962540.350030516
> (/home/rrao/NFS/NFS_test/home/sreddy/usrtrace3/cpu_0), 327, 327,
> ./sample-tata, UNBRANDED, 268, 0x0, SYSCALL { "in: sample-tata.c at:
> main:24: Counter value is: 0." }
> 
> user_generic.string: 42962541.370010985
> (/home/rrao/NFS/NFS_test/home/sreddy/usrtrace3/cpu_0), 327, 327,
> ./sample-tata, UNBRANDED, 268, 0x0, SYSCALL { "Hello world! Have a nice
> day." }
> 
> user_generic.slow_printf: 42962541.370014647
> (/home/rrao/NFS/NFS_test/home/sreddy/usrtrace3/cpu_0), 327, 327,
> ./sample-tata, UNBRANDED, 268, 0x0, SYSCALL { "in: sample-tata.c at:
> main:24: Counter value is: 1." }
> 
> user_generic.string: 42962542.380010985
> (/home/rrao/NFS/NFS_test/home/sreddy/usrtrace3/cpu_0), 327, 327,
> ./sample-tata, UNBRANDED, 268, 0x0, SYSCALL { "Hello world! Have a nice
> day." }
> 
> user_generic.slow_printf: 42962542.380014647
> (/home/rrao/NFS/NFS_test/home/sreddy/usrtrace3/cpu_0), 327, 327,
> ./sample-tata, UNBRANDED, 268, 0x0, SYSCALL { "in: sample-tata.c at:
> main:24: Counter value is: 2." }
> 
> Regards,
> Srinivas.
> 

-- 
Mathieu Desnoyers
Computer Engineering Ph.D. Student, Ecole Polytechnique de Montreal
OpenPGP key fingerprint: 8CD5 52C3 8E3C 4140 715F  BA06 3F25 A8FE 3BAE 9A68