Commit graph

548 commits

Author SHA1 Message Date
Paul Gofman
7e8bb68f95 ntdll: Support HighestEndingAddress in NtAllocateVirtualMemoryEx(). 2022-11-10 22:00:35 +01:00
Alexandre Julliard
988d9ddbf5 ntdll: Don't inline NtCurrentTeb() in Unix libraries.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-11-09 21:10:29 +01:00
Santino Mazza
8230742016 include: Define REG_APP_HIVE and REG_PROCESS_PRIVATE. 2022-09-22 17:58:12 +02:00
Jinoh Kang
d5f5834735 include: Define atomic read/write helpers for 32-bit integers.
Based on the corresponding functions from Windows SDK header files.

Signed-off-by: Jinoh Kang <jinoh.kang.kr@gmail.com>
2022-09-15 13:47:45 +02:00
Jinoh Kang
67e4807ba5 include: Move WIN32_MEMORY_RANGE_ENTRY from winnt.h to winbase.h.
Signed-off-by: Jinoh Kang <jinoh.kang.kr@gmail.com>
2022-07-13 16:10:04 +02:00
Dmitry Timoshkov
82c30480c9 include: Fix a typo in _InterlockedXor64() intrinsic declaration.
Signed-off-by: Dmitry Timoshkov <dmitry@baikal.ru>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-07-07 19:10:02 +02:00
Alexandre Julliard
a40973f204 include: Add a number of 64-bit interlocked functions.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-06-23 10:55:06 +02:00
Jinoh Kang
253a2e2edb include: Define fast fail codes and the __fastfail() intrinsic.
Signed-off-by: Jinoh Kang <jinoh.kang.kr@gmail.com>
2022-05-31 11:43:28 +02:00
Nikolay Sivov
30f1777e87 kernelbase/tests: Add some VirtualAlloc2() tests.
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-05-20 11:37:24 +02:00
Brendan Shanks
eb55f64d52 include: Add __WINE_DEALLOC attribute and use it for allocation functions.
Signed-off-by: Brendan Shanks <bshanks@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-05-18 18:36:10 +02:00
Brendan Shanks
fd1b9afc1d include: Add __WINE_MALLOC attribute and use it for allocation functions.
Signed-off-by: Brendan Shanks <bshanks@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-05-18 18:36:10 +02:00
Brendan Shanks
1c4131ba78 include: Add WINE_ALLOC_SIZE attribute to heap_calloc().
Signed-off-by: Brendan Shanks <bshanks@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-05-04 22:10:55 +02:00
Martin Storsjö
55177136cc include: Add a declaration of _InterlockedExchangeAdd64 for MSVC mode for aarch64.
This matches the corresponding declaration for x86_64.

Signed-off-by: Martin Storsjö <martin@martin.st>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-04-25 11:37:56 +02:00
Rémi Bernon
e37740c62c include: Add ACTIVATION_CONTEXT_SECTION_WINRT_ACTIVATABLE_CLASSES declaration.
Signed-off-by: Rémi Bernon <rbernon@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-04-06 23:07:20 +02:00
Alexandre Julliard
09e233790e include: Update __MSABI_LONG definition for WINE_NO_LONG_TYPES support.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-02-25 19:02:18 +01:00
Stefan Dösinger
2f7c665999 include: Remove an incorrect InterlockedCompareExchange128 function.
Signed-off-by: Stefan Dösinger <stefan@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-02-09 18:37:33 +01:00
Stefan Dösinger
20c2e5ba28 include: InterlockedExchangeAdd64 msvc intrinsic does not exist in x86.
Signed-off-by: Stefan Dösinger <stefan@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-02-09 18:37:33 +01:00
Alexandre Julliard
f0cd33c69e include: Add support for defining Win32 types as 'long' where possible.
Add -DWINE_NO_LONG_TYPES to modules that still have compilation
warnings with long types.

Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-01-27 20:38:22 +01:00
Zebediah Figura
c5bdd938d2 include: Define InterlockedExchangeAdd64() and InterlockedExchangeAddSizeT().
Signed-off-by: Zebediah Figura <zfigura@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-01-27 11:08:14 +01:00
Alexandre Julliard
4c2b6af10f include: Define a few more intrinsic functions.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2022-01-24 21:44:06 +01:00
Mohamad Al-Jaf
e214b99ae6 include: Add namespaceapi.h file.
Required by IE11.

Signed-off-by: Mohamad Al-Jaf <mohamadaljaf@gmail.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-12-07 16:19:48 +01:00
Paul Gofman
bf8b185b91 kernelbase: Add stub for PrefetchVirtualMemory().
Signed-off-by: Paul Gofman <pgofman@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-11-24 15:37:24 +01:00
Stefan Dösinger
ad05f33d67 include: _InterlockedExchangePointer is an intrinsic on x86 in newer MSVC versions.
msvc 2019 complains that _InterlockedCompareExchangePointer and
_InterlockedExchangePointer are intrinsics and cannot be defined
even when building for x86. If I read Microsoft's header right
that started with msvc 2016.

Signed-off-by: Stefan Dösinger <stefan@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-11-08 20:40:09 +01:00
Alexandre Julliard
19d5734e20 include: Always add defines for the Interlocked* functions.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-10-14 15:28:56 +02:00
Alexandre Julliard
d4259ac8e9 include: Import specstrings.h and related headers from Mingw.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-10-13 13:39:20 +02:00
Alexandre Julliard
5d18d4df84 include: Define DECLSPEC_HIDDEN in guiddef.h if necessary.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-10-13 13:05:24 +02:00
Jacek Caban
a7ecf08040 include: Don't use DECLSPEC_HIDDEN for NTSYSAPI in Unix libs.
Signed-off-by: Jacek Caban <jacek@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-10-05 20:09:20 +02:00
Alex Henrie
3ad4def46a include: Provide a definition of NOP_FUNCTION that works on GCC.
NOP_FUNCTION is a drop-in function replacement that ignores its
arguments but also suppresses compiler warnings about them being unused.
For example, on MSVC, 0(foo, bar, baz()); or __noop(foo, bar, baz());
would suppress warnings about foo and bar being unused and not call baz
at all. Neither of those syntaxes is supported on GCC, which provides no
similar way to suppress unused variable warnings, but we can at least
allow such code to compile by defining NOP_FUNCTION to be an empty
variadic macro.

Signed-off-by: Alex Henrie <alexhenrie24@gmail.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-09-09 20:12:15 +02:00
Alexandre Julliard
7a25671c38 include: Define all the context structures on all platforms.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-05-12 16:56:27 +02:00
Alexandre Julliard
dba8d3c3d4 include: Remove context definitions for obsolete platforms.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-05-11 20:33:51 +02:00
Alexandre Julliard
2d519f5aa4 ntdll: Support MaxVersionTested in the manifest compatibility element.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-04-19 15:39:55 +02:00
Paul Gofman
084519a82b ntdll: Implement NtQuerySystemInformationEx(SystemCpuSetInformation).
Signed-off-by: Paul Gofman <pgofman@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-03-30 17:10:03 +02:00
Jacek Caban
b39b9eea39 include: Don't default to WINE_NO_NAMELESS_EXTENSION for Wine build.
Signed-off-by: Jacek Caban <jacek@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-03-22 21:48:38 +01:00
Alexandre Julliard
e5cade0ff1 ntdll: Remove DLL_WINE_PREATTACH support.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-03-02 11:01:25 +01:00
Jacek Caban
894dbe8353 include: Use GCC-style InterlockedCompareExchange128 implementation on clang in MSVC mode.
It's not yet supported on aarch64.

Signed-off-by: Jacek Caban <jacek@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-02-26 16:28:56 +01:00
Jacek Caban
4fdea7a7ca include: Add MSVC ARM version of NtCurrentTeb.
Signed-off-by: Jacek Caban <jacek@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-02-26 16:28:37 +01:00
Jacek Caban
e3708c2c79 include: Fix __dmb declaration.
Signed-off-by: Jacek Caban <jacek@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-02-26 16:28:20 +01:00
Dmitry Timoshkov
3f951cbe72 include/winnt.h: Fix arguments order for _InterlockedCompareExchange64() MSVC intrinsic.
Signed-off-by: Dmitry Timoshkov <dmitry@baikal.ru>
Signed-off-by: Jacek Caban <jacek@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-02-26 16:28:12 +01:00
Alexandre Julliard
584427fc89 server: Avoid redefining the DuplicateHandle() constants.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-02-16 21:20:47 +01:00
Alexandre Julliard
7b78896a8a include: Add a couple of access right flags.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-02-03 20:43:08 +01:00
Rémi Bernon
9138508a94 include: Define DECLSPEC_SELECTANY on MinGW.
Signed-off-by: Rémi Bernon <rbernon@codeweavers.com>
Signed-off-by: Jacek Caban <jacek@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-02-01 10:50:22 +01:00
Jacek Caban
1495ccd152 winnt.h: Fix MSVC variants of InterlockedIncrement16 and InterlockedDecrement16.
Signed-off-by: Jacek Caban <jacek@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-01-22 18:33:32 +01:00
Alexandre Julliard
e137063394 include: Add a couple of dll characteristics.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-01-21 20:46:13 +01:00
Alexandre Julliard
fc7c3b51ac ntdll: Always inline NtCurrentTeb() on ARM.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-01-21 20:46:13 +01:00
Zebediah Figura
86fc30c105 include: Add YieldProcessor().
Signed-off-by: Zebediah Figura <z.figura12@gmail.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-01-21 10:30:41 +01:00
Zebediah Figura
a3c295d4cf include: Add InterlockedIncrement16() and InterlockedDecrement16().
Signed-off-by: Zebediah Figura <z.figura12@gmail.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-01-21 10:27:49 +01:00
Zebediah Figura
0d1345ac2b include: Add InterlockedAnd().
Signed-off-by: Zebediah Figura <z.figura12@gmail.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-01-21 10:27:33 +01:00
Zebediah Figura
a952453888 include: Add MemoryBarrier().
Signed-off-by: Zebediah Figura <z.figura12@gmail.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-01-20 22:24:29 +01:00
Zebediah Figura
377f721362 include: Add InterlockedOr().
Signed-off-by: Zebediah Figura <z.figura12@gmail.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-01-20 22:23:35 +01:00
Zebediah Figura
aabdaed102 include: Use __atomic_exchange_n() for InterlockedExchange*() if possible.
Signed-off-by: Zebediah Figura <z.figura12@gmail.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2021-01-20 22:22:52 +01:00