11.6 pid Provider

The pid provider enables tracing of any user process, as specified by its pid.

The pid provider enables tracing function entry and return in user programs just like the fbt provider provides that capability for the kernel. Note that most of the examples in this guide that use the fbt provider to trace kernel function calls can be modified slightly to apply to user processes.

The pid provider also enables tracing of any instruction, as specified by an absolute address or function offset.

The pid provider has no probe effect when probes are not enabled. When probes are enabled, the probes only induce probe effect on those processes that are traced.


When the compiler inlines a function, the pid provider's probe does not fire. Use one of the following methods to compile a particular C function so that it will not be inlined.

  • Sun Studio: #pragma no_inline (funcname[, funcname])

  • gcc: funcname __attribute__ ((noinline))

Consult your compiler documentation for updates.