Re: LWLock contention: I think I understand the problem

From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
To: "Jeffrey W(dot) Baker" <jwbaker(at)acm(dot)org>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: LWLock contention: I think I understand the problem
Date: 2001-12-30 02:13:36
Message-ID: 200112300213.fBU2DaL02923@candle.pha.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers pgsql-odbc

>
>
> On Sat, 29 Dec 2001, Bruce Momjian wrote:
>
> > OK, here are the results on BSD/OS 4.2 on a 2-cpu system. The first is
> > before the patch, the second after. Both average 14tps, so the patch
> > has no negative effect on my system. Of course, it has no positive
> > effect either. :-)
>
> Actually it looks slighty worse with the patch. What about CPU usage?

Yes, slightly, but I have better performance on 2 cpu's than 1, so I
didn't expect to see any major change, partially because the context
switching overhead problem doesn't see to exist on this OS.

If we find that it helps single-cpu machines, and perhaps helps machines
that had worse performance on SMP than single-cpu, my guess is it would
be a win, in general.

Let me tell you what I did to test it. I ran /contrib/pgbench. I had
the postmaster configured with 1000 buffers, and ran pgbench with a
scale of 50. I then ran it with 1, 10, 25, and 50 clients using 1000
transactions.

The commands were:

$ createdb pgbench
$ pgbench -i -s 50
$ for CLIENT in 1 10 25 50
do
pgbench -c $CLIENT -t 1000 pgbench
done | tee -a pgbench2_7.2

--
Bruce Momjian | http://candle.pha.pa.us
pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 853-3000
+ If your life is a hard drive, | 830 Blythe Avenue
+ Christ can be your backup. | Drexel Hill, Pennsylvania 19026

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Bruce Momjian 2001-12-30 02:30:23 Re: LWLock contention: I think I understand the problem
Previous Message Bruce Momjian 2001-12-30 02:08:59 Re: Latest datetime changes produce gcc complaints

Browse pgsql-odbc by date

  From Date Subject
Next Message Bruce Momjian 2001-12-30 02:30:23 Re: LWLock contention: I think I understand the problem
Previous Message Jeffrey W. Baker 2001-12-30 02:00:43 Re: LWLock contention: I think I understand the problem