From: | Thomas Munro <thomas(dot)munro(at)gmail(dot)com> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | Peter Eisentraut <peter(dot)eisentraut(at)enterprisedb(dot)com>, Andres Freund <andres(at)anarazel(dot)de>, Andrew Dunstan <andrew(at)dunslane(dot)net>, Robert Haas <robertmhaas(at)gmail(dot)com>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: Cleaning up historical portability baggage |
Date: | 2022-08-12 21:48:24 |
Message-ID: | CA+hUKG+G=fB7Gx3wL6JHa30fq_o0h9JQwe3ff8tZO-q40467zw@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Sat, Aug 13, 2022 at 8:08 AM Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> I wrote:
> > I see that prairiedog was the only buildfarm animal failing the
> > HAVE_PPC_LWARX_MUTEX_HINT test, and it seems pretty unlikely that
> > there are any assemblers remaining in the wild that can't parse that.
>
> Actually, after further investigation and testing, I think we could
> drop the conditionality around PPC spinlock sequences altogether.
> The commentary in pg_config_manual.h claims that "some pre-POWER4
> machines" will fail on LWSYNC or LWARX with hint, but I've now
> confirmed that the oldest PPC chips in my possession (prairiedog's
> ppc7400, as well as a couple of ppc7450 machines) are all fine with
> both. Indeed, prairiedog would have been failing for some time now
> if it didn't like LWSYNC, because port/atomics/arch-ppc.h is using
> that unconditionally in some places :-(. I think we can safely
> assume that such machines no longer exist in the wild, or at least
> are not going to be used to run Postgres v16.
Yeah, POWER3 was superseded in 2001. Looking around, Linux distros
that someone might seriously run a database on already require much
more recent POWER generations to even boot up, and although there is
(for example) a separate unofficial powerpc port for Debian and of
course NetBSD and others that can target older Macs and IBM servers
etc, apparently no one has run our test suite on 21+ year old hardware
and reported that it (presumably) SIGILLs already, per that
observation (I think ports/packages that fail to work probably just
get marked broken). As for vintage Apple hardware, clearly the G4
cube was far more collectable than those weird slightly inflated
looking G3 machines :-)
I'm curious, though... if we used compiler builtins, would
-march/-mcpu etc know about this kind of thing, for people who wanted
to compile on ancient hardware, or, I guess more interestingly, newer
tricks that we haven't got around to learning about yet?
From | Date | Subject | |
---|---|---|---|
Next Message | Bruce Momjian | 2022-08-12 22:22:01 | Re: Add lasterrno setting for dir_existsfile() |
Previous Message | Tom Lane | 2022-08-12 20:08:42 | Re: Cleaning up historical portability baggage |