Mark Young [Fri, 2 Jul 2021 14:40:16 +0000 (08:40 -0600)]
Re-arrange/update loader docs
Update the loader documentation in the following ways:
1. Move documentation to new "docs" folder"
2. Split LoaderAndLayerInterface.md into multiple docs to focus
on target audience:
- Top-Level LoaderInterfaceArchitecture.md
- Applications LoaderApplicationInterface.md
- Layers LoaderLayerInterface.md
- ICDs LoaderImplementationInterface.md
3. Upload newer images and their corresponding original Inkscape files.
4. Cleanup and update sections on Linux directory search
5. Add new sections to detail items missing
- VkConfig
- Handling undef Fuchsia
6. Language cleanup
Thanks to @charles-lunarg and @smcv for feedback and various section language
corrections.
Charles Giessen [Tue, 21 Sep 2021 22:22:06 +0000 (16:22 -0600)]
Only return pre-instance functions when instance is NULL
vkGetInstanceProcAddr should only return the pre-instance, aka global
functions, when the VkInstance handle is NULL. This brings the desktop
vulkan loader into alignment on the spec and with the android loader.
https://github.com/KhronosGroup/Vulkan-Docs/issues/1605
The repo previously did follow this rule, but was changes in the
1.0.42 header version timeframe for unknown reasons.
Mike Schuchardt [Wed, 13 Oct 2021 16:35:45 +0000 (09:35 -0700)]
build: Update to header 1.2.196
- Update known-good
- Generate source
Charles Giessen [Thu, 7 Oct 2021 19:50:17 +0000 (13:50 -0600)]
Update README.md to remove mention of Vk-Headers
Charles Giessen [Wed, 6 Oct 2021 22:39:31 +0000 (16:39 -0600)]
test: Update WrapObjects test to new framework
Moved over the WrapObjects test logic into the new framework, removing all
the old tests infrastructure that is no longer needed.
Charles Giessen [Wed, 6 Oct 2021 22:37:30 +0000 (16:37 -0600)]
Zero-init values passed into EnumPhysDevs
Graeme Leese [Wed, 6 Oct 2021 11:46:58 +0000 (12:46 +0100)]
Only parse git information if .git/HEAD exists
If the source comes from somewhere else (eg. the release tarballs) then
.git/HEAD does not exist, so the cmake step was failing. Only try to
colelct the git information if the file exists.
Fixes #714.
Mike Schuchardt [Tue, 5 Oct 2021 18:08:10 +0000 (11:08 -0700)]
build: Update to header 1.2.195
- Update known-good
- Generate source
Charles Giessen [Tue, 5 Oct 2021 05:46:05 +0000 (23:46 -0600)]
test: remove stub functions
Test code should not use stub functions because its undefined behavior. This
resulted in SEH exceptions on Win32.
Charles Giessen [Tue, 5 Oct 2021 05:45:05 +0000 (23:45 -0600)]
test: Use correct name in def files
Charles Giessen [Mon, 4 Oct 2021 18:15:18 +0000 (12:15 -0600)]
test: Use correct path in json files
Previously a Windows path in a json file did not include the correct
backslahses. This commit rectifies that.
Charles Giessen [Fri, 1 Oct 2021 22:05:14 +0000 (16:05 -0600)]
test: Update ExtraLoaderTests
Updated the enable/disable env-var tests to use the test framework.
Removed the run_extra_loader_tests.sh.
Charles Giessen [Fri, 1 Oct 2021 19:50:25 +0000 (13:50 -0600)]
test: Move more old tests to new framework
More tests can now be written with the new framework. Several of the
shell scripts used tests in vk_loader_validation_tests which were phased
out so no longer necessary.
Charles Giessen [Fri, 1 Oct 2021 22:46:33 +0000 (16:46 -0600)]
ci: Enable tests on MacOS GithubActions
Tests only get built if you enable them now, instead of when
googletest is in the external folder.
Charles Giessen [Thu, 30 Sep 2021 23:16:14 +0000 (17:16 -0600)]
loader: Remove old debug path printing
This commit only prints paths using the new, more structured, output.
It wasn't removed until now due to the paths being used in tests which
have since been modernized, thus no longer needing to keep the old output
style.
Charles Giessen [Thu, 30 Sep 2021 23:05:13 +0000 (17:05 -0600)]
test: Add XDG & VK_LAYER_PATH tests
Tests check to see if the paths are searched by looking at the log.
Makde FrameworkEnvironment contain a debug_log, this is to prevent any
lifetime issues. This prevents the possibility of creating a DebugUtilsLogger
after the InstWrapper.
Had to redo the test framework a bit to make them work.
Charles Giessen [Tue, 21 Sep 2021 20:12:47 +0000 (14:12 -0600)]
test: Fixup XDG path handling, add XDG tests
Charles Giessen [Thu, 30 Sep 2021 17:52:08 +0000 (11:52 -0600)]
build: Revert generated loader.rc
Revert the commit that uses the vulkan-headers version and instead uses the
1.0.1111.2222 version number while still allowing for the CMake build arg
BUILD_DLL_VERSIONINFO to dictate the actual version.
Ralf Habacker [Tue, 7 Sep 2021 11:12:10 +0000 (13:12 +0200)]
loader: Fix setting `libdir` in generated vulkan.pc on Windows
Fixes #668
Charles Giessen [Wed, 29 Sep 2021 19:00:58 +0000 (13:00 -0600)]
loader: Only include loader_windows.h on windows
This header should only be included on windows platforms, since non-windows platforms
may not know that the header should be present (which is the case for GN builds).
Charles Giessen [Thu, 23 Sep 2021 21:15:08 +0000 (15:15 -0600)]
build: Move test dependencies to known_good.json
This makes the requisite changes to make the dependencies needed for testing automatically
downloaded by cmake when the UPDATE_DEPS option is given.
Charles Giessen [Thu, 23 Sep 2021 21:06:47 +0000 (15:06 -0600)]
build: Update update_deps.py to match VVL
Was out of date with the feature set VVL contained.
Fixed an issue where backslashes were used on windows, which caused issues when
cmake decided to escape a string one more time than necessary.
"C:\\Users\\..." -> "C:\Users" which has a `\U` escape symbol mucking things up.
Mike Schuchardt [Tue, 28 Sep 2021 15:33:35 +0000 (08:33 -0700)]
build: Update to header 1.2.194
- Update known-good
- Generate source
Charles Giessen [Mon, 27 Sep 2021 23:37:47 +0000 (17:37 -0600)]
build: Add RELEASE_BUILD option for Windows SDK builds
This CMake option controls the information put in the loader.rc file,
specifically the "Dev Build" string in the version info.
Charles Giessen [Mon, 27 Sep 2021 21:35:16 +0000 (15:35 -0600)]
Use CMake to define SECURE_GETENV variables
Use `target_compile_definitions` to provide the HAVE_SECURE_GETENV and
HAVE___SECURE_GETENV macro defines. This removes the need to configure
a file and makes the definition global to the loader, rather than just
from whoever included the header file.
Charles Giessen [Sat, 18 Sep 2021 00:00:18 +0000 (18:00 -0600)]
build: Set DLL version automatically
The loader.rc file was used to set the version used in the loader. However,
this was always done manually (either by hand or a script to edit the file).
This commit makes the version number needed generated automatically based on
the current generated header version or uses a provided version, such as in
the case of SDK builds with a 'build revision', eg "1.2.191.2".
This commit also renames the atrosciously named
loader_generated_header_version_generator to a nicer
loader_versioning_generator.
Nathaniel Cesario [Thu, 23 Sep 2021 16:09:26 +0000 (10:09 -0600)]
build: Add UPDATE_DEPS cmake arg
Add an UPDATE_DEPS cmake arg that can be used to automatically run
update_deps.py as needed.
Charles Giessen [Wed, 22 Sep 2021 22:17:50 +0000 (16:17 -0600)]
test: Isolate Env-Vars from test framework
Previously if any of the env-vars the loader looks for were set on the
system, the loader would find and use them, leading to highly confusing
logs. Removing them preemptively at tests start make this a non-issue.
unknown [Tue, 21 Sep 2021 17:37:14 +0000 (11:37 -0600)]
build: Fix using wrong Windows SDK for VS 2015
CMake 3.19 disallowed VS 2015 builds from selecting an SDK higher than
10.0.14393. Unfortunately, the loader requires SDK version 10.0.17763 or
higher. This commit uses the 3.19 capability to disable that limit set in
place by CMake so that we can use an SDK that suits our needs.
Mike Schuchardt [Tue, 21 Sep 2021 15:30:05 +0000 (08:30 -0700)]
build: Update to header 1.2.193
- Update known-good
- Generate source
Natalie Chouinard [Thu, 16 Sep 2021 20:39:05 +0000 (20:39 +0000)]
loader: Add cJSON prefix to update function
Mike Schuchardt [Wed, 15 Sep 2021 16:21:27 +0000 (09:21 -0700)]
build: Update to header 1.2.192
- Update known-good
- Generate source
Jamie Madill [Fri, 10 Sep 2021 11:35:12 +0000 (07:35 -0400)]
loader: Add loader.rc to Windows GN build
This omission was causing the build dll to be missing version info.
Charles Giessen [Sat, 11 Sep 2021 16:28:08 +0000 (10:28 -0600)]
test: Fix 32 bit test suite build error
Charles Giessen [Fri, 10 Sep 2021 20:14:56 +0000 (14:14 -0600)]
loader: Move struct decls to loader_common.h
Not all structs declarations in loader.h were moved to loader_common.h. This
caused compilation errors due to not having the struct declaration available
in the headers it was needed.
Charles Giessen [Thu, 2 Sep 2021 21:54:56 +0000 (15:54 -0600)]
test: Add test which calls GetPDProps inside CreateInstance
This test makes sure that any layer calling GetPDProps inside of CreateInstance
succeeds and doesn't crash.
Charles Giessen [Fri, 10 Sep 2021 17:01:36 +0000 (11:01 -0600)]
test: Add ICD Interface V6 TestICD binary
Charles Giessen [Thu, 2 Sep 2021 21:54:07 +0000 (15:54 -0600)]
test: Add callback to layers create instance and device
This allows some code to be written inside the test which then gets run
during the call to vkCreateInstance and vkCreateDevice.
Mark Young [Tue, 17 Aug 2021 02:01:25 +0000 (20:01 -0600)]
Update more logging info for the Loader
Output more information to the "info" debug target when the loader loads
so we can determine more info about:
- Where loader was loaded from (Windows)
- What Git Branch was used to build it
- What Git tags were most recent when it was built.
Also, add more detailed logging of implicit layers:
- Log manifest file location
- Layer library location
- Type of layer (implicit/explicit)
- Disable enum if layer is implicit
Charles Giessen [Thu, 9 Sep 2021 20:13:21 +0000 (14:13 -0600)]
loader: Reverst asserting on size 0 in malloc
Charles Giessen [Wed, 12 May 2021 23:23:46 +0000 (17:23 -0600)]
loader: Move disable_environment into function body
The function `loader_read_layer_json` does not modify the
disable_environment parameter that is passed in. It can safely be made
a variable local to the function.
Change-Id: I25ef3f3e5f008082dc9514be8f607d2acbf212a1
Charles Giessen [Wed, 18 Aug 2021 17:11:01 +0000 (11:11 -0600)]
build: Use generated source everywhere
The previous commit that added a generated header version didn't apply
it to mac or linux specific versioning. This commit fixes that.
Charles Giessen [Mon, 30 Aug 2021 16:59:05 +0000 (10:59 -0600)]
test: Add test for memory leak in setup_tramp_phys_devs
Tries to trick the loader by increasing the number of physical devices
after the call to vkEnumeratePhysicalDevices to get the count.
Charles Giessen [Fri, 21 May 2021 04:34:52 +0000 (22:34 -0600)]
loader: Fix freeing of uninitialized list
The memset of icd_tramp_list in terminator_EnumerateInstanceExtensionPropeties
was inside an else-branch. If an error occured in the preceding if branch, this
would cause the cleanup code to run on a non-zerod out icd_tramp_list.
Change-Id: I7af1da31580f01c54c4ffababbb9c7ecfa8966d8
Charles Giessen [Fri, 21 May 2021 02:33:16 +0000 (20:33 -0600)]
loader: Remove deadstore when breaking from a loop
Change-Id: Ic72cf396cad918ce255b331fa9a9c3a652b8764d
Charles Giessen [Fri, 21 May 2021 02:19:24 +0000 (20:19 -0600)]
loader: Prevent use-after-free in error path.
When `setup_loader_term_phys_devs` and `setup_loader_term_phys_dev_groups` hit an
error, they attempt to delete all the alocated elements in `new_phys_devs`. However,
the code first may copy elements from another array into it first before hitting
the error. This causes the deletion code to free those 'good' elements which were
copied, leading to use-after-free's.
Additionally, an error message used total_gpu_count instead of total_icd_count, this
is fixed with this commit.
Change-Id: I8f714f699ff09cc99d094cf2ed8190cedcad684b
Charles Giessen [Mon, 17 May 2021 23:42:29 +0000 (17:42 -0600)]
loader: Don't pass null pointer into strcmp
strcmp wasn't correctly guarded against a null first parameter when
doing the shallow search in loader_name_in_dev_ext_table and
loader_name_in_phys_dev_ext_table.
Change-Id: Ia751e9860334895930210defa2dcb2becbfd6daa
Charles Giessen [Mon, 17 May 2021 22:24:23 +0000 (16:24 -0600)]
loader: Remove dead store of total_count
`loaderScanForLayers` total_count is not used after determining
if it is not zero.
Change-Id: I2ff3a1a5d7dde42ce5ad7d57aab63831ccf58156
Charles Giessen [Mon, 17 May 2021 22:09:27 +0000 (16:09 -0600)]
loader: Prevent stack_alloc of 0
`loader_create_device_chain` would previously attempt to use stack allocations
when `expanded_activated_layer_list.count` was zero, which is undefined behavior
Change-Id: I56fab835a1728914191f1a7adc210dae58afa155
Charles Giessen [Mon, 17 May 2021 22:05:46 +0000 (16:05 -0600)]
loader: Get DeviceGroups early exits if 0 are found
This commit prevents undefined behavior by exiting
`setupLoaderTermPhysDevGroups` if total_count is 0.
Change-Id: Ieef2747724f79ec26a08a74884904bc0e0485c17
Charles Giessen [Mon, 17 May 2021 21:17:58 +0000 (15:17 -0600)]
loader: Remove redundant stores
`layer_node = layer_node->next;` is redundant in error paths that goto out.
Change-Id: I889b03c825f896f458a1ed3171b951d64d8827d7
Charles Giessen [Mon, 17 May 2021 20:41:38 +0000 (14:41 -0600)]
loader: assert if trying to malloc 0 bytes
The behavior of malloc is undefined if size is 0. This commit checks for that
and prevents a possible malloc of zero in device extension property enumeration
by only malloc'ing if size is greater than 0.
Change-Id: Id506ab93d404bd4895503c660ef74bcb9c4550a3
Charles Giessen [Mon, 17 May 2021 16:56:14 +0000 (10:56 -0600)]
loader: Format WSI error messages
Change-Id: I3040be426a8e70ca41e7beede1fae6b52e1381af
Charles Giessen [Thu, 13 May 2021 22:41:16 +0000 (16:41 -0600)]
loader: Use abort to force a crash where needed
Many places in the loader need to intentionally crash. This commit makes the
loader use `abort();` in those places, including replacing numerous
`assert(false)` statements. Using abort clearly signals intent instead of
having it do a null pointer dereference to cause the crash.
Change-Id: I6874eab5702c94af59b7984fab00f6eaf03f2f45
Charles Giessen [Thu, 13 May 2021 00:20:37 +0000 (18:20 -0600)]
loader: Fix potential memory leak
Also remove a redundant setting of an int to 0
Change-Id: Ia099ad75e9da14aacf9874d75267716c12794305
Charles Giessen [Wed, 12 May 2021 23:42:00 +0000 (17:42 -0600)]
loader: Handle OOM in loader_phys_dev_ext_gpa
Removing some dead code revealed a case where a potencial OOM situation
was not being handled.
Change-Id: Ibc5ad607f6adc0f590f663ab928c1abca6732d96
Charles Giessen [Thu, 9 Sep 2021 16:00:52 +0000 (10:00 -0600)]
loader: Make trampolineGetProcAddr snake_case
Charles Giessen [Mon, 6 Sep 2021 16:47:34 +0000 (10:47 -0600)]
loader: Move simple terminators to terminator.c
Keeps the complex terminators in loader.c for the time being.
Charles Giessen [Mon, 6 Sep 2021 16:16:28 +0000 (10:16 -0600)]
loader: Rename SetupLoaderTermPhysDevGroups
Forgot this name when renaming all the functions.
Charles Giessen [Mon, 6 Sep 2021 00:53:57 +0000 (18:53 -0600)]
gn: Fix gn build for refactor changes
Charles Giessen [Mon, 6 Sep 2021 00:34:10 +0000 (18:34 -0600)]
loader: Move Windows logic to dedicated file
Relocated most windows specific functionality into loader_windows.h/.c
This removes the need for loader.c to include windows specific header files.
Charles Giessen [Sun, 5 Sep 2021 23:20:26 +0000 (17:20 -0600)]
loader: Move struct declarations into header
Charles Giessen [Sun, 5 Sep 2021 23:14:47 +0000 (17:14 -0600)]
loader: Move init functions closer together
Charles Giessen [Sun, 5 Sep 2021 05:23:28 +0000 (23:23 -0600)]
loader: Header include cleanup
Separated headers into common groups, with system headers being first, then
Vulkan API headers, followed by loader headers.
Then alphabetized headers in each group. Due to moving _GNU_SOURCE to being set
by cmake, there isn't any implicit dependency between the include order used.
Made sure headers should be able to be included independently, such as
including the vulkan headers where appropriate.
Charles Giessen [Sun, 5 Sep 2021 05:08:26 +0000 (23:08 -0600)]
loader: Remove headers from cmake source list
Headers do not do any functional thing here. Better to remove them so they dont
clutter up or make people thing they need to be there.
Charles Giessen [Sun, 5 Sep 2021 05:06:46 +0000 (23:06 -0600)]
loader: Make logging and getenv their own headers
This commit pulls the logging capabilities into a single log.h/.c file and does
the same for the getenv functionality.
Charles Giessen [Sun, 5 Sep 2021 04:40:36 +0000 (22:40 -0600)]
loader: Make _GNU_SOURCE a cmake definition
Moves the many instances of #define _GNU_SOURCE into a single cmake call which
sets the macro in all translation units for the vulkan library. This way it
cannot be forgotten and makes behavior across the library consistent.
Charles Giessen [Sun, 5 Sep 2021 04:31:25 +0000 (22:31 -0600)]
loader: Move alloca into allocation.h
Charles Giessen [Sun, 5 Sep 2021 04:28:36 +0000 (22:28 -0600)]
loader: Remove duplicate macro defines
Charles Giessen [Sun, 5 Sep 2021 04:15:40 +0000 (22:15 -0600)]
loader: Make vk_loader_layer.h a proper header
Makes it possible to include this file without worry of not having the required
headers already included.
Charles Giessen [Sun, 5 Sep 2021 04:13:51 +0000 (22:13 -0600)]
loader: Remove unneeded parts of loader_common.h
Charles Giessen [Sun, 5 Sep 2021 04:10:59 +0000 (22:10 -0600)]
loader: Shift around vk_loader_platform headers
Moved the includes into their own block, instead of living in the block for
each operating system. This way is easier to see what includes are in the file
in its entirety.
Also, _GNU_SOURCE was uncommented since it appears in each source file
individually and is needed for alloca and secure_getenv
Charles Giessen [Sun, 5 Sep 2021 00:53:54 +0000 (18:53 -0600)]
loader: Dont include C++ libraries in C++ mode
Charles Giessen [Sat, 4 Sep 2021 21:38:53 +0000 (15:38 -0600)]
loader: Move allocation functions to a header
Functions pertainting to allocation (malloc, realloc, free) have been moved to
their own translation unit for better organizational purposes.
Charles Giessen [Sat, 4 Sep 2021 19:48:37 +0000 (13:48 -0600)]
loader: Remove TLS
The only purpose TLS was serving was as a channel for allocation callbacks to
be useable inside cJSON and dirent_on_windows. TLS didn't solve any specific
threading problem. Instead it served as an information channel. On top of that,
the only time when the TLS was used was inside vkCreateInstance as the
pre-instance calls would have the TLS pointer to loader_instance be set to
NULL.
Charles Giessen [Sat, 4 Sep 2021 19:33:38 +0000 (13:33 -0600)]
loader: cJSON to use regular heap instead of TLS
Refactored the cJSON library to take an loader_instance pointer everywhere it
allocates memory. This way a TLS loader_instance pointer doesn't need to be
set at initialization and then at vkCreateInstance.
Charles Giessen [Sat, 4 Sep 2021 17:13:40 +0000 (11:13 -0600)]
loader: Dont use TLS in dirent_on_windows
Loader will now pass in the instance handle directly rather than rely on TLS to
pass it. This makes the loader code simpler to reason about and better since
if a second instance is created on the same thread the TLS wont be overwritten.
Charles Giessen [Sat, 4 Sep 2021 04:18:51 +0000 (22:18 -0600)]
loader: Add gpa_helper.c
Make gpa_helper.h not contain function definitions, moving them into the
appropriate header file.
Charles Giessen [Sat, 4 Sep 2021 04:03:18 +0000 (22:03 -0600)]
loader: Move loader struct defs into common file
This commit separates the structure definitions from the function declarations.
The reason to do this is to allow splitting of loader.h/.c functionality into
individual headers, which may require access to these structs but don't need to
know about the other functions.
Charles Giessen [Sat, 4 Sep 2021 03:55:09 +0000 (21:55 -0600)]
loader: Update Copyright for 2021
Charles Giessen [Sat, 4 Sep 2021 03:41:19 +0000 (21:41 -0600)]
loader: Use #pragma once everywhere
The #pragma once include guard is sufficiently widespread enough to allow
usage of it everywhere.
Charles Giessen [Sat, 4 Sep 2021 03:23:43 +0000 (21:23 -0600)]
loader: Update Copyright
Charles Giessen [Sat, 4 Sep 2021 03:22:45 +0000 (21:22 -0600)]
build: Alphabetize loader source file list
Charles Giessen [Wed, 8 Sep 2021 21:26:09 +0000 (15:26 -0600)]
test: Add test for Override Meta Layer
Charles Giessen [Wed, 8 Sep 2021 21:25:37 +0000 (15:25 -0600)]
test: Fix extra } in layer manifest printer
Charles Giessen [Wed, 8 Sep 2021 21:23:22 +0000 (15:23 -0600)]
loader: Move layer cleanup to a single function
Previously the logic to free all the components of loader_layer_properties was spread
across a half dozen different places, resulting in leaks. This commit moves the logic
into a single location, centralizing the process and making it easier to add new
fields to the loader_layer_properties struct.
Mike Schuchardt [Wed, 8 Sep 2021 22:06:25 +0000 (15:06 -0700)]
build: Update to header 1.2.191
- Update known-good
- Generate source
Charles Giessen [Mon, 6 Sep 2021 23:57:08 +0000 (17:57 -0600)]
test: Improved Test Wrapper interface
Made InstanceWrapper and DeviceWrapper simpler to use by moving them to test_environment
then making the Create() member functions and doing the gtest assertions in the function
itself.
Additionally:
Removed the `detail` namespace in the test_environment.
Renamed get_new_test_icd/layer to just `reset_icd/layer`. This is clearer about what it
is doing and makes the interface more expressive with code such as
`env->reset_icd().SetMinInterfaceVersion(5);`
Charles Giessen [Fri, 3 Sep 2021 01:24:19 +0000 (19:24 -0600)]
loader: Make all loader functions use snake_case
Before it was a mix of camelCase, PascalCase, and snake_case.
"Vulkan" functions, like terminator_GetPhysicalDeviceProperties, remain in camelCase.
This way it looks visually similar with the actual vulkan functions they correspond to.
Mark Young [Fri, 27 Aug 2021 15:33:47 +0000 (09:33 -0600)]
Fix loader not knowing about extensions enabled in layers
This change allows the loader to know extensions enabled in the layers
as well as extensions enabled but handled by layers.
This should fix several issues where the enabled extensions is not
known soon enough for layers to use.
Mark Young [Fri, 13 Aug 2021 23:26:04 +0000 (17:26 -0600)]
Update XDG paths
Issue #245 was created because we were not properly using the XDG
paths.
This change updates the path search order to be more correct.
While an argument could be made that the loader really should only
be looking in the DATA folders, we already are looking in the
CONFIG folders. Therefore, just correct the order and also make
sure the proper _HOME variable for CONFIG and DATA is searched
first (but only in non-superuser mode).
Charles Giessen [Tue, 31 Aug 2021 20:52:54 +0000 (14:52 -0600)]
test: Add handle_assert helper functions
Added functions which check handle values using GTEST. Includes:
checking for null, not null, equality of two handles, and variants that
operate on vectors and arrays.
Charles Giessen [Tue, 31 Aug 2021 20:08:41 +0000 (14:08 -0600)]
test: Move DeviceGroup tests to regression suite
Charles Giessen [Tue, 31 Aug 2021 20:05:32 +0000 (14:05 -0600)]
test: Add TestICD DeviceGroup support
Add support for tests which use device groups by adding a new structure that
holds pointes to PhysicalDevice structs and implementing the necessary vulkan
API calls.
This commit also:
- Formats test_icd.cpp
- Makes vk_icdGetPhysicalDeviceProcAddr return stuff by refactoring the
instance procaddr functions
Charles Giessen [Mon, 30 Aug 2021 17:04:55 +0000 (11:04 -0600)]
scripts: Remove loader_icd_init_entries duplicate
Seems to be a copy-paste error that makes the function declaration appear twice.
Mike Schuchardt [Mon, 30 Aug 2021 16:10:06 +0000 (09:10 -0700)]
build: Update to header 1.2.190
- Update known-good
- Generate source
Charles Giessen [Mon, 16 Aug 2021 17:50:43 +0000 (11:50 -0600)]
build: Silence MSVC warning of replacing /GR
Charles Giessen [Wed, 25 Aug 2021 22:43:58 +0000 (16:43 -0600)]
test: Update 32/64 tests to check the log
Use the DebugUtilsLogger to verify that the loader is downgrading the error
level of dll/so's from ERROR to INFO
Charles Giessen [Wed, 25 Aug 2021 22:41:59 +0000 (16:41 -0600)]
test: Add DebugUtilsWrapper
This wrapper allows easy reading of the log output through the debug utils
messenger infrastructure. Since getting the stdout/stderr is not well
supported by googletest, this allows tests to be written which check for
specific log messages to be emitted, allowing another way to verify the
loader is behaving as expected.
Charles Giessen [Wed, 25 Aug 2021 22:39:26 +0000 (16:39 -0600)]
loader: Downgrade wrong arch errors on windows
On linux, when the loader fails to load a .so if it was due to being on the
wrong architecture, the loader downgraded the error to INFO level. This
commit does the same thing for windows. Error code 193 is winapi's way to
signify that the dll failed to load cause of the architecture.