Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1ZVKBB-0004u4-U0 for pgsql-hackers@arkaria.postgresql.org; Fri, 28 Aug 2015 13:58:54 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84) (envelope-from ) id 1ZVKBB-0003rh-G1 for pgsql-hackers@arkaria.postgresql.org; Fri, 28 Aug 2015 13:58:53 +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) (envelope-from ) id 1ZVKBA-0003rb-V9 for pgsql-hackers@postgresql.org; Fri, 28 Aug 2015 13:58:53 +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) (envelope-from ) id 1ZVKB7-00066s-KP for pgsql-hackers@postgresql.org; Fri, 28 Aug 2015 13:58:52 +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 t7SDwkqI019829; Fri, 28 Aug 2015 09:58:46 -0400 From: Tom Lane To: Noah Misch cc: pgsql-hackers@postgresql.org Subject: Re: [BUGS] Compile fails on AIX 6.1 In-reply-to: <20150828070203.GA2534837@tornado.leadboat.com> References: <1823346352.314711.1405443099463.open-xchange@oxbaltgw55.schlund.de> <14934.1440686206@sss.pgh.pa.us> <20150828070203.GA2534837@tornado.leadboat.com> Comments: In-reply-to Noah Misch message dated "Fri, 28 Aug 2015 03:02:03 -0400" Date: Fri, 28 Aug 2015 09:58:46 -0400 Message-ID: <19828.1440770326@sss.pgh.pa.us> X-Pg-Spam-Score: -3.3 (---) 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 Noah Misch writes: > On Thu, Aug 27, 2015 at 10:36:46AM -0400, Tom Lane wrote: >> the problem is that >> IBM's assembler doesn't understand the "local symbol" notation supported >> by the GNU assembler ("bne 1f" referencing the next occurrence of "1:"). >> So s_lock.h's PowerPC assembly code works if you have gcc configured to >> use gas as backend, but not if it's configured to use the native AIX >> assembler. Steve says the latter configuration is pretty common. > These days, the latter configuration is all but universal. Per the GCC > installation instructions, "The GNU Assembler has not been updated to support > AIX 6 or AIX 7." Ouch. I'm surprised we've not gotten more complaints. >> 2. Don't rely on local symbols in the PPC spinlock assembly code. This >> is a bit ugly, because the only way to do that is to hard-code branch >> offsets, as in the attached draft patch. If there were any likelihood >> that we'd be changing the PPC spinlock code in future, I would regard >> this as unmaintainable ... but really, that code is pretty static. >> So I think this is a viable alternative. > A third option is to use __sync intrinsics, like we do on ARM. I like (2). I've been waiting to hear confirmation from Steve that the proposed patch works with IBM's assembler. (For all I know, it uses "*" rather than ".", or some other randomness.) He's not responded yet though. Are you in a position to test the patch? 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