Re: [PATCH] Add native windows on arm64 support
Michael Paquier <michael@paquier.xyz>
From: Michael Paquier <michael@paquier.xyz>
To: Niyas Sait <niyas.sait@linaro.org>
Cc: Andres Freund <andres@anarazel.de>, Ian Lawrence Barwick <barwick@gmail.com>, Tom Lane <tgl@sss.pgh.pa.us>, Thomas Munro <thomas.munro@gmail.com>, Julien Rouhaud <rjuju123@gmail.com>, PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Date: 2022-12-02T05:02:54Z
Lists: pgsql-hackers
On Thu, Dec 01, 2022 at 05:53:47PM +0000, Niyas Sait wrote: > I've attached a new revision of the patch (v4) and includes following > changes, > > 1. Add support for meson build system > 2. Extend MSVC scripts to handle ARM64 platform. > 3. Add arm64 definition of spin_delay function. > 4. Exclude arm_acle.h import with MSVC compiler. > > V3->V4: Add support for meson build system > V2->V3: Removed ASLR enablement and rebased on master. > V1->V2: Rebased on top of master Thanks for the updated version. I have been looking at it closely and it looks like it should be able to do the job (no arm64 machine for Windows here, sigh). I have one tiny comment about this part: - USE_ARMV8_CRC32C_WITH_RUNTIME_CHECK => undef, + USE_ARMV8_CRC32C_WITH_RUNTIME_CHECK => 1, Shouldn't we only enable this flag when we are under aarch64? Similarly, I don't think that it is a good idea to switch on USE_SSE42_CRC32C_WITH_RUNTIME_CHECK all the time. We should only set it when building under x86 and x86_64. I would also add your link [1] in s_lock.h. [1]: https://learn.microsoft.com/en-us/cpp/intrinsics/arm64-intrinsics#BarrierRestrictions -- Michael
Commits
-
MSVC: Support building for AArch64.
- a516b3f00d74 19 (unreleased) landed
-
Remove "#ifdef WIN32" guards from src/port/win32*.c
- 09eb633e1baa 17.0 cited
-
Adjust XML test case to avoid unstable behavior.
- 4ea07e7cf3c6 16.0 landed
-
Enable RandomizedBaseAddress (ASLR) on Windows with MSVC builds
- 36389a060ca6 16.0 landed