Re: DTrace probe patch for OS X Leopard - Mailing list pgsql-patches

From Robert Lor
Subject Re: DTrace probe patch for OS X Leopard
Date
Msg-id 47C813DC.3020001@sun.com
Whole thread Raw
In response to Re: DTrace probe patch for OS X Leopard  (Peter Eisentraut <peter_e@gmx.net>)
Responses Re: DTrace probe patch for OS X Leopard
List pgsql-patches
Peter Eisentraut wrote:
> Another thing that is concerning me about this new approach is the way the
> probes are named.  For example, we'd now have a call
>
> POSTGRESQL_LWLOCK_ACQUIRE()
>
> in the code.  This does not say we are *tracing* lock aquisition, but it looks
> like a macro that actually acquires a lock.
>
Definitely a valid concern.
> I understand that these probe names follow some global naming scheme.  Is it
> hard to change that?  I'd feel more comfortable with, say,
> (D)TRACE_POSTGRESQL_LWLOCK_ACQUIRE().
>
Because the macro is auto generated and follows certain naming
conventions, prepending TRACE_ will not work. If you did that, the probe
name will be called "postgresql-lwlock-aquire" and the provider will be
"trace" which is not what we want.

To avoid the confusion, how about just adding a simple comment like /*
DTrace probe or  Trace point or something similar */  before all
occurrences of the macro calls?

Regards,
-Robert

pgsql-patches by date:

Previous
From: Alvaro Herrera
Date:
Subject: Re: DTrace probe patch for OS X Leopard
Next
From: Alvaro Herrera
Date:
Subject: remove TCL_ARRAYS