Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1apoxr-0007L3-0U for pgsql-hackers@arkaria.postgresql.org; Tue, 12 Apr 2016 03:26:07 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84_2) (envelope-from ) id 1apoxq-0000zJ-Ew for pgsql-hackers@arkaria.postgresql.org; Tue, 12 Apr 2016 03:26:06 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1apowV-0007ns-Cl for pgsql-hackers@postgreSQL.org; Tue, 12 Apr 2016 03:24:43 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1apowS-0006GH-Ak for pgsql-hackers@postgreSQL.org; Tue, 12 Apr 2016 03:24:42 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.4/8.14.4) with ESMTP id u3C3OaKW001882; Mon, 11 Apr 2016 23:24:36 -0400 From: Tom Lane To: Andres Freund cc: pgsql-hackers@postgreSQL.org Subject: Re: [COMMITTERS] pgsql: Allow Pin/UnpinBuffer to operate in a lockfree manner. In-reply-to: References: Comments: In-reply-to Andres Freund message dated "Mon, 11 Apr 2016 03:12:51 -0000" Date: Mon, 11 Apr 2016 23:24:36 -0400 Message-ID: <1881.1460431476@sss.pgh.pa.us> X-Pg-Spam-Score: -2.9 (--) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-hackers Precedence: bulk Sender: pgsql-hackers-owner@postgresql.org Andres Freund writes: > Allow Pin/UnpinBuffer to operate in a lockfree manner. This commit has broken buildfarm member gaur, and no doubt pademelon will be equally unhappy once it catches up to HEAD. The reason is that you've caused localbuf.c to perform a whole bunch of atomic operations on its buffer headers; and on machines that don't have native atomic ops, there's a spinlock underlying those; and you did not bother to ensure that appropriate SpinLockInit operations happen for local-buffer headers. (HPPA, possibly alone among supported platforms, does not think that SpinLockInit is equivalent to memset-to-zeroes.) While we could fix this by performing suitable SpinLockInit's on local-buffer headers, I have to think that that's fundamentally the wrong direction. The *entire* *point* of having local buffers is that they are not subject to concurrency overhead. So IMO, sticking atomic-ops calls into localbuf.c is broken on its face. regards, tom lane -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers