Re: [BUGS] Compile fails on AIX 6.1

From: Noah Misch <noah(at)leadboat(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: [BUGS] Compile fails on AIX 6.1
Date: 2015-08-29 05:42:39
Message-ID: 20150829054239.GA2556062@tornado.leadboat.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs pgsql-hackers

On Fri, Aug 28, 2015 at 09:58:46AM -0400, Tom Lane wrote:
> Noah Misch <noah(at)leadboat(dot)com> writes:
> > On Thu, Aug 27, 2015 at 10:36:46AM -0400, Tom Lane wrote:
> >> 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.

That surprised me, too. Perhaps almost everyone has used either xlc or that
IBM-provided gcc you wrote about.

> >> 2. Don't rely on local symbols in the PPC spinlock assembly code.

> > 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?

I tested a gcc 64-bit build. Consistent with your followup, "b .+12" doesn't
build, but "b $+12" builds and passes "make check". I am attaching the exact
diff I tested.

On GNU/Linux ppc, I get the same opcodes before and after the change.

Attachment Content-Type Size
no-local-asm-symbols-dollar.patch text/plain 1.4 KB

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message rongjianwei 2015-08-29 08:41:41 BUG #13596: could not start the service of postgresql 9.4.4
Previous Message it 2015-08-29 01:42:42 BUG #13595: pg_ctl.exe interferes with GPClient.exe

Browse pgsql-hackers by date

  From Date Subject
Next Message Pavel Stehule 2015-08-29 06:39:00 to_json(NULL) should to return JSON null instead NULL
Previous Message AI Rumman 2015-08-29 05:34:38 Pg_upgrade remote copy