Re: Detection of hadware feature => please do not use signal
Tom Lane <tgl@sss.pgh.pa.us>
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Thomas Munro <thomas.munro@gmail.com>
Cc: Heikki Linnakangas <hlinnaka@iki.fi>, Bastien Roucariès <rouca@debian.org>, pgsql-bugs@lists.postgresql.org
Date: 2024-11-01T04:44:35Z
Lists: pgsql-bugs
Thomas Munro <thomas.munro@gmail.com> writes: > On Fri, Nov 1, 2024 at 7:25 AM Tom Lane <tgl@sss.pgh.pa.us> wrote: >> It occurs to me to wonder whether the existing code works on Windows. >> Windows-on-ARM wasn't a thing we thought about in 2018, but it's >> a reasonable target now. > I looked into that[1] and decided that I was going to ignore it > completely, because: > [ oodles o' details ] Hmm. So it seems like we could do this: * Linux, FreeBSD, OpenBSD: do run-time test as recommended * Windows, macOS: assume that supported ARM hardware can do this * anything else: assume no hardware CRC The only thing I'd be even a bit sad about there is not having NetBSD support. Maybe we just need to research that a bit more, or maybe we have to wait for/lobby for them to do what the other BSDen have done. But in any case I'm not seeing NetBSD-on-ARM as a platform that's important enough to block movement on this, let alone anything else in the "anything else" category. An alternative to "assume no hardware CRC" could be * anything else: use the existing SIGILL test But I do sympathize with Bastien's concerns about that. regards, tom lane
Commits
-
Update configure probes for CFLAGS needed for ARM CRC instructions.
- e266a0ed67d2 17.3 landed
- 851c6ff18fd3 15.11 landed
- 5980f1884fc9 18.0 landed
- 32057a0f791e 13.19 landed
- 2fc0199a5015 14.16 landed
- 1f4aadec41b8 16.7 landed
-
Support runtime CRC feature probing on NetBSD/ARM using sysctl().
- 4570b22666dd 18.0 landed
-
Use auxv to check for CRC32 instructions on ARM.
- aac831cafa6f 18.0 landed
-
Improve our method for probing the availability of ARM CRC instructions.
- 1c72ec6f4989 11.0 cited