Re: [pgsql-patches] Patch to avoid gprof profilingoverwrites - Mailing list pgsql-patches

From Neil Conway
Subject Re: [pgsql-patches] Patch to avoid gprof profilingoverwrites
Date
Msg-id 1170312040.12546.102.camel@localhost.localdomain
Whole thread Raw
In response to Re: [pgsql-patches] Patch to avoid gprof profilingoverwrites  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: [pgsql-patches] Patch to avoid gprof profilingoverwrites
List pgsql-patches
On Thu, 2007-02-01 at 00:59 -0500, Tom Lane wrote:
> Is there a way to detect via #if that profiling is enabled?  I wouldn't
> expect a really portable answer, but maybe there's something that works
> for gcc?

What about a "--enable-gprof" (or "--enable-profiling"?) configure flag?
This could add the appropriate compiler flags to CFLAGS, enable
LINUX_PROFILE if on Linux, and enable the "gprof/pid" mkdir().

-Neil



pgsql-patches by date:

Previous
From: Tom Lane
Date:
Subject: Re: [pgsql-patches] Patch to avoid gprof profilingoverwrites
Next
From: Peter Eisentraut
Date:
Subject: Re: [pgsql-patches] Patch to avoid gprof profilingoverwrites