From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | pgsql-committers(at)postgresql(dot)org |
Subject: | pgsql: Fix s_lock.h PPC assembly code to be compatible with native AIX |
Date: | 2015-08-29 20:09:52 |
Message-ID: | E1ZVmRk-0004iC-3c@gemulon.postgresql.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-committers |
Fix s_lock.h PPC assembly code to be compatible with native AIX assembler.
On recent AIX it's necessary to configure gcc to use the native assembler
(because the GNU assembler hasn't been updated to handle AIX 6+). This
caused PG builds to fail with assembler syntax errors, because we'd try
to compile s_lock.h's gcc asm fragment for PPC, and that assembly code
relied on GNU-style local labels. We can't substitute normal labels
because it would fail in any file containing more than one inlined use of
tas(). Fortunately, that code is stable enough, and the PPC ISA is simple
enough, that it doesn't seem like too much of a maintenance burden to just
hand-code the branch offsets, removing the need for any labels.
Note that the AIX assembler only accepts "$" for the location counter
pseudo-symbol. The usual GNU convention is "."; but it appears that all
versions of gas for PPC also accept "$", so in theory this patch will not
break any other PPC platforms.
This has been reported by a few people, but Steve Underwood gets the credit
for being the first to pursue the problem far enough to understand why it
was failing. Thanks also to Noah Misch for additional testing.
Branch
------
REL9_1_STABLE
Details
-------
http://git.postgresql.org/pg/commitdiff/14b497cfbbbbd7663edb14a0d666ed511b81bfe7
Modified Files
--------------
src/include/storage/s_lock.h | 16 ++++++++++------
1 file changed, 10 insertions(+), 6 deletions(-)
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2015-08-29 20:34:37 | pgsql: Use "mb" not the nonexistent "rmb" for pg_read_barrier() on Alph |
Previous Message | Bruce Momjian | 2015-08-28 22:31:45 | Re: Adding commit details to SGML release notes |