X-Original-To: pgsql-performance-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.2]) by svr1.postgresql.org (Postfix) with ESMTP id 5A4F3D1EC92 for ; Tue, 23 Mar 2004 22:17:54 +0000 (GMT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (neptune.hub.org [200.46.204.2]) (amavisd-new, port 10024) with ESMTP id 48025-03 for ; Tue, 23 Mar 2004 18:17:54 -0400 (AST) Received: from sss.pgh.pa.us (unknown [192.204.191.242]) by svr1.postgresql.org (Postfix) with ESMTP id E8CFFD1EC50 for ; Tue, 23 Mar 2004 18:17:51 -0400 (AST) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.12.11/8.12.11) with ESMTP id i2NMHrWp007084; Tue, 23 Mar 2004 17:17:53 -0500 (EST) To: Darcy Buskermolen Cc: pgsql-performance@postgresql.org Subject: Re: Fwd: FreeBSD, PostgreSQL, semwait and sbwait! In-reply-to: <200403231248.34425.darcy@wavefire.com> References: <200403231248.34425.darcy@wavefire.com> Comments: In-reply-to Darcy Buskermolen message dated "Tue, 23 Mar 2004 12:48:34 -0800" Date: Tue, 23 Mar 2004 17:17:53 -0500 Message-ID: <7083.1080080273@sss.pgh.pa.us> From: Tom Lane X-Virus-Scanned: by amavisd-new at postgresql.org X-Archive-Number: 200403/332 X-Sequence-Number: 6188 Darcy Buskermolen writes: > The database server is a dual P4-2.8 w/ HT enabled (kernel finds 4 > processors), 2GB RAM, 4 disk Serial ATA on 3ware RAID, gigabit Ethernet > connection to web servers. It's running FreeBSD 5.2 and PostgreSQL 7.4.1. Hm. What happens if you turn off the hyperthreading? We have seen a number of reports recently that suggest that our spinlocking code behaves inefficiently on hyperthreaded machines. This hasn't got to the point where we have any substantiated evidence, mind you, but maybe you can help provide some. Also it might be interesting to put one of these into the outer loop in s_lock(): __asm__ __volatile__( " rep; nop \n" : : : "memory"); (This suggestion is a quick-and-dirty backport of a change that's already in CVS tip.) regards, tom lane