[DTrace-devel] [PATCH] doc: Add stapsdt provider documentation

Eugene Loh eugene.loh at oracle.com
Wed Nov 19 00:15:16 UTC 2025


On 11/18/25 07:43, Alan Maguire wrote:

> On 18/11/2025 04:30, eugene.loh at oracle.com wrote:
>> From: Eugene Loh <eugene.loh at oracle.com>
>>
>> Signed-off-by: Eugene Loh <eugene.loh at oracle.com>
> looks great, a few small suggestions below, but
>
> Reviewed-by: Alan Maguire <alan.maguire at oracle.com>

Thanks, but...

>> diff --git a/doc/userguide/reference/dtrace_providers_stapsdt.md b/doc/userguide/reference/dtrace_providers_stapsdt.md
>> +    STAP_PROBE3(myprovider, myprobe, argc, argv[0], 18);
>> +    if (myprovider_myprobe_semaphore)
>> +        printf("the probe is enabled\n");
>> +    else
>> +        printf("the probe is not enabled\n");
> I found the example a bit confusing. I would have thought:

(fwiw.  I think it's cool you can check it anyhow, but yeah your example 
makes more sense.)

>> +Notice that the instrumented source code includes the header file
>> +`<sys/sdt.h>`.  On Oracle Linux, this file is installed
>> +by the RPM package `systemtap-sdt-devel`, but the package also
>> +installs `/usr/bin/dtrace`.  So be sure to have `/usr/sbin`
>> +in front of `/usr/bin` in your path, or explicitly specify
>> +`/usr/sbin/dtrace` whenever you want to use `dtrace`.
>> +
> Would be good to mention that a double underscore "__" gets converted to
> a dash (-) in provider/probe names too.

... but what does this have to do with stapsdt?  I thought that was a 
general DTrace thing that would not need to be called out specially here.



More information about the DTrace-devel mailing list