You've already forked wine-staging
mirror of
https://gitlab.winehq.org/wine/wine-staging.git
synced 2025-04-13 14:42:51 -07:00
Compare commits
10 Commits
Author | SHA1 | Date | |
---|---|---|---|
|
7ba8823e57 | ||
|
5a368dddd1 | ||
|
4cd3d8eba4 | ||
|
e0593972f0 | ||
|
e7a74d707b | ||
|
8b3f47c1d2 | ||
|
78f630993b | ||
|
3f86dff407 | ||
|
65b72cb912 | ||
|
32abf9fc97 |
@@ -1,4 +1,4 @@
|
||||
From a43255ead53a49837e7995ab4de0afa8e05e6334 Mon Sep 17 00:00:00 2001
|
||||
From ce164f9c292bc93ad50055bdb0a786e8a8770afa Mon Sep 17 00:00:00 2001
|
||||
From: Zebediah Figura <zfigura@codeweavers.com>
|
||||
Date: Mon, 6 Jul 2020 15:11:12 -0500
|
||||
Subject: [PATCH] server: Create eventfd file descriptors for process objects.
|
||||
@@ -49,7 +49,7 @@ index 00f9e638d83..8522d8a69ae 100644
|
||||
void esync_init(void);
|
||||
+int esync_create_fd( int initval, int flags );
|
||||
diff --git a/server/process.c b/server/process.c
|
||||
index 031c0fece13..eb073551b57 100644
|
||||
index 3c5a58b7b03..30555d516c8 100644
|
||||
--- a/server/process.c
|
||||
+++ b/server/process.c
|
||||
@@ -63,6 +63,7 @@
|
||||
@@ -77,7 +77,7 @@ index 031c0fece13..eb073551b57 100644
|
||||
no_satisfied, /* satisfied */
|
||||
no_signal, /* signal */
|
||||
no_get_fd, /* get_fd */
|
||||
@@ -688,6 +690,7 @@ struct process *create_process( int fd, struct process *parent, unsigned int fla
|
||||
@@ -689,6 +691,7 @@ struct process *create_process( int fd, struct process *parent, unsigned int fla
|
||||
process->rawinput_kbd = NULL;
|
||||
memset( &process->image_info, 0, sizeof(process->image_info) );
|
||||
list_init( &process->rawinput_entry );
|
||||
@@ -85,7 +85,7 @@ index 031c0fece13..eb073551b57 100644
|
||||
list_init( &process->kernel_object );
|
||||
list_init( &process->thread_list );
|
||||
list_init( &process->locks );
|
||||
@@ -738,6 +741,9 @@ struct process *create_process( int fd, struct process *parent, unsigned int fla
|
||||
@@ -739,6 +742,9 @@ struct process *create_process( int fd, struct process *parent, unsigned int fla
|
||||
if (!process->handles || !process->token) goto error;
|
||||
process->session_id = token_get_session_id( process->token );
|
||||
|
||||
@@ -95,7 +95,7 @@ index 031c0fece13..eb073551b57 100644
|
||||
set_fd_events( process->msg_fd, POLLIN ); /* start listening to events */
|
||||
return process;
|
||||
|
||||
@@ -786,6 +792,7 @@ static void process_destroy( struct object *obj )
|
||||
@@ -787,6 +793,7 @@ static void process_destroy( struct object *obj )
|
||||
free( process->rawinput_devices );
|
||||
free( process->dir_cache );
|
||||
free( process->image );
|
||||
@@ -103,7 +103,7 @@ index 031c0fece13..eb073551b57 100644
|
||||
}
|
||||
|
||||
/* dump a process on stdout for debugging purposes */
|
||||
@@ -803,6 +810,13 @@ static int process_signaled( struct object *obj, struct wait_queue_entry *entry
|
||||
@@ -804,6 +811,13 @@ static int process_signaled( struct object *obj, struct wait_queue_entry *entry
|
||||
return !process->running_threads;
|
||||
}
|
||||
|
||||
@@ -118,17 +118,17 @@ index 031c0fece13..eb073551b57 100644
|
||||
{
|
||||
access = default_map_access( obj, access );
|
||||
diff --git a/server/process.h b/server/process.h
|
||||
index 1e73e9d47dc..bedd8bb4586 100644
|
||||
index 96814ab7cf8..ec74ba0490a 100644
|
||||
--- a/server/process.h
|
||||
+++ b/server/process.h
|
||||
@@ -86,6 +86,7 @@ struct process
|
||||
struct list rawinput_entry; /* entry in the rawinput process list */
|
||||
struct list kernel_object; /* list of kernel object pointers */
|
||||
pe_image_info_t image_info; /* main exe image info */
|
||||
struct pe_image_info image_info; /* main exe image info */
|
||||
+ int esync_fd; /* esync file descriptor (signaled on exit) */
|
||||
};
|
||||
|
||||
/* process functions */
|
||||
--
|
||||
2.43.0
|
||||
2.45.2
|
||||
|
||||
|
@@ -1,4 +1,4 @@
|
||||
From 622de4743d9585d895bb560b4c8ac6ab01aff23f Mon Sep 17 00:00:00 2001
|
||||
From 631ec6bff81bb2e3389d0c2030364dea91719bf6 Mon Sep 17 00:00:00 2001
|
||||
From: Zebediah Figura <zfigura@codeweavers.com>
|
||||
Date: Mon, 6 Jul 2020 16:52:39 -0500
|
||||
Subject: [PATCH] ntdll: Implement NtSignalAndWaitForSingleObject().
|
||||
@@ -10,10 +10,10 @@ Subject: [PATCH] ntdll: Implement NtSignalAndWaitForSingleObject().
|
||||
3 files changed, 33 insertions(+)
|
||||
|
||||
diff --git a/dlls/ntdll/unix/esync.c b/dlls/ntdll/unix/esync.c
|
||||
index 9e980643a6e..db70e5075d1 100644
|
||||
index 6d07d8057a1..ca0ffd2b8b1 100644
|
||||
--- a/dlls/ntdll/unix/esync.c
|
||||
+++ b/dlls/ntdll/unix/esync.c
|
||||
@@ -842,6 +842,34 @@ NTSTATUS esync_wait_objects( DWORD count, const HANDLE *handles, BOOLEAN wait_an
|
||||
@@ -844,6 +844,34 @@ NTSTATUS esync_wait_objects( DWORD count, const HANDLE *handles, BOOLEAN wait_an
|
||||
return ret;
|
||||
}
|
||||
|
||||
@@ -62,11 +62,11 @@ index 8eaa79a5823..88a6d5c8975 100644
|
||||
|
||||
/* We have to synchronize on the fd cache mutex so that our calls to receive_fd
|
||||
diff --git a/dlls/ntdll/unix/sync.c b/dlls/ntdll/unix/sync.c
|
||||
index 20391617e40..12ed44f7a8e 100644
|
||||
index 943ba6c0da9..51fca406a4c 100644
|
||||
--- a/dlls/ntdll/unix/sync.c
|
||||
+++ b/dlls/ntdll/unix/sync.c
|
||||
@@ -1531,6 +1531,9 @@ NTSTATUS WINAPI NtSignalAndWaitForSingleObject( HANDLE signal, HANDLE wait,
|
||||
select_op_t select_op;
|
||||
@@ -1636,6 +1636,9 @@ NTSTATUS WINAPI NtSignalAndWaitForSingleObject( HANDLE signal, HANDLE wait,
|
||||
union select_op select_op;
|
||||
UINT flags = SELECT_INTERRUPTIBLE;
|
||||
|
||||
+ if (do_esync())
|
||||
@@ -76,5 +76,5 @@ index 20391617e40..12ed44f7a8e 100644
|
||||
|
||||
if (alertable) flags |= SELECT_ALERTABLE;
|
||||
--
|
||||
2.42.0
|
||||
2.45.2
|
||||
|
||||
|
@@ -1,211 +0,0 @@
|
||||
From d1f5c52e07bce357d3b471e839db2a6f7a72fa86 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Michael=20M=C3=BCller?= <michael@fds-team.de>
|
||||
Date: Mon, 3 Apr 2017 05:30:27 +0200
|
||||
Subject: [PATCH] ntdll: Implement HashLinks field in LDR module data.
|
||||
|
||||
---
|
||||
dlls/kernel32/tests/loader.c | 75 ++++++++++++++++++++++++++++++++++++
|
||||
dlls/ntdll/loader.c | 42 ++++++++++++++++++++
|
||||
2 files changed, 117 insertions(+)
|
||||
|
||||
diff --git a/dlls/kernel32/tests/loader.c b/dlls/kernel32/tests/loader.c
|
||||
index 9b0f8f6bff2..747dfb0afa6 100644
|
||||
--- a/dlls/kernel32/tests/loader.c
|
||||
+++ b/dlls/kernel32/tests/loader.c
|
||||
@@ -28,6 +28,7 @@
|
||||
#include "winbase.h"
|
||||
#include "winternl.h"
|
||||
#include "winnls.h"
|
||||
+#include "winuser.h"
|
||||
#include "wine/test.h"
|
||||
#include "delayloadhandler.h"
|
||||
|
||||
@@ -4651,6 +4652,79 @@ static void test_Wow64Transition(void)
|
||||
debugstr_wn(name->SectionFileName.Buffer, name->SectionFileName.Length / sizeof(WCHAR)));
|
||||
}
|
||||
|
||||
+static inline WCHAR toupperW(WCHAR c)
|
||||
+{
|
||||
+ WCHAR tmp = c;
|
||||
+ CharUpperBuffW(&tmp, 1);
|
||||
+ return tmp;
|
||||
+}
|
||||
+
|
||||
+static ULONG hash_basename(const WCHAR *basename)
|
||||
+{
|
||||
+ WORD version = MAKEWORD(NtCurrentTeb()->Peb->OSMinorVersion,
|
||||
+ NtCurrentTeb()->Peb->OSMajorVersion);
|
||||
+ ULONG hash = 0;
|
||||
+
|
||||
+ if (version >= 0x0602)
|
||||
+ {
|
||||
+ for (; *basename; basename++)
|
||||
+ hash = hash * 65599 + toupperW(*basename);
|
||||
+ }
|
||||
+ else if (version == 0x0601)
|
||||
+ {
|
||||
+ for (; *basename; basename++)
|
||||
+ hash = hash + 65599 * toupperW(*basename);
|
||||
+ }
|
||||
+ else
|
||||
+ hash = toupperW(basename[0]) - 'A';
|
||||
+
|
||||
+ return hash & 31;
|
||||
+}
|
||||
+
|
||||
+static void test_HashLinks(void)
|
||||
+{
|
||||
+ static WCHAR ntdllW[] = {'n','t','d','l','l','.','d','l','l',0};
|
||||
+ static WCHAR kernel32W[] = {'k','e','r','n','e','l','3','2','.','d','l','l',0};
|
||||
+
|
||||
+ LIST_ENTRY *hash_map, *entry, *mark;
|
||||
+ LDR_DATA_TABLE_ENTRY *module;
|
||||
+ BOOL found;
|
||||
+
|
||||
+ entry = &NtCurrentTeb()->Peb->LdrData->InLoadOrderModuleList;
|
||||
+ entry = entry->Flink;
|
||||
+
|
||||
+ module = CONTAINING_RECORD(entry, LDR_DATA_TABLE_ENTRY, InLoadOrderLinks);
|
||||
+ entry = module->HashLinks.Blink;
|
||||
+
|
||||
+ hash_map = entry - hash_basename(module->BaseDllName.Buffer);
|
||||
+
|
||||
+ mark = &hash_map[hash_basename(ntdllW)];
|
||||
+ found = FALSE;
|
||||
+ for (entry = mark->Flink; entry != mark; entry = entry->Flink)
|
||||
+ {
|
||||
+ module = CONTAINING_RECORD(entry, LDR_DATA_TABLE_ENTRY, HashLinks);
|
||||
+ if (!lstrcmpiW(module->BaseDllName.Buffer, ntdllW))
|
||||
+ {
|
||||
+ found = TRUE;
|
||||
+ break;
|
||||
+ }
|
||||
+ }
|
||||
+ ok(found, "Could not find ntdll\n");
|
||||
+
|
||||
+ mark = &hash_map[hash_basename(kernel32W)];
|
||||
+ found = FALSE;
|
||||
+ for (entry = mark->Flink; entry != mark; entry = entry->Flink)
|
||||
+ {
|
||||
+ module = CONTAINING_RECORD(entry, LDR_DATA_TABLE_ENTRY, HashLinks);
|
||||
+ if (!lstrcmpiW(module->BaseDllName.Buffer, kernel32W))
|
||||
+ {
|
||||
+ found = TRUE;
|
||||
+ break;
|
||||
+ }
|
||||
+ }
|
||||
+ ok(found, "Could not find kernel32\n");
|
||||
+}
|
||||
+
|
||||
START_TEST(loader)
|
||||
{
|
||||
int argc;
|
||||
@@ -4734,6 +4808,7 @@ START_TEST(loader)
|
||||
test_InMemoryOrderModuleList();
|
||||
test_LoadPackagedLibrary();
|
||||
test_wow64_redirection();
|
||||
+ test_HashLinks();
|
||||
test_dll_file( "ntdll.dll" );
|
||||
test_dll_file( "kernel32.dll" );
|
||||
test_dll_file( "advapi32.dll" );
|
||||
diff --git a/dlls/ntdll/loader.c b/dlls/ntdll/loader.c
|
||||
index 0ed37ad390c..94610a82a65 100644
|
||||
--- a/dlls/ntdll/loader.c
|
||||
+++ b/dlls/ntdll/loader.c
|
||||
@@ -128,6 +128,9 @@ struct file_id
|
||||
BYTE ObjectId[16];
|
||||
};
|
||||
|
||||
+#define HASH_MAP_SIZE 32
|
||||
+static LIST_ENTRY hash_table[HASH_MAP_SIZE];
|
||||
+
|
||||
/* internal representation of loaded modules */
|
||||
typedef struct _wine_modref
|
||||
{
|
||||
@@ -603,6 +606,33 @@ static int base_address_compare( const void *key, const RTL_BALANCED_NODE *entry
|
||||
return 0;
|
||||
}
|
||||
|
||||
+/*************************************************************************
|
||||
+ * hash_basename
|
||||
+ *
|
||||
+ * Calculates the bucket index of a dll using the basename.
|
||||
+ */
|
||||
+static ULONG hash_basename(const WCHAR *basename)
|
||||
+{
|
||||
+ WORD version = MAKEWORD(NtCurrentTeb()->Peb->OSMinorVersion,
|
||||
+ NtCurrentTeb()->Peb->OSMajorVersion);
|
||||
+ ULONG hash = 0;
|
||||
+
|
||||
+ if (version >= 0x0602)
|
||||
+ {
|
||||
+ for (; *basename; basename++)
|
||||
+ hash = hash * 65599 + towupper(*basename);
|
||||
+ }
|
||||
+ else if (version == 0x0601)
|
||||
+ {
|
||||
+ for (; *basename; basename++)
|
||||
+ hash = hash + 65599 * towupper(*basename);
|
||||
+ }
|
||||
+ else
|
||||
+ hash = towupper(basename[0]) - 'A';
|
||||
+
|
||||
+ return hash & (HASH_MAP_SIZE-1);
|
||||
+}
|
||||
+
|
||||
/*************************************************************************
|
||||
* get_modref
|
||||
*
|
||||
@@ -1599,9 +1629,14 @@ static WINE_MODREF *alloc_module( HMODULE hModule, const UNICODE_STRING *nt_name
|
||||
&wm->ldr.InLoadOrderLinks);
|
||||
InsertTailList(&NtCurrentTeb()->Peb->LdrData->InMemoryOrderModuleList,
|
||||
&wm->ldr.InMemoryOrderLinks);
|
||||
+ InsertTailList(&hash_table[hash_basename(wm->ldr.BaseDllName.Buffer)],
|
||||
+ &wm->ldr.HashLinks);
|
||||
if (rtl_rb_tree_put( &base_address_index_tree, wm->ldr.DllBase, &wm->ldr.BaseAddressIndexNode, base_address_compare ))
|
||||
ERR( "rtl_rb_tree_put failed.\n" );
|
||||
+
|
||||
/* wait until init is called for inserting into InInitializationOrderModuleList */
|
||||
+ wm->ldr.InInitializationOrderLinks.Flink = NULL;
|
||||
+ wm->ldr.InInitializationOrderLinks.Blink = NULL;
|
||||
|
||||
if (!(nt->OptionalHeader.DllCharacteristics & IMAGE_DLLCHARACTERISTICS_NX_COMPAT))
|
||||
{
|
||||
@@ -2299,6 +2334,7 @@ static NTSTATUS build_module( LPCWSTR load_path, const UNICODE_STRING *nt_name,
|
||||
/* the module has only be inserted in the load & memory order lists */
|
||||
RemoveEntryList(&wm->ldr.InLoadOrderLinks);
|
||||
RemoveEntryList(&wm->ldr.InMemoryOrderLinks);
|
||||
+ RemoveEntryList(&wm->ldr.HashLinks);
|
||||
RtlRbRemoveNode( &base_address_index_tree, &wm->ldr.BaseAddressIndexNode );
|
||||
|
||||
/* FIXME: there are several more dangling references
|
||||
@@ -3963,6 +3999,7 @@ static void free_modref( WINE_MODREF *wm )
|
||||
|
||||
RemoveEntryList(&wm->ldr.InLoadOrderLinks);
|
||||
RemoveEntryList(&wm->ldr.InMemoryOrderLinks);
|
||||
+ RemoveEntryList(&wm->ldr.HashLinks);
|
||||
RtlRbRemoveNode( &base_address_index_tree, &wm->ldr.BaseAddressIndexNode );
|
||||
if (wm->ldr.InInitializationOrderLinks.Flink)
|
||||
RemoveEntryList(&wm->ldr.InInitializationOrderLinks);
|
||||
@@ -4384,6 +4421,7 @@ void loader_init( CONTEXT *context, void **entry )
|
||||
ANSI_STRING ctrl_routine = RTL_CONSTANT_STRING( "CtrlRoutine" );
|
||||
WINE_MODREF *kernel32;
|
||||
PEB *peb = NtCurrentTeb()->Peb;
|
||||
+ unsigned int i;
|
||||
|
||||
peb->LdrData = &ldr;
|
||||
peb->FastPebLock = &peb_lock;
|
||||
@@ -4402,6 +4440,10 @@ void loader_init( CONTEXT *context, void **entry )
|
||||
if (!(tls_dirs = RtlAllocateHeap( GetProcessHeap(), HEAP_ZERO_MEMORY, tls_module_count * sizeof(*tls_dirs) )))
|
||||
NtTerminateProcess( GetCurrentProcess(), STATUS_NO_MEMORY );
|
||||
|
||||
+ /* initialize hash table */
|
||||
+ for (i = 0; i < HASH_MAP_SIZE; i++)
|
||||
+ InitializeListHead( &hash_table[i] );
|
||||
+
|
||||
init_user_process_params();
|
||||
load_global_options();
|
||||
version_init();
|
||||
--
|
||||
2.45.2
|
||||
|
@@ -1,34 +0,0 @@
|
||||
From ddd05cd2289136f417a8de210aef68a076da8399 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Michael=20M=C3=BCller?= <michael@fds-team.de>
|
||||
Date: Mon, 3 Apr 2017 05:56:19 +0200
|
||||
Subject: [PATCH] ntdll: Use HashLinks when searching for a dll using the
|
||||
basename.
|
||||
|
||||
---
|
||||
dlls/ntdll/loader.c | 6 +++---
|
||||
1 file changed, 3 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/dlls/ntdll/loader.c b/dlls/ntdll/loader.c
|
||||
index 3e275e8c409..7f4aa8eba06 100644
|
||||
--- a/dlls/ntdll/loader.c
|
||||
+++ b/dlls/ntdll/loader.c
|
||||
@@ -543,13 +543,13 @@ static WINE_MODREF *find_basename_module( LPCWSTR name )
|
||||
if (cached_modref && RtlEqualUnicodeString( &name_str, &cached_modref->ldr.BaseDllName, TRUE ))
|
||||
return cached_modref;
|
||||
|
||||
- mark = &NtCurrentTeb()->Peb->LdrData->InLoadOrderModuleList;
|
||||
+ mark = &hash_table[hash_basename(name)];
|
||||
for (entry = mark->Flink; entry != mark; entry = entry->Flink)
|
||||
{
|
||||
- WINE_MODREF *mod = CONTAINING_RECORD(entry, WINE_MODREF, ldr.InLoadOrderLinks);
|
||||
+ WINE_MODREF *mod = CONTAINING_RECORD(entry, WINE_MODREF, ldr.HashLinks);
|
||||
if (RtlEqualUnicodeString( &name_str, &mod->ldr.BaseDllName, TRUE ) && !mod->system)
|
||||
{
|
||||
- cached_modref = CONTAINING_RECORD(mod, WINE_MODREF, ldr);
|
||||
+ cached_modref = CONTAINING_RECORD(&mod->ldr, WINE_MODREF, ldr);
|
||||
return cached_modref;
|
||||
}
|
||||
}
|
||||
--
|
||||
2.35.1
|
||||
|
@@ -1 +0,0 @@
|
||||
Fixes: Implement and use hash links when looking up LDR module
|
@@ -1,4 +1,4 @@
|
||||
From bdbc1c90697424373a5248cf6c2bda589785bd37 Mon Sep 17 00:00:00 2001
|
||||
From a6d2b52c9461723c39982237512d29de0154b5ff Mon Sep 17 00:00:00 2001
|
||||
From: "Erich E. Hoover" <erich.e.hoover@gmail.com>
|
||||
Date: Thu, 16 Jan 2014 20:56:49 -0700
|
||||
Subject: [PATCH] ntdll: Add support for creating reparse points.
|
||||
@@ -13,10 +13,10 @@ Signed-off-by: Erich E. Hoover <erich.e.hoover@gmail.com>
|
||||
5 files changed, 451 insertions(+), 19 deletions(-)
|
||||
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index d380c66ff40..4314be5553c 100644
|
||||
index 3bde1e448be..52537e7056c 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -2078,6 +2078,8 @@ AC_CHECK_FUNCS(\
|
||||
@@ -2081,6 +2081,8 @@ AC_CHECK_FUNCS(\
|
||||
posix_fallocate \
|
||||
prctl \
|
||||
sched_yield \
|
||||
@@ -39,7 +39,7 @@ index 37bd6c86e31..f9a15d28ed2 100644
|
||||
EXTRADLLFLAGS = -nodefaultlibs
|
||||
i386_EXTRADLLFLAGS = -Wl,--image-base,0x7bc00000
|
||||
diff --git a/dlls/ntdll/tests/file.c b/dlls/ntdll/tests/file.c
|
||||
index 7d3618a3804..148b6058cee 100644
|
||||
index 95bd1c37cac..25cac61317b 100644
|
||||
--- a/dlls/ntdll/tests/file.c
|
||||
+++ b/dlls/ntdll/tests/file.c
|
||||
@@ -38,6 +38,7 @@
|
||||
@@ -50,7 +50,7 @@ index 7d3618a3804..148b6058cee 100644
|
||||
|
||||
#ifndef IO_COMPLETION_ALL_ACCESS
|
||||
#define IO_COMPLETION_ALL_ACCESS 0x001F0003
|
||||
@@ -5863,32 +5864,154 @@ static void test_mailslot_name(void)
|
||||
@@ -5906,32 +5907,154 @@ static void test_mailslot_name(void)
|
||||
CloseHandle( device );
|
||||
}
|
||||
|
||||
@@ -221,8 +221,8 @@ index 7d3618a3804..148b6058cee 100644
|
||||
+ RemoveDirectoryW(path);
|
||||
}
|
||||
|
||||
START_TEST(file)
|
||||
@@ -5969,6 +6092,6 @@ START_TEST(file)
|
||||
static void test_set_io_completion_ex(void)
|
||||
@@ -6071,6 +6194,6 @@ START_TEST(file)
|
||||
test_ioctl();
|
||||
test_query_ea();
|
||||
test_flush_buffers_file();
|
||||
@@ -231,7 +231,7 @@ index 7d3618a3804..148b6058cee 100644
|
||||
+ test_mailslot_name();
|
||||
}
|
||||
diff --git a/dlls/ntdll/unix/file.c b/dlls/ntdll/unix/file.c
|
||||
index ca95dd347eb..ac4de149455 100644
|
||||
index 9da53339ff0..34121c7d08a 100644
|
||||
--- a/dlls/ntdll/unix/file.c
|
||||
+++ b/dlls/ntdll/unix/file.c
|
||||
@@ -36,6 +36,8 @@
|
||||
@@ -243,7 +243,7 @@ index ca95dd347eb..ac4de149455 100644
|
||||
#include <limits.h>
|
||||
#include <unistd.h>
|
||||
#ifdef HAVE_MNTENT_H
|
||||
@@ -124,6 +126,7 @@
|
||||
@@ -121,6 +123,7 @@
|
||||
#include "wine/list.h"
|
||||
#include "wine/debug.h"
|
||||
#include "unix_private.h"
|
||||
@@ -251,7 +251,7 @@ index ca95dd347eb..ac4de149455 100644
|
||||
|
||||
WINE_DEFAULT_DEBUG_CHANNEL(file);
|
||||
WINE_DECLARE_DEBUG_CHANNEL(winediag);
|
||||
@@ -135,6 +138,12 @@ WINE_DECLARE_DEBUG_CHANNEL(winediag);
|
||||
@@ -132,6 +135,12 @@ WINE_DECLARE_DEBUG_CHANNEL(winediag);
|
||||
#undef EXT2_IOC_GETFLAGS
|
||||
#undef EXT4_CASEFOLD_FL
|
||||
|
||||
@@ -264,7 +264,7 @@ index ca95dd347eb..ac4de149455 100644
|
||||
#ifdef linux
|
||||
|
||||
/* We want the real kernel dirent structure, not the libc one */
|
||||
@@ -246,6 +255,95 @@ static const BOOL is_case_sensitive = FALSE;
|
||||
@@ -243,6 +252,95 @@ static const BOOL is_case_sensitive = FALSE;
|
||||
static pthread_mutex_t dir_mutex = PTHREAD_MUTEX_INITIALIZER;
|
||||
static pthread_mutex_t mnt_mutex = PTHREAD_MUTEX_INITIALIZER;
|
||||
|
||||
@@ -360,7 +360,7 @@ index ca95dd347eb..ac4de149455 100644
|
||||
/* check if a given Unicode char is OK in a DOS short name */
|
||||
static inline BOOL is_invalid_dos_char( WCHAR ch )
|
||||
{
|
||||
@@ -1644,6 +1742,28 @@ static int parse_samba_dos_attrib_data( char *data, int len )
|
||||
@@ -1641,6 +1739,28 @@ static int parse_samba_dos_attrib_data( char *data, int len )
|
||||
}
|
||||
|
||||
|
||||
@@ -389,7 +389,7 @@ index ca95dd347eb..ac4de149455 100644
|
||||
static BOOL fd_is_mount_point( int fd, const struct stat *st )
|
||||
{
|
||||
struct stat parent;
|
||||
@@ -3418,6 +3538,181 @@ done:
|
||||
@@ -3415,6 +3535,181 @@ done:
|
||||
}
|
||||
|
||||
|
||||
@@ -571,7 +571,7 @@ index ca95dd347eb..ac4de149455 100644
|
||||
/******************************************************************************
|
||||
* lookup_unix_name
|
||||
*
|
||||
@@ -6249,6 +6544,13 @@ NTSTATUS WINAPI NtFsControlFile( HANDLE handle, HANDLE event, PIO_APC_ROUTINE ap
|
||||
@@ -6250,6 +6545,13 @@ NTSTATUS WINAPI NtFsControlFile( HANDLE handle, HANDLE event, PIO_APC_ROUTINE ap
|
||||
break;
|
||||
}
|
||||
|
||||
|
@@ -1,4 +1,4 @@
|
||||
From 48124df7efbda048d841899cc9bde77a3684622b Mon Sep 17 00:00:00 2001
|
||||
From 2c353379e4e6da08174cc6bc7b0fd95f26c2d16e Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?R=C3=A9mi=20Bernon?= <rbernon@codeweavers.com>
|
||||
Date: Mon, 26 Aug 2019 14:37:20 +0200
|
||||
Subject: [PATCH] server: Add send_hardware_message flags for rawinput
|
||||
@@ -6,15 +6,15 @@ Subject: [PATCH] server: Add send_hardware_message flags for rawinput
|
||||
|
||||
---
|
||||
include/ntuser.h | 4 ++++
|
||||
server/protocol.def | 3 +--
|
||||
server/queue.c | 20 ++++++++++++--------
|
||||
3 files changed, 17 insertions(+), 10 deletions(-)
|
||||
server/protocol.def | 5 ++---
|
||||
server/queue.c | 26 +++++++++++++++-----------
|
||||
3 files changed, 21 insertions(+), 14 deletions(-)
|
||||
|
||||
diff --git a/include/ntuser.h b/include/ntuser.h
|
||||
index bd11567290f..c75e691b4ee 100644
|
||||
index 3d981927395..f20945f4122 100644
|
||||
--- a/include/ntuser.h
|
||||
+++ b/include/ntuser.h
|
||||
@@ -1480,6 +1480,10 @@ struct hid_packet
|
||||
@@ -1613,6 +1613,10 @@ struct hid_packet
|
||||
|
||||
C_ASSERT(sizeof(struct hid_packet) == offsetof(struct hid_packet, data[0]));
|
||||
|
||||
@@ -26,19 +26,21 @@ index bd11567290f..c75e691b4ee 100644
|
||||
{
|
||||
UINT flags;
|
||||
diff --git a/server/protocol.def b/server/protocol.def
|
||||
index 222a283477a..320b87775b7 100644
|
||||
index ae53a65db64..1fcace0d131 100644
|
||||
--- a/server/protocol.def
|
||||
+++ b/server/protocol.def
|
||||
@@ -2208,7 +2208,7 @@ enum message_type
|
||||
@@ -2262,8 +2262,8 @@ enum message_type
|
||||
/* Send a hardware message to a thread queue */
|
||||
@REQ(send_hardware_message)
|
||||
user_handle_t win; /* window handle */
|
||||
hw_input_t input; /* input data */
|
||||
- union hw_input input; /* input data */
|
||||
- unsigned int flags; /* flags (see below) */
|
||||
+ union hw_input input; /* input data */
|
||||
+ unsigned int flags; /* flags (see ntuser.h) */
|
||||
VARARG(report,bytes); /* HID report data */
|
||||
@REPLY
|
||||
int wait; /* do we need to wait for a reply? */
|
||||
@@ -2217,7 +2217,6 @@ enum message_type
|
||||
@@ -2272,7 +2272,6 @@ enum message_type
|
||||
int new_x; /* new cursor position */
|
||||
int new_y;
|
||||
@END
|
||||
@@ -47,19 +49,21 @@ index 222a283477a..320b87775b7 100644
|
||||
|
||||
/* Get a message from the current queue */
|
||||
diff --git a/server/queue.c b/server/queue.c
|
||||
index 784443ce955..0db4faab193 100644
|
||||
index 94169a57db6..9695eceff28 100644
|
||||
--- a/server/queue.c
|
||||
+++ b/server/queue.c
|
||||
@@ -2056,7 +2056,7 @@ static void dispatch_rawinput_message( struct desktop *desktop, struct rawinput_
|
||||
@@ -2243,8 +2243,8 @@ static void dispatch_rawinput_message( struct desktop *desktop, struct rawinput_
|
||||
}
|
||||
|
||||
/* queue a hardware message for a mouse event */
|
||||
static int queue_mouse_message( struct desktop *desktop, user_handle_t win, const hw_input_t *input,
|
||||
-static int queue_mouse_message( struct desktop *desktop, user_handle_t win, const union hw_input *input,
|
||||
- unsigned int origin, struct msg_queue *sender )
|
||||
+static int queue_mouse_message( struct desktop *desktop, user_handle_t win, const union hw_input *input,
|
||||
+ unsigned int origin, struct msg_queue *sender, unsigned int send_flags )
|
||||
{
|
||||
const desktop_shm_t *desktop_shm = desktop->shared;
|
||||
struct hardware_msg_data *msg_data;
|
||||
@@ -2117,7 +2117,7 @@ static int queue_mouse_message( struct desktop *desktop, user_handle_t win, cons
|
||||
@@ -2305,7 +2305,7 @@ static int queue_mouse_message( struct desktop *desktop, user_handle_t win, cons
|
||||
y = desktop_shm->cursor.y;
|
||||
}
|
||||
|
||||
@@ -68,7 +72,7 @@ index 784443ce955..0db4faab193 100644
|
||||
{
|
||||
memset( &raw_msg, 0, sizeof(raw_msg) );
|
||||
raw_msg.foreground = foreground;
|
||||
@@ -2132,6 +2132,8 @@ static int queue_mouse_message( struct desktop *desktop, user_handle_t win, cons
|
||||
@@ -2320,6 +2320,8 @@ static int queue_mouse_message( struct desktop *desktop, user_handle_t win, cons
|
||||
release_object( foreground );
|
||||
}
|
||||
|
||||
@@ -77,11 +81,13 @@ index 784443ce955..0db4faab193 100644
|
||||
for (i = 0; i < ARRAY_SIZE( messages ); i++)
|
||||
{
|
||||
if (!messages[i]) continue;
|
||||
@@ -2162,14 +2164,14 @@ static int queue_mouse_message( struct desktop *desktop, user_handle_t win, cons
|
||||
@@ -2349,15 +2351,15 @@ static int queue_mouse_message( struct desktop *desktop, user_handle_t win, cons
|
||||
return wait;
|
||||
}
|
||||
|
||||
static int queue_keyboard_message( struct desktop *desktop, user_handle_t win, const hw_input_t *input,
|
||||
-static int queue_keyboard_message( struct desktop *desktop, user_handle_t win, const union hw_input *input,
|
||||
- unsigned int origin, struct msg_queue *sender, int repeat );
|
||||
+static int queue_keyboard_message( struct desktop *desktop, user_handle_t win, const union hw_input *input,
|
||||
+ unsigned int origin, struct msg_queue *sender, int repeat, unsigned int send_flags);
|
||||
|
||||
static void key_repeat_timeout( void *private )
|
||||
@@ -94,16 +100,18 @@ index 784443ce955..0db4faab193 100644
|
||||
}
|
||||
|
||||
static void stop_key_repeat( struct desktop *desktop )
|
||||
@@ -2182,7 +2184,7 @@ static void stop_key_repeat( struct desktop *desktop )
|
||||
@@ -2369,8 +2371,8 @@ static void stop_key_repeat( struct desktop *desktop )
|
||||
}
|
||||
|
||||
/* queue a hardware message for a keyboard event */
|
||||
static int queue_keyboard_message( struct desktop *desktop, user_handle_t win, const hw_input_t *input,
|
||||
-static int queue_keyboard_message( struct desktop *desktop, user_handle_t win, const union hw_input *input,
|
||||
- unsigned int origin, struct msg_queue *sender, int repeat )
|
||||
+static int queue_keyboard_message( struct desktop *desktop, user_handle_t win, const union hw_input *input,
|
||||
+ unsigned int origin, struct msg_queue *sender, int repeat, unsigned int send_flags )
|
||||
{
|
||||
const desktop_shm_t *desktop_shm = desktop->shared;
|
||||
struct hw_msg_source source = { IMDT_KEYBOARD, origin };
|
||||
@@ -2305,7 +2307,7 @@ static int queue_keyboard_message( struct desktop *desktop, user_handle_t win, c
|
||||
@@ -2493,7 +2495,7 @@ static int queue_keyboard_message( struct desktop *desktop, user_handle_t win, c
|
||||
}
|
||||
}
|
||||
|
||||
@@ -112,7 +120,7 @@ index 784443ce955..0db4faab193 100644
|
||||
{
|
||||
struct rawinput_message raw_msg = {0};
|
||||
raw_msg.foreground = foreground;
|
||||
@@ -2320,6 +2322,8 @@ static int queue_keyboard_message( struct desktop *desktop, user_handle_t win, c
|
||||
@@ -2508,6 +2510,8 @@ static int queue_keyboard_message( struct desktop *desktop, user_handle_t win, c
|
||||
release_object( foreground );
|
||||
}
|
||||
|
||||
@@ -121,7 +129,7 @@ index 784443ce955..0db4faab193 100644
|
||||
if (!(msg = alloc_hardware_message( input->kbd.info, source, time, 0 ))) return 0;
|
||||
msg_data = msg->data;
|
||||
|
||||
@@ -3075,10 +3079,10 @@ DECL_HANDLER(send_hardware_message)
|
||||
@@ -3294,10 +3298,10 @@ DECL_HANDLER(send_hardware_message)
|
||||
switch (req->input.type)
|
||||
{
|
||||
case INPUT_MOUSE:
|
||||
@@ -135,5 +143,5 @@ index 784443ce955..0db4faab193 100644
|
||||
case INPUT_HARDWARE:
|
||||
queue_custom_hardware_message( desktop, req->win, origin, &req->input );
|
||||
--
|
||||
2.43.0
|
||||
2.45.2
|
||||
|
||||
|
@@ -1,4 +1,4 @@
|
||||
From 03ca1a439ace6f14b8551a5e9a83dec83872577f Mon Sep 17 00:00:00 2001
|
||||
From 14dc22e926e64a1ab824278ba245caabe7e1449b Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?R=C3=A9mi=20Bernon?= <rbernon@codeweavers.com>
|
||||
Date: Thu, 19 Dec 2019 22:34:44 +0100
|
||||
Subject: [PATCH] winex11: Keep track of mouse device and pointer button
|
||||
@@ -17,10 +17,10 @@ Original patch by Andrew Eikum <aeikum@codeweavers.com>.
|
||||
5 files changed, 114 insertions(+), 6 deletions(-)
|
||||
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index d7d8411c1a3..720e016d0af 100644
|
||||
index 51b453b9af4..7dcc220aecb 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -1203,6 +1203,7 @@ then
|
||||
@@ -1209,6 +1209,7 @@ then
|
||||
|
||||
dnl *** All of the following tests require X11/Xlib.h
|
||||
AC_CHECK_HEADERS([X11/extensions/shape.h \
|
||||
@@ -29,7 +29,7 @@ index d7d8411c1a3..720e016d0af 100644
|
||||
X11/extensions/XShm.h \
|
||||
X11/extensions/Xfixes.h \
|
||||
diff --git a/dlls/winex11.drv/keyboard.c b/dlls/winex11.drv/keyboard.c
|
||||
index bb5bf6220e1..af0bdb54205 100644
|
||||
index 7b7371ed696..fdca9d67e0b 100644
|
||||
--- a/dlls/winex11.drv/keyboard.c
|
||||
+++ b/dlls/winex11.drv/keyboard.c
|
||||
@@ -1820,11 +1820,7 @@ BOOL X11DRV_ActivateKeyboardLayout(HKL hkl, UINT flags)
|
||||
@@ -71,7 +71,7 @@ index bb5bf6220e1..af0bdb54205 100644
|
||||
/***********************************************************************
|
||||
* VkKeyScanEx (X11DRV.@)
|
||||
diff --git a/dlls/winex11.drv/mouse.c b/dlls/winex11.drv/mouse.c
|
||||
index e513e302351..23ceb5eb00a 100644
|
||||
index 501a8e5ebc2..ad8b86c1e61 100644
|
||||
--- a/dlls/winex11.drv/mouse.c
|
||||
+++ b/dlls/winex11.drv/mouse.c
|
||||
@@ -31,6 +31,9 @@
|
||||
@@ -175,7 +175,7 @@ index e513e302351..23ceb5eb00a 100644
|
||||
#ifdef HAVE_X11_EXTENSIONS_XINPUT2_H
|
||||
/***********************************************************************
|
||||
* update_relative_valuators
|
||||
@@ -1671,6 +1751,8 @@ static BOOL X11DRV_DeviceChanged( XGenericEventCookie *xev )
|
||||
@@ -1664,6 +1744,8 @@ static BOOL X11DRV_DeviceChanged( XGenericEventCookie *xev )
|
||||
|
||||
if (event->deviceid != data->xinput2_pointer) return FALSE;
|
||||
update_relative_valuators( event->classes, event->num_classes );
|
||||
@@ -184,7 +184,7 @@ index e513e302351..23ceb5eb00a 100644
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
@@ -1819,7 +1901,7 @@ static BOOL X11DRV_TouchEvent( HWND hwnd, XGenericEventCookie *xev )
|
||||
@@ -1812,7 +1894,7 @@ static BOOL X11DRV_TouchEvent( HWND hwnd, XGenericEventCookie *xev )
|
||||
*/
|
||||
void x11drv_xinput2_load(void)
|
||||
{
|
||||
@@ -193,7 +193,7 @@ index e513e302351..23ceb5eb00a 100644
|
||||
int event, error;
|
||||
void *libxi_handle = dlopen( SONAME_LIBXI, RTLD_NOW );
|
||||
|
||||
@@ -1835,11 +1917,20 @@ void x11drv_xinput2_load(void)
|
||||
@@ -1828,11 +1910,20 @@ void x11drv_xinput2_load(void)
|
||||
return; \
|
||||
}
|
||||
|
||||
@@ -215,19 +215,19 @@ index e513e302351..23ceb5eb00a 100644
|
||||
|
||||
xinput2_available = XQueryExtension( gdi_display, "XInputExtension", &xinput2_opcode, &event, &error );
|
||||
diff --git a/dlls/winex11.drv/x11drv.h b/dlls/winex11.drv/x11drv.h
|
||||
index 1e669f9fe61..a6cfd5a483e 100644
|
||||
index 625e37eecc5..fbc7efc4ffa 100644
|
||||
--- a/dlls/winex11.drv/x11drv.h
|
||||
+++ b/dlls/winex11.drv/x11drv.h
|
||||
@@ -687,6 +687,7 @@ extern void reapply_cursor_clipping(void);
|
||||
@@ -701,6 +701,7 @@ extern void reapply_cursor_clipping(void);
|
||||
extern void ungrab_clipping_window(void);
|
||||
extern void move_resize_window( HWND hwnd, int dir );
|
||||
extern void move_resize_window( HWND hwnd, int dir, POINT pos );
|
||||
extern void X11DRV_InitKeyboard( Display *display );
|
||||
+extern void X11DRV_InitMouse( Display *display );
|
||||
extern BOOL X11DRV_ProcessEvents( DWORD mask );
|
||||
extern HWND *build_hwnd_list(void);
|
||||
|
||||
diff --git a/dlls/winex11.drv/x11drv_main.c b/dlls/winex11.drv/x11drv_main.c
|
||||
index abc14032c61..d95c4761529 100644
|
||||
index 7f05acccea6..40157645c53 100644
|
||||
--- a/dlls/winex11.drv/x11drv_main.c
|
||||
+++ b/dlls/winex11.drv/x11drv_main.c
|
||||
@@ -672,6 +672,7 @@ static NTSTATUS x11drv_init( void *arg )
|
||||
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@@ -1,478 +0,0 @@
|
||||
From 9f1222c0cc241c9a3256403a637d16ffd26587fc Mon Sep 17 00:00:00 2001
|
||||
From: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
|
||||
Date: Thu, 24 Oct 2024 07:08:51 +1100
|
||||
Subject: [PATCH] Updated vkd3d to 91701f83035c0d67d1ab917e0f6b73f91e8583d4.
|
||||
|
||||
---
|
||||
libs/vkd3d/libs/vkd3d-shader/d3dbc.c | 12 --
|
||||
libs/vkd3d/libs/vkd3d-shader/dxil.c | 15 ---
|
||||
libs/vkd3d/libs/vkd3d-shader/tpf.c | 12 --
|
||||
.../libs/vkd3d-shader/vkd3d_shader_main.c | 105 +++++++++---------
|
||||
.../libs/vkd3d-shader/vkd3d_shader_private.h | 6 -
|
||||
libs/vkd3d/libs/vkd3d/device.c | 65 ++++++-----
|
||||
libs/vkd3d/libs/vkd3d/resource.c | 14 ++-
|
||||
libs/vkd3d/libs/vkd3d/state.c | 21 ++--
|
||||
libs/vkd3d/libs/vkd3d/vkd3d_private.h | 23 ++--
|
||||
9 files changed, 123 insertions(+), 150 deletions(-)
|
||||
|
||||
diff --git a/libs/vkd3d/libs/vkd3d-shader/d3dbc.c b/libs/vkd3d/libs/vkd3d-shader/d3dbc.c
|
||||
index bbebf86e6d5..9e2eacbcfa6 100644
|
||||
--- a/libs/vkd3d/libs/vkd3d-shader/d3dbc.c
|
||||
+++ b/libs/vkd3d/libs/vkd3d-shader/d3dbc.c
|
||||
@@ -1391,18 +1391,6 @@ int d3dbc_parse(const struct vkd3d_shader_compile_info *compile_info, uint64_t c
|
||||
|
||||
if (ret < 0)
|
||||
{
|
||||
- WARN("Failed to parse shader.\n");
|
||||
- vsir_program_cleanup(program);
|
||||
- return ret;
|
||||
- }
|
||||
-
|
||||
- if ((ret = vkd3d_shader_parser_validate(&sm1.p, config_flags)) < 0)
|
||||
- {
|
||||
- WARN("Failed to validate shader after parsing, ret %d.\n", ret);
|
||||
-
|
||||
- if (TRACE_ON())
|
||||
- vsir_program_trace(program);
|
||||
-
|
||||
vsir_program_cleanup(program);
|
||||
return ret;
|
||||
}
|
||||
diff --git a/libs/vkd3d/libs/vkd3d-shader/dxil.c b/libs/vkd3d/libs/vkd3d-shader/dxil.c
|
||||
index 570af5eca5a..3235a278769 100644
|
||||
--- a/libs/vkd3d/libs/vkd3d-shader/dxil.c
|
||||
+++ b/libs/vkd3d/libs/vkd3d-shader/dxil.c
|
||||
@@ -10603,22 +10603,7 @@ int dxil_parse(const struct vkd3d_shader_compile_info *compile_info, uint64_t co
|
||||
vkd3d_free(byte_code);
|
||||
|
||||
if (ret < 0)
|
||||
- {
|
||||
- WARN("Failed to parse shader.\n");
|
||||
- return ret;
|
||||
- }
|
||||
-
|
||||
- if ((ret = vkd3d_shader_parser_validate(&sm6.p, config_flags)) < 0)
|
||||
- {
|
||||
- WARN("Failed to validate shader after parsing, ret %d.\n", ret);
|
||||
-
|
||||
- if (TRACE_ON())
|
||||
- vsir_program_trace(program);
|
||||
-
|
||||
- sm6_parser_cleanup(&sm6);
|
||||
- vsir_program_cleanup(program);
|
||||
return ret;
|
||||
- }
|
||||
|
||||
sm6_parser_cleanup(&sm6);
|
||||
|
||||
diff --git a/libs/vkd3d/libs/vkd3d-shader/tpf.c b/libs/vkd3d/libs/vkd3d-shader/tpf.c
|
||||
index f96d300676c..c937b245559 100644
|
||||
--- a/libs/vkd3d/libs/vkd3d-shader/tpf.c
|
||||
+++ b/libs/vkd3d/libs/vkd3d-shader/tpf.c
|
||||
@@ -2964,22 +2964,10 @@ int tpf_parse(const struct vkd3d_shader_compile_info *compile_info, uint64_t con
|
||||
|
||||
if (sm4.p.failed)
|
||||
{
|
||||
- WARN("Failed to parse shader.\n");
|
||||
vsir_program_cleanup(program);
|
||||
return VKD3D_ERROR_INVALID_SHADER;
|
||||
}
|
||||
|
||||
- if ((ret = vkd3d_shader_parser_validate(&sm4.p, config_flags)) < 0)
|
||||
- {
|
||||
- WARN("Failed to validate shader after parsing, ret %d.\n", ret);
|
||||
-
|
||||
- if (TRACE_ON())
|
||||
- vsir_program_trace(program);
|
||||
-
|
||||
- vsir_program_cleanup(program);
|
||||
- return ret;
|
||||
- }
|
||||
-
|
||||
return VKD3D_OK;
|
||||
}
|
||||
|
||||
diff --git a/libs/vkd3d/libs/vkd3d-shader/vkd3d_shader_main.c b/libs/vkd3d/libs/vkd3d-shader/vkd3d_shader_main.c
|
||||
index ca012d4948a..3355e18b88e 100644
|
||||
--- a/libs/vkd3d/libs/vkd3d-shader/vkd3d_shader_main.c
|
||||
+++ b/libs/vkd3d/libs/vkd3d-shader/vkd3d_shader_main.c
|
||||
@@ -489,13 +489,13 @@ static void vkd3d_shader_dump_shader(const struct shader_dump_data *dump_data,
|
||||
if ((f = fopen(filename, "wb")))
|
||||
{
|
||||
if (fwrite(data, 1, size, f) != size)
|
||||
- ERR("Failed to write shader to %s.\n", filename);
|
||||
+ WARN("Failed to write shader to %s.\n", filename);
|
||||
if (fclose(f))
|
||||
- ERR("Failed to close stream %s.\n", filename);
|
||||
+ WARN("Failed to close stream %s.\n", filename);
|
||||
}
|
||||
else
|
||||
{
|
||||
- ERR("Failed to open %s for dumping shader.\n", filename);
|
||||
+ WARN("Failed to open %s for dumping shader.\n", filename);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -680,6 +680,50 @@ static int vkd3d_shader_validate_compile_info(const struct vkd3d_shader_compile_
|
||||
return VKD3D_OK;
|
||||
}
|
||||
|
||||
+static enum vkd3d_result vsir_parse(const struct vkd3d_shader_compile_info *compile_info, uint64_t config_flags,
|
||||
+ struct vkd3d_shader_message_context *message_context, struct vsir_program *program)
|
||||
+{
|
||||
+ enum vkd3d_result ret;
|
||||
+
|
||||
+ switch (compile_info->source_type)
|
||||
+ {
|
||||
+ case VKD3D_SHADER_SOURCE_D3D_BYTECODE:
|
||||
+ ret = d3dbc_parse(compile_info, config_flags, message_context, program);
|
||||
+ break;
|
||||
+
|
||||
+ case VKD3D_SHADER_SOURCE_DXBC_TPF:
|
||||
+ ret = tpf_parse(compile_info, config_flags, message_context, program);
|
||||
+ break;
|
||||
+
|
||||
+ case VKD3D_SHADER_SOURCE_DXBC_DXIL:
|
||||
+ ret = dxil_parse(compile_info, config_flags, message_context, program);
|
||||
+ break;
|
||||
+
|
||||
+ default:
|
||||
+ ERR("Unsupported source type %#x.\n", compile_info->source_type);
|
||||
+ ret = VKD3D_ERROR_INVALID_ARGUMENT;
|
||||
+ break;
|
||||
+ }
|
||||
+
|
||||
+ if (ret < 0)
|
||||
+ {
|
||||
+ WARN("Failed to parse shader.\n");
|
||||
+ return ret;
|
||||
+ }
|
||||
+
|
||||
+ if ((ret = vsir_program_validate(program, config_flags, compile_info->source_name, message_context)) < 0)
|
||||
+ {
|
||||
+ WARN("Failed to validate shader after parsing, ret %d.\n", ret);
|
||||
+
|
||||
+ if (TRACE_ON())
|
||||
+ vsir_program_trace(program);
|
||||
+
|
||||
+ vsir_program_cleanup(program);
|
||||
+ }
|
||||
+
|
||||
+ return ret;
|
||||
+}
|
||||
+
|
||||
void vkd3d_shader_free_messages(char *messages)
|
||||
{
|
||||
TRACE("messages %p.\n", messages);
|
||||
@@ -1578,31 +1622,7 @@ int vkd3d_shader_scan(const struct vkd3d_shader_compile_info *compile_info, char
|
||||
uint64_t config_flags = vkd3d_shader_init_config_flags();
|
||||
struct vsir_program program;
|
||||
|
||||
- switch (compile_info->source_type)
|
||||
- {
|
||||
- case VKD3D_SHADER_SOURCE_D3D_BYTECODE:
|
||||
- ret = d3dbc_parse(compile_info, config_flags, &message_context, &program);
|
||||
- break;
|
||||
-
|
||||
- case VKD3D_SHADER_SOURCE_DXBC_TPF:
|
||||
- ret = tpf_parse(compile_info, config_flags, &message_context, &program);
|
||||
- break;
|
||||
-
|
||||
- case VKD3D_SHADER_SOURCE_DXBC_DXIL:
|
||||
- ret = dxil_parse(compile_info, config_flags, &message_context, &program);
|
||||
- break;
|
||||
-
|
||||
- default:
|
||||
- ERR("Unsupported source type %#x.\n", compile_info->source_type);
|
||||
- ret = VKD3D_ERROR_INVALID_ARGUMENT;
|
||||
- break;
|
||||
- }
|
||||
-
|
||||
- if (ret < 0)
|
||||
- {
|
||||
- WARN("Failed to parse shader.\n");
|
||||
- }
|
||||
- else
|
||||
+ if (!(ret = vsir_parse(compile_info, config_flags, &message_context, &program)))
|
||||
{
|
||||
ret = vsir_program_scan(&program, compile_info, &message_context, NULL);
|
||||
vsir_program_cleanup(&program);
|
||||
@@ -1719,38 +1739,15 @@ int vkd3d_shader_compile(const struct vkd3d_shader_compile_info *compile_info,
|
||||
uint64_t config_flags = vkd3d_shader_init_config_flags();
|
||||
struct vsir_program program;
|
||||
|
||||
- switch (compile_info->source_type)
|
||||
- {
|
||||
- case VKD3D_SHADER_SOURCE_D3D_BYTECODE:
|
||||
- ret = d3dbc_parse(compile_info, config_flags, &message_context, &program);
|
||||
- break;
|
||||
-
|
||||
- case VKD3D_SHADER_SOURCE_DXBC_TPF:
|
||||
- ret = tpf_parse(compile_info, config_flags, &message_context, &program);
|
||||
- break;
|
||||
-
|
||||
- case VKD3D_SHADER_SOURCE_DXBC_DXIL:
|
||||
- ret = dxil_parse(compile_info, config_flags, &message_context, &program);
|
||||
- break;
|
||||
-
|
||||
- default:
|
||||
- ERR("Unsupported source type %#x.\n", compile_info->source_type);
|
||||
- ret = VKD3D_ERROR_INVALID_ARGUMENT;
|
||||
- break;
|
||||
- }
|
||||
-
|
||||
- if (ret < 0)
|
||||
- {
|
||||
- WARN("Failed to parse shader.\n");
|
||||
- }
|
||||
- else
|
||||
+ if (!(ret = vsir_parse(compile_info, config_flags, &message_context, &program)))
|
||||
{
|
||||
ret = vsir_program_compile(&program, config_flags, compile_info, out, &message_context);
|
||||
vsir_program_cleanup(&program);
|
||||
}
|
||||
}
|
||||
|
||||
- vkd3d_shader_dump_shader(&dump_data, out->code, out->size, false);
|
||||
+ if (ret >= 0)
|
||||
+ vkd3d_shader_dump_shader(&dump_data, out->code, out->size, false);
|
||||
|
||||
vkd3d_shader_message_context_trace_messages(&message_context);
|
||||
if (!vkd3d_shader_message_context_copy_messages(&message_context, messages))
|
||||
diff --git a/libs/vkd3d/libs/vkd3d-shader/vkd3d_shader_private.h b/libs/vkd3d/libs/vkd3d-shader/vkd3d_shader_private.h
|
||||
index d6c68155ee7..5ae938e0525 100644
|
||||
--- a/libs/vkd3d/libs/vkd3d-shader/vkd3d_shader_private.h
|
||||
+++ b/libs/vkd3d/libs/vkd3d-shader/vkd3d_shader_private.h
|
||||
@@ -1477,12 +1477,6 @@ void vkd3d_shader_parser_init(struct vkd3d_shader_parser *parser, struct vsir_pr
|
||||
void vkd3d_shader_parser_warning(struct vkd3d_shader_parser *parser,
|
||||
enum vkd3d_shader_error error, const char *format, ...) VKD3D_PRINTF_FUNC(3, 4);
|
||||
|
||||
-static inline enum vkd3d_result vkd3d_shader_parser_validate(struct vkd3d_shader_parser *parser, uint64_t config_flags)
|
||||
-{
|
||||
- return vsir_program_validate(parser->program, config_flags,
|
||||
- parser->location.source_name, parser->message_context);
|
||||
-}
|
||||
-
|
||||
struct vkd3d_shader_descriptor_info1
|
||||
{
|
||||
enum vkd3d_shader_descriptor_type type;
|
||||
diff --git a/libs/vkd3d/libs/vkd3d/device.c b/libs/vkd3d/libs/vkd3d/device.c
|
||||
index fd0ca20838f..54a39e18a0f 100644
|
||||
--- a/libs/vkd3d/libs/vkd3d/device.c
|
||||
+++ b/libs/vkd3d/libs/vkd3d/device.c
|
||||
@@ -136,7 +136,8 @@ static HRESULT vkd3d_create_vk_descriptor_heap_layout(struct d3d12_device *devic
|
||||
VK_DESCRIPTOR_TYPE_STORAGE_IMAGE,
|
||||
};
|
||||
|
||||
- if (device->vk_info.EXT_mutable_descriptor_type && index && index != VKD3D_SET_INDEX_UAV_COUNTER
|
||||
+ if (device->vk_info.EXT_mutable_descriptor_type
|
||||
+ && index != VKD3D_SET_INDEX_MUTABLE && index != VKD3D_SET_INDEX_UAV_COUNTER
|
||||
&& device->vk_descriptor_heap_layouts[index].applicable_heap_type == D3D12_DESCRIPTOR_HEAP_TYPE_CBV_SRV_UAV)
|
||||
{
|
||||
device->vk_descriptor_heap_layouts[index].vk_set_layout = VK_NULL_HANDLE;
|
||||
@@ -144,7 +145,7 @@ static HRESULT vkd3d_create_vk_descriptor_heap_layout(struct d3d12_device *devic
|
||||
}
|
||||
|
||||
binding.binding = 0;
|
||||
- binding.descriptorType = (device->vk_info.EXT_mutable_descriptor_type && !index)
|
||||
+ binding.descriptorType = (device->vk_info.EXT_mutable_descriptor_type && index == VKD3D_SET_INDEX_MUTABLE)
|
||||
? VK_DESCRIPTOR_TYPE_MUTABLE_EXT : device->vk_descriptor_heap_layouts[index].type;
|
||||
binding.descriptorCount = device->vk_descriptor_heap_layouts[index].count;
|
||||
binding.stageFlags = VK_SHADER_STAGE_ALL;
|
||||
@@ -200,14 +201,20 @@ static HRESULT vkd3d_vk_descriptor_heap_layouts_init(struct d3d12_device *device
|
||||
{
|
||||
static const struct vkd3d_vk_descriptor_heap_layout vk_descriptor_heap_layouts[VKD3D_SET_INDEX_COUNT] =
|
||||
{
|
||||
- {VK_DESCRIPTOR_TYPE_UNIFORM_BUFFER, true, D3D12_DESCRIPTOR_HEAP_TYPE_CBV_SRV_UAV},
|
||||
- {VK_DESCRIPTOR_TYPE_UNIFORM_TEXEL_BUFFER, true, D3D12_DESCRIPTOR_HEAP_TYPE_CBV_SRV_UAV},
|
||||
- {VK_DESCRIPTOR_TYPE_SAMPLED_IMAGE, false, D3D12_DESCRIPTOR_HEAP_TYPE_CBV_SRV_UAV},
|
||||
- {VK_DESCRIPTOR_TYPE_STORAGE_TEXEL_BUFFER, true, D3D12_DESCRIPTOR_HEAP_TYPE_CBV_SRV_UAV},
|
||||
- {VK_DESCRIPTOR_TYPE_STORAGE_IMAGE, false, D3D12_DESCRIPTOR_HEAP_TYPE_CBV_SRV_UAV},
|
||||
- {VK_DESCRIPTOR_TYPE_SAMPLER, false, D3D12_DESCRIPTOR_HEAP_TYPE_SAMPLER},
|
||||
- /* UAV counters */
|
||||
- {VK_DESCRIPTOR_TYPE_STORAGE_TEXEL_BUFFER, true, D3D12_DESCRIPTOR_HEAP_TYPE_CBV_SRV_UAV},
|
||||
+ [VKD3D_SET_INDEX_UNIFORM_BUFFER] =
|
||||
+ {VK_DESCRIPTOR_TYPE_UNIFORM_BUFFER, true, D3D12_DESCRIPTOR_HEAP_TYPE_CBV_SRV_UAV},
|
||||
+ [VKD3D_SET_INDEX_UNIFORM_TEXEL_BUFFER] =
|
||||
+ {VK_DESCRIPTOR_TYPE_UNIFORM_TEXEL_BUFFER, true, D3D12_DESCRIPTOR_HEAP_TYPE_CBV_SRV_UAV},
|
||||
+ [VKD3D_SET_INDEX_SAMPLED_IMAGE] =
|
||||
+ {VK_DESCRIPTOR_TYPE_SAMPLED_IMAGE, false, D3D12_DESCRIPTOR_HEAP_TYPE_CBV_SRV_UAV},
|
||||
+ [VKD3D_SET_INDEX_STORAGE_TEXEL_BUFFER] =
|
||||
+ {VK_DESCRIPTOR_TYPE_STORAGE_TEXEL_BUFFER, true, D3D12_DESCRIPTOR_HEAP_TYPE_CBV_SRV_UAV},
|
||||
+ [VKD3D_SET_INDEX_STORAGE_IMAGE] =
|
||||
+ {VK_DESCRIPTOR_TYPE_STORAGE_IMAGE, false, D3D12_DESCRIPTOR_HEAP_TYPE_CBV_SRV_UAV},
|
||||
+ [VKD3D_SET_INDEX_SAMPLER] =
|
||||
+ {VK_DESCRIPTOR_TYPE_SAMPLER, false, D3D12_DESCRIPTOR_HEAP_TYPE_SAMPLER},
|
||||
+ [VKD3D_SET_INDEX_UAV_COUNTER] =
|
||||
+ {VK_DESCRIPTOR_TYPE_STORAGE_TEXEL_BUFFER, true, D3D12_DESCRIPTOR_HEAP_TYPE_CBV_SRV_UAV},
|
||||
};
|
||||
const struct vkd3d_device_descriptor_limits *limits = &device->vk_info.descriptor_limits;
|
||||
enum vkd3d_vk_descriptor_set_index set;
|
||||
@@ -1918,24 +1925,26 @@ static HRESULT vkd3d_init_device_caps(struct d3d12_device *device,
|
||||
&& descriptor_indexing->descriptorBindingUniformTexelBufferUpdateAfterBind
|
||||
&& descriptor_indexing->descriptorBindingStorageTexelBufferUpdateAfterBind;
|
||||
|
||||
- /* Many Vulkan implementations allow up to 8 descriptor sets. Unfortunately
|
||||
- * using vkd3d with Vulkan heaps and push descriptors currently requires up
|
||||
- * to 9 descriptor sets (up to one for the push descriptors, up to one for
|
||||
- * the static samplers and seven for Vulkan heaps, one for each needed
|
||||
- * descriptor type). If we detect such situation, we disable push
|
||||
- * descriptors, which allows us to stay within the limits (not doing so is
|
||||
- * fatal on many implmentations).
|
||||
- *
|
||||
- * It is possible that a different strategy might be used. For example, we
|
||||
- * could move the static samplers to one of the seven Vulkan heaps sets. Or
|
||||
- * we could decide whether to create the push descriptor set when creating
|
||||
- * the root signature, depending on whether there are static samplers or
|
||||
- * not. */
|
||||
- if (device->vk_info.device_limits.maxBoundDescriptorSets == 8 && device->use_vk_heaps
|
||||
- && device->vk_info.KHR_push_descriptor)
|
||||
- {
|
||||
- TRACE("Disabling VK_KHR_push_descriptor to save a descriptor set.\n");
|
||||
- device->vk_info.KHR_push_descriptor = VK_FALSE;
|
||||
+ if (device->use_vk_heaps && device->vk_info.KHR_push_descriptor)
|
||||
+ {
|
||||
+ /* VKD3D_SET_INDEX_COUNT for the Vulkan heaps, one for the push
|
||||
+ * descriptors set and one for the static samplers set. */
|
||||
+ unsigned int descriptor_set_count = VKD3D_SET_INDEX_COUNT + 2;
|
||||
+
|
||||
+ /* A mutable descriptor set can replace all those that should otherwise
|
||||
+ * back the SRV-UAV-CBV descriptor heap. */
|
||||
+ if (device->vk_info.EXT_mutable_descriptor_type)
|
||||
+ descriptor_set_count -= VKD3D_SET_INDEX_COUNT - (VKD3D_SET_INDEX_MUTABLE + 1);
|
||||
+
|
||||
+ /* For many Vulkan implementations maxBoundDescriptorSets == 8; also,
|
||||
+ * if mutable descriptors are not available the descriptor set count
|
||||
+ * will be 9; so saving a descriptor set is going to be often
|
||||
+ * significant. */
|
||||
+ if (descriptor_set_count > device->vk_info.device_limits.maxBoundDescriptorSets)
|
||||
+ {
|
||||
+ WARN("Disabling VK_KHR_push_descriptor to save a descriptor set.\n");
|
||||
+ device->vk_info.KHR_push_descriptor = VK_FALSE;
|
||||
+ }
|
||||
}
|
||||
|
||||
if (device->use_vk_heaps)
|
||||
diff --git a/libs/vkd3d/libs/vkd3d/resource.c b/libs/vkd3d/libs/vkd3d/resource.c
|
||||
index 6d6820d3752..1f7d90eb95f 100644
|
||||
--- a/libs/vkd3d/libs/vkd3d/resource.c
|
||||
+++ b/libs/vkd3d/libs/vkd3d/resource.c
|
||||
@@ -2498,7 +2498,7 @@ static void d3d12_desc_write_vk_heap_null_descriptor(struct d3d12_descriptor_hea
|
||||
enum vkd3d_vk_descriptor_set_index set, end;
|
||||
unsigned int i = writes->count;
|
||||
|
||||
- end = device->vk_info.EXT_mutable_descriptor_type ? VKD3D_SET_INDEX_UNIFORM_BUFFER
|
||||
+ end = device->vk_info.EXT_mutable_descriptor_type ? VKD3D_SET_INDEX_MUTABLE
|
||||
: VKD3D_SET_INDEX_STORAGE_IMAGE;
|
||||
/* Binding a shader with the wrong null descriptor type works in Windows.
|
||||
* To support that here we must write one to all applicable Vulkan sets. */
|
||||
@@ -4250,7 +4250,8 @@ static HRESULT d3d12_descriptor_heap_create_descriptor_pool(struct d3d12_descrip
|
||||
if (device->vk_descriptor_heap_layouts[set].applicable_heap_type == desc->Type
|
||||
&& device->vk_descriptor_heap_layouts[set].vk_set_layout)
|
||||
{
|
||||
- pool_sizes[pool_desc.poolSizeCount].type = (device->vk_info.EXT_mutable_descriptor_type && !set)
|
||||
+ pool_sizes[pool_desc.poolSizeCount].type =
|
||||
+ (device->vk_info.EXT_mutable_descriptor_type && set == VKD3D_SET_INDEX_MUTABLE)
|
||||
? VK_DESCRIPTOR_TYPE_MUTABLE_EXT : device->vk_descriptor_heap_layouts[set].type;
|
||||
pool_sizes[pool_desc.poolSizeCount++].descriptorCount = desc->NumDescriptors;
|
||||
}
|
||||
@@ -4280,11 +4281,12 @@ static HRESULT d3d12_descriptor_heap_create_descriptor_set(struct d3d12_descript
|
||||
|
||||
if (!device->vk_descriptor_heap_layouts[set].vk_set_layout)
|
||||
{
|
||||
- /* Set 0 uses mutable descriptors, and this set is unused. */
|
||||
- if (!descriptor_heap->vk_descriptor_sets[0].vk_set
|
||||
- && FAILED(hr = d3d12_descriptor_heap_create_descriptor_set(descriptor_heap, device, 0)))
|
||||
+ /* Mutable descriptors are in use, and this set is unused. */
|
||||
+ if (!descriptor_heap->vk_descriptor_sets[VKD3D_SET_INDEX_MUTABLE].vk_set
|
||||
+ && FAILED(hr = d3d12_descriptor_heap_create_descriptor_set(descriptor_heap,
|
||||
+ device, VKD3D_SET_INDEX_MUTABLE)))
|
||||
return hr;
|
||||
- descriptor_set->vk_set = descriptor_heap->vk_descriptor_sets[0].vk_set;
|
||||
+ descriptor_set->vk_set = descriptor_heap->vk_descriptor_sets[VKD3D_SET_INDEX_MUTABLE].vk_set;
|
||||
descriptor_set->vk_type = device->vk_descriptor_heap_layouts[set].type;
|
||||
return S_OK;
|
||||
}
|
||||
diff --git a/libs/vkd3d/libs/vkd3d/state.c b/libs/vkd3d/libs/vkd3d/state.c
|
||||
index 8e5ec70a577..e7476a01bd7 100644
|
||||
--- a/libs/vkd3d/libs/vkd3d/state.c
|
||||
+++ b/libs/vkd3d/libs/vkd3d/state.c
|
||||
@@ -1016,7 +1016,7 @@ static void vkd3d_descriptor_heap_binding_from_descriptor_range(const struct d3d
|
||||
}
|
||||
else
|
||||
{
|
||||
- binding->set = 0;
|
||||
+ binding->set = VKD3D_SET_INDEX_MUTABLE;
|
||||
descriptor_set_size = descriptor_limits->sampled_image_max_descriptors;
|
||||
}
|
||||
}
|
||||
@@ -1483,21 +1483,24 @@ static unsigned int d3d12_root_signature_copy_descriptor_set_layouts(const struc
|
||||
{
|
||||
const struct d3d12_device *device = root_signature->device;
|
||||
enum vkd3d_vk_descriptor_set_index set;
|
||||
+ VkDescriptorSetLayout vk_set_layout;
|
||||
unsigned int i;
|
||||
|
||||
for (i = 0; i < root_signature->vk_set_count; ++i)
|
||||
vk_set_layouts[i] = root_signature->descriptor_set_layouts[i].vk_layout;
|
||||
|
||||
- if (device->use_vk_heaps)
|
||||
+ if (!device->use_vk_heaps)
|
||||
+ return i;
|
||||
+
|
||||
+ for (set = 0; set < ARRAY_SIZE(device->vk_descriptor_heap_layouts); ++set)
|
||||
{
|
||||
- VkDescriptorSetLayout mutable_layout = device->vk_descriptor_heap_layouts[0].vk_set_layout;
|
||||
+ vk_set_layout = device->vk_descriptor_heap_layouts[set].vk_set_layout;
|
||||
|
||||
- for (set = 0; set < ARRAY_SIZE(device->vk_descriptor_heap_layouts); ++set)
|
||||
- {
|
||||
- VkDescriptorSetLayout vk_set_layout = device->vk_descriptor_heap_layouts[set].vk_set_layout;
|
||||
- /* All layouts must be valid, so if null, just set it to the mutable one. */
|
||||
- vk_set_layouts[i++] = vk_set_layout ? vk_set_layout : mutable_layout;
|
||||
- }
|
||||
+ VKD3D_ASSERT(vk_set_layout);
|
||||
+ vk_set_layouts[i++] = vk_set_layout;
|
||||
+
|
||||
+ if (device->vk_info.EXT_mutable_descriptor_type && set == VKD3D_SET_INDEX_MUTABLE)
|
||||
+ break;
|
||||
}
|
||||
|
||||
return i;
|
||||
diff --git a/libs/vkd3d/libs/vkd3d/vkd3d_private.h b/libs/vkd3d/libs/vkd3d/vkd3d_private.h
|
||||
index e6d477a5c12..97a99782d6a 100644
|
||||
--- a/libs/vkd3d/libs/vkd3d/vkd3d_private.h
|
||||
+++ b/libs/vkd3d/libs/vkd3d/vkd3d_private.h
|
||||
@@ -772,14 +772,21 @@ void d3d12_dsv_desc_create_dsv(struct d3d12_dsv_desc *dsv_desc, struct d3d12_dev
|
||||
|
||||
enum vkd3d_vk_descriptor_set_index
|
||||
{
|
||||
- VKD3D_SET_INDEX_UNIFORM_BUFFER = 0,
|
||||
- VKD3D_SET_INDEX_UNIFORM_TEXEL_BUFFER = 1,
|
||||
- VKD3D_SET_INDEX_SAMPLED_IMAGE = 2,
|
||||
- VKD3D_SET_INDEX_STORAGE_TEXEL_BUFFER = 3,
|
||||
- VKD3D_SET_INDEX_STORAGE_IMAGE = 4,
|
||||
- VKD3D_SET_INDEX_SAMPLER = 5,
|
||||
- VKD3D_SET_INDEX_UAV_COUNTER = 6,
|
||||
- VKD3D_SET_INDEX_COUNT = 7
|
||||
+ VKD3D_SET_INDEX_SAMPLER,
|
||||
+ VKD3D_SET_INDEX_UAV_COUNTER,
|
||||
+ VKD3D_SET_INDEX_MUTABLE,
|
||||
+
|
||||
+ /* These are used when mutable descriptors are not available to back
|
||||
+ * SRV-UAV-CBV descriptor heaps. They must stay at the end of this
|
||||
+ * enumeration, so that they can be ignored when mutable descriptors are
|
||||
+ * used. */
|
||||
+ VKD3D_SET_INDEX_UNIFORM_BUFFER = VKD3D_SET_INDEX_MUTABLE,
|
||||
+ VKD3D_SET_INDEX_UNIFORM_TEXEL_BUFFER,
|
||||
+ VKD3D_SET_INDEX_SAMPLED_IMAGE,
|
||||
+ VKD3D_SET_INDEX_STORAGE_TEXEL_BUFFER,
|
||||
+ VKD3D_SET_INDEX_STORAGE_IMAGE,
|
||||
+
|
||||
+ VKD3D_SET_INDEX_COUNT
|
||||
};
|
||||
|
||||
extern const enum vkd3d_vk_descriptor_set_index vk_descriptor_set_index_table[];
|
||||
--
|
||||
2.45.2
|
||||
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@@ -1,4 +1,4 @@
|
||||
From fe189703f5fd934e96f986dce72af6a84c4303ce Mon Sep 17 00:00:00 2001
|
||||
From b4aeefdb8869f683f5085b8d64bc591855df138a Mon Sep 17 00:00:00 2001
|
||||
From: Paul Gofman <gofmanp@gmail.com>
|
||||
Date: Mon, 9 Sep 2019 18:48:43 +0300
|
||||
Subject: [PATCH] wined3d: Add a setting to workaround 0 * inf problem in
|
||||
@@ -15,10 +15,10 @@ Signed-off-by: Paul Gofman <gofmanp@gmail.com>
|
||||
3 files changed, 135 insertions(+), 24 deletions(-)
|
||||
|
||||
diff --git a/dlls/wined3d/glsl_shader.c b/dlls/wined3d/glsl_shader.c
|
||||
index f7f09d73538..75a88aac6ef 100644
|
||||
index df2ad761d8f..fccb45233db 100644
|
||||
--- a/dlls/wined3d/glsl_shader.c
|
||||
+++ b/dlls/wined3d/glsl_shader.c
|
||||
@@ -2407,6 +2407,19 @@ static void shader_generate_glsl_declarations(const struct wined3d_context_gl *c
|
||||
@@ -2382,6 +2382,19 @@ static void shader_generate_glsl_declarations(const struct wined3d_context_gl *c
|
||||
if (wined3d_settings.strict_shader_math)
|
||||
shader_addline(buffer, "#pragma optionNV(fastmath off)\n");
|
||||
|
||||
@@ -38,7 +38,7 @@ index f7f09d73538..75a88aac6ef 100644
|
||||
prefix = shader_glsl_get_prefix(version->type);
|
||||
|
||||
/* Prototype the subroutines */
|
||||
@@ -3997,7 +4010,12 @@ static void shader_glsl_binop(const struct wined3d_shader_instruction *ins)
|
||||
@@ -3920,7 +3933,12 @@ static void shader_glsl_binop(const struct wined3d_shader_instruction *ins)
|
||||
write_mask = shader_glsl_append_dst(buffer, ins);
|
||||
shader_glsl_add_src_param(ins, &ins->src[0], write_mask, &src0_param);
|
||||
shader_glsl_add_src_param(ins, &ins->src[1], write_mask, &src1_param);
|
||||
@@ -52,7 +52,7 @@ index f7f09d73538..75a88aac6ef 100644
|
||||
}
|
||||
|
||||
static void shader_glsl_relop(const struct wined3d_shader_instruction *ins)
|
||||
@@ -4210,26 +4228,45 @@ static void shader_glsl_dot(const struct wined3d_shader_instruction *ins)
|
||||
@@ -4133,26 +4151,45 @@ static void shader_glsl_dot(const struct wined3d_shader_instruction *ins)
|
||||
struct glsl_src_param src0_param;
|
||||
struct glsl_src_param src1_param;
|
||||
DWORD dst_write_mask, src_write_mask;
|
||||
@@ -104,7 +104,7 @@ index f7f09d73538..75a88aac6ef 100644
|
||||
}
|
||||
}
|
||||
|
||||
@@ -4265,10 +4302,15 @@ static void shader_glsl_cut(const struct wined3d_shader_instruction *ins)
|
||||
@@ -4188,10 +4225,15 @@ static void shader_glsl_cut(const struct wined3d_shader_instruction *ins)
|
||||
static void shader_glsl_pow(const struct wined3d_shader_instruction *ins)
|
||||
{
|
||||
struct wined3d_string_buffer *buffer = ins->ctx->buffer;
|
||||
@@ -120,7 +120,7 @@ index f7f09d73538..75a88aac6ef 100644
|
||||
|
||||
dst_write_mask = shader_glsl_append_dst(buffer, ins);
|
||||
dst_size = shader_glsl_get_write_mask_size(dst_write_mask);
|
||||
@@ -4278,13 +4320,33 @@ static void shader_glsl_pow(const struct wined3d_shader_instruction *ins)
|
||||
@@ -4201,13 +4243,33 @@ static void shader_glsl_pow(const struct wined3d_shader_instruction *ins)
|
||||
|
||||
if (dst_size > 1)
|
||||
{
|
||||
@@ -158,7 +158,7 @@ index f7f09d73538..75a88aac6ef 100644
|
||||
}
|
||||
}
|
||||
|
||||
@@ -4462,11 +4524,15 @@ static void shader_glsl_scalar_op(const struct wined3d_shader_instruction *ins)
|
||||
@@ -4382,11 +4444,15 @@ static void shader_glsl_scalar_op(const struct wined3d_shader_instruction *ins)
|
||||
{
|
||||
DWORD shader_version = WINED3D_SHADER_VERSION(ins->ctx->reg_maps->shader_version.major,
|
||||
ins->ctx->reg_maps->shader_version.minor);
|
||||
@@ -175,7 +175,7 @@ index f7f09d73538..75a88aac6ef 100644
|
||||
|
||||
dst_write_mask = shader_glsl_append_dst(buffer, ins);
|
||||
dst_size = shader_glsl_get_write_mask_size(dst_write_mask);
|
||||
@@ -4476,41 +4542,78 @@ static void shader_glsl_scalar_op(const struct wined3d_shader_instruction *ins)
|
||||
@@ -4396,41 +4462,78 @@ static void shader_glsl_scalar_op(const struct wined3d_shader_instruction *ins)
|
||||
|
||||
shader_glsl_add_src_param(ins, &ins->src[0], dst_write_mask, &src0_param);
|
||||
|
||||
@@ -264,7 +264,7 @@ index f7f09d73538..75a88aac6ef 100644
|
||||
}
|
||||
|
||||
/** Process the WINED3DSIO_EXPP instruction in GLSL:
|
||||
@@ -4827,8 +4930,13 @@ static void shader_glsl_mad(const struct wined3d_shader_instruction *ins)
|
||||
@@ -4775,8 +4878,13 @@ static void shader_glsl_mad(const struct wined3d_shader_instruction *ins)
|
||||
shader_glsl_add_src_param(ins, &ins->src[0], write_mask, &src0_param);
|
||||
shader_glsl_add_src_param(ins, &ins->src[1], write_mask, &src1_param);
|
||||
shader_glsl_add_src_param(ins, &ins->src[2], write_mask, &src2_param);
|
||||
@@ -281,10 +281,10 @@ index f7f09d73538..75a88aac6ef 100644
|
||||
|
||||
/* Handles transforming all WINED3DSIO_M?x? opcodes for
|
||||
diff --git a/dlls/wined3d/wined3d_main.c b/dlls/wined3d/wined3d_main.c
|
||||
index 524dc7508f9..1168b0ccb8d 100644
|
||||
index 3b436919559..abf8153cff0 100644
|
||||
--- a/dlls/wined3d/wined3d_main.c
|
||||
+++ b/dlls/wined3d/wined3d_main.c
|
||||
@@ -421,6 +421,8 @@ static BOOL wined3d_dll_init(HINSTANCE hInstDLL)
|
||||
@@ -430,6 +430,8 @@ static BOOL wined3d_dll_init(HINSTANCE hInstDLL)
|
||||
ERR_(winediag)("Setting strict shader math to %#x.\n", wined3d_settings.strict_shader_math);
|
||||
if (!get_config_key_dword(hkey, appkey, env, "MaxShaderModelVS", &wined3d_settings.max_sm_vs))
|
||||
TRACE("Limiting VS shader model to %u.\n", wined3d_settings.max_sm_vs);
|
||||
@@ -294,17 +294,17 @@ index 524dc7508f9..1168b0ccb8d 100644
|
||||
TRACE("Limiting HS shader model to %u.\n", wined3d_settings.max_sm_hs);
|
||||
if (!get_config_key_dword(hkey, appkey, env, "MaxShaderModelDS", &wined3d_settings.max_sm_ds))
|
||||
diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h
|
||||
index 2b84a6070fb..c031e6fe8b6 100644
|
||||
index 2e0a541cea5..8af55a88eaf 100644
|
||||
--- a/dlls/wined3d/wined3d_private.h
|
||||
+++ b/dlls/wined3d/wined3d_private.h
|
||||
@@ -469,6 +469,7 @@ struct wined3d_settings
|
||||
@@ -477,6 +477,7 @@ struct wined3d_settings
|
||||
unsigned int multisample_textures;
|
||||
unsigned int sample_count;
|
||||
BOOL check_float_constants;
|
||||
unsigned int strict_shader_math;
|
||||
+ unsigned int multiply_special;
|
||||
unsigned int max_sm_vs;
|
||||
unsigned int max_sm_hs;
|
||||
unsigned int max_sm_ds;
|
||||
--
|
||||
2.35.1
|
||||
2.45.2
|
||||
|
||||
|
@@ -122,7 +122,7 @@ index 53982bb8c3b..f6769a695d4 100644
|
||||
+
|
||||
+ if (!(data = get_win_data( hwnd ))) return;
|
||||
+
|
||||
+ if (data->mapped && data->managed && !data->iconic)
|
||||
+ if (data->managed)
|
||||
+ {
|
||||
+ XEvent xev;
|
||||
+ struct x11drv_win_data *active = get_win_data( thread_data->active_window );
|
||||
|
@@ -1,4 +1,4 @@
|
||||
From 35f112456d2095d17e59974ca7538c67bad110c2 Mon Sep 17 00:00:00 2001
|
||||
From f286821dd241e169a7a2146ac23b7200b66a645a Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Gabriel=20Iv=C4=83ncescu?= <gabrielopcode@gmail.com>
|
||||
Date: Mon, 24 Dec 2018 14:26:57 +0200
|
||||
Subject: [PATCH] winex11.drv/window: Query the X server for the actual rect of
|
||||
@@ -22,10 +22,10 @@ Signed-off-by: Gabriel Ivăncescu <gabrielopcode@gmail.com>
|
||||
1 file changed, 21 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/dlls/winex11.drv/window.c b/dlls/winex11.drv/window.c
|
||||
index 0e06939f67d..cc5d0db870c 100644
|
||||
index 22c15c35468..b48bc13df7c 100644
|
||||
--- a/dlls/winex11.drv/window.c
|
||||
+++ b/dlls/winex11.drv/window.c
|
||||
@@ -222,6 +222,25 @@ static BOOL has_owned_popups( HWND hwnd )
|
||||
@@ -345,6 +345,25 @@ static BOOL has_owned_popups( HWND hwnd )
|
||||
return ret;
|
||||
}
|
||||
|
||||
@@ -51,13 +51,13 @@ index 0e06939f67d..cc5d0db870c 100644
|
||||
|
||||
/***********************************************************************
|
||||
* alloc_win_data
|
||||
@@ -2629,7 +2648,8 @@ void X11DRV_WindowPosChanged( HWND hwnd, HWND insert_after, UINT swp_flags, cons
|
||||
@@ -2995,7 +3014,8 @@ void X11DRV_WindowPosChanged( HWND hwnd, HWND insert_after, HWND owner_hint, UIN
|
||||
if (old_style & WS_VISIBLE)
|
||||
{
|
||||
if (((swp_flags & SWP_HIDEWINDOW) && !(new_style & WS_VISIBLE)) ||
|
||||
(!event_type && !(new_style & WS_MINIMIZE) &&
|
||||
- !is_window_rect_mapped( &new_rects->window ) && is_window_rect_mapped( &old_rects.window )))
|
||||
+ !is_window_rect_mapped( &new_rects->window ) && is_window_rect_mapped( &old_rects.window ) &&
|
||||
+ !is_actual_window_rect_mapped( data )))
|
||||
- (!(new_style & WS_MINIMIZE) && !is_window_rect_mapped( &new_rects->window ) && is_window_rect_mapped( &old_rects.window )))
|
||||
+ (!(new_style & WS_MINIMIZE) && !is_window_rect_mapped( &new_rects->window ) && is_window_rect_mapped( &old_rects.window ) &
|
||||
+ !is_actual_window_rect_mapped( data )))
|
||||
{
|
||||
release_win_data( data );
|
||||
unmap_window( hwnd );
|
||||
|
@@ -1 +1 @@
|
||||
Wine Staging 9.21
|
||||
Wine Staging 9.22
|
||||
|
@@ -1 +1 @@
|
||||
c9a8333c0f274201faf33d27abda1ebb5ae07cec
|
||||
51ccd95c49c2c61ad41960b25a01f834601d70c0
|
||||
|
Reference in New Issue
Block a user