Re: Access statistics

From: Jan Wieck <JanWieck(at)Yahoo(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Jan Wieck <JanWieck(at)Yahoo(dot)com>, PostgreSQL HACKERS <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Access statistics
Date: 2001-06-01 14:34:36
Message-ID: 200106011434.f51EYas01443@jupiter.us.greatbridge.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Tom Lane wrote:
> Jan Wieck <JanWieck(at)Yahoo(dot)com> writes:
> > So outing myself not beeing a *real programmer*, this is what
> > I have so far:
>
> Hmm ... what is the performance of all this like? Seems like a lot
> of overhead. Can it be turned off?

Current performance loss is about 2-4% wallclock measured. I
expect it to become better when turning some of the functions
into macros.

The plan is to add another column to pg_database that can be
used to turn it on/off on a per database level. Backends just
decide at startup if they collect and send for their session
lifetime.

> > * Backends call some collector functions at various places
> > now (these will finally be macros), that count up table
> > scans, tuples returned by scans, buffer fetches/hits and
> > the like.
>
> Have you removed the existing stats-gathering support
> (backend/access/heap/stats.c and so on)? That would buy back
> at least a few of the cycles involved ...

Not sure if we really should. Let's later decide if it's
really obsolete.

--

#======================================================================#
# It's easier to get forgiveness for being wrong than for being right. #
# Let's break this rule - forgive me. #
#================================================== JanWieck(at)Yahoo(dot)com #

_________________________________________________________
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2001-06-01 14:42:30 Re: Access statistics
Previous Message Tom Lane 2001-06-01 14:08:41 Re: Access statistics