Re: BUG #17448: In Windows 10, version 1703 and later, huge_pages doesn't work.

Поиск
Список
Период
Сортировка
От Michael Paquier
Тема Re: BUG #17448: In Windows 10, version 1703 and later, huge_pages doesn't work.
Дата
Msg-id Yj76HKWAxZ66SGsc@paquier.xyz
обсуждение исходный текст
Ответ на Re: BUG #17448: In Windows 10, version 1703 and later, huge_pages doesn't work.  (Thomas Munro <thomas.munro@gmail.com>)
Список pgsql-bugs
On Sun, Mar 27, 2022 at 12:07:57AM +1300, Thomas Munro wrote:
> Some question I have: is FILE_MAP_LARGE PAGES a macro?  We claim to
> support all those ancient zombie OSes like Windows 7, or maybe it's
> even XP for 11, and this has to be back-patched to 11, so we might
> need to make it conditional.  But conditional on what?  For example,
> does something like the attached work (untested)?  What happens if a <
> 1703 kernel sees this flag, does it reject it or ignore it?

Good question.  I would choose a soft approach here and not insist if
the flag was not known at compilation time, but we could also take a
more aggressive approach and hardcode a value.  Anyway, it seems to me
that the correct solution here would be to compile the code with a
PG_FILE_MAP_LARGE_PAGES that checks if the flag exists at compile
time, and we would set it at run time if we know that we are on a
version of Windows that supports it.  IsWindowsVersionOrGreater()
should be able to do the job.
--
Michael

Вложения

В списке pgsql-bugs по дате отправления:

Предыдущее
От: Thomas Munro
Дата:
Сообщение: Re: BUG #17448: In Windows 10, version 1703 and later, huge_pages doesn't work.
Следующее
От: "Vibhu Chauhan (iDEAS-ER&D)"
Дата:
Сообщение: OpenSSL v1.1.1n in postgres