This is the mail archive of the
systemtap@sourceware.org
mailing list for the systemtap project.
Re: [PATCH v2 0/3] Perf support to SDT markers
- From: Namhyung Kim <namhyung at kernel dot org>
- To: fche at redhat dot com (Frank Ch. Eigler)
- Cc: Hemant Kumar <hkshaw at linux dot vnet dot ibm dot com>, linux-kernel at vger dot kernel dot org, srikar at linux dot vnet dot ibm dot com, peterz at infradead dot org, oleg at redhat dot com, hegdevasant at linux dot vnet dot ibm dot com, mingo at redhat dot com, anton at redhat dot com, systemtap at sourceware dot org, masami dot hiramatsu dot pt at hitachi dot com, aravinda at linux dot vnet dot ibm dot com
- Date: Tue, 08 Oct 2013 18:10:52 +0900
- Subject: Re: [PATCH v2 0/3] Perf support to SDT markers
- Authentication-results: sourceware.org; auth=none
- References: <20131007063911 dot 11693 dot 33624 dot stgit at hemant-fedora> <y0m38odytfm dot fsf at fche dot csb>
Hi Frank,
On Mon, 07 Oct 2013 11:47:09 -0400, Frank Ch. Eigler wrote:
> Hemant Kumar <hkshaw@linux.vnet.ibm.com> writes:
>
>> [...]
>> A simple example to show this follows.
>> - Create a file with .d extension and mention the probe names in it with
>> provider name and marker name.
>> [...]
>> - Now create the probes.h and probes.o file :
>> $ dtrace -C -h -s probes.d -o probes.h
>> $ dtrace -C -G -s probes.d -o probes.o
>> [...]
>
> It may be worthwhile to document an even-simpler case:
>
> - no .d file
> - no invocation of the dtrace python script
> - no generated .h or .o file
> - in the C file, just add:
>
> #include <sys/sdt.h>
>
> void main () {
> /* ... */
> STAP_PROBE(provider_name,probe_name);
> /* ... */
> }
>
> - gcc file.c
> - stap -l 'process("./a.out").mark("*")' to list
Yes, looks much simpler and better.
Hemant, would you add it to the doc too?
Thanks,
Namhyung