pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Michael Paquier <michael@paquier.xyz>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Fix huge_pages on Windows
Date: Sat, 17 Sep 2022 06:40:25 +0000
Message-ID: <E1oZRV2-000iMO-Om@gemulon.postgresql.org> (raw)

Fix huge_pages on Windows

Since Windows 10 1703, it is additionally necessary to pass a flag
called FILE_MAP_LARGE_PAGES to MapViewOfFile() to enable large pages at
map time.  This flag is ignored on older versions of Windows, where
large pages should still be able to work properly without setting it.
Note that the flag would be set only for binaries that knew about it at
compile-time, which should be more or less all the Windows environments
these days.

Since 495ed0e, Windows 10 is the minimum version of Windows supported by
Postgres, making this change easy to reason about on HEAD.  Per
discussion, no backpatch is done for the moment.

Reported-by: Okano Naoki
Author: Thomas Munro
Reviewed-by: Tom Lane, Michael Paquier, Julien Rouhaud
Discussion: https://postgr.es/m/17448-0a96583a67edb1f7@postgresql.org

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/fdd8937c071e85e2b7606939fb28284f008e15d1

Modified Files
--------------
src/backend/port/win32_shmem.c | 10 +++++++++-
1 file changed, 9 insertions(+), 1 deletion(-)



Message-ID: <E1oZRV2-000iMO-Om@gemulon.postgresql.org>
Permalink:  ../E1oZRV2-000iMO-Om@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1oZRV2-000iMO-Om@gemulon.postgresql.org

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-committers@postgresql.org
  Cc: michael@paquier.xyz
  Subject: Re: pgsql: Fix huge_pages on Windows
  In-Reply-To: <E1oZRV2-000iMO-Om@gemulon.postgresql.org>
  References: <E1oZRV2-000iMO-Om@gemulon.postgresql.org>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox