Bob Ellison [Wed, 15 Jul 2020 21:13:48 +0000 (15:13 -0600)]
scripts: fix update_deps retry clone
There was a subtle bug in the original change; "git fetch"
would retry correctly, but "git clone" failed because the
destination directory was missing (after having been removed,
to ensure a clean clone operation).
The test case that was used (hundreds of times) happened to
provoke an error on the "git fetch" path; I was unaware that
the "git clone" failure path had never been exercised.
Shannon McPherson [Tue, 14 Jul 2020 17:25:34 +0000 (11:25 -0600)]
build: Update known-good files for 1.2.147 header
Changes:
- Updated `known_good.json`
Change-Id: I2309eef9e654cdca58770161a9397929a0b23de8
Lenny Komow [Tue, 14 Jul 2020 19:54:05 +0000 (13:54 -0600)]
loader: Remove RTLD_DEEPBIND flag
This causes trouble when used with the steam fossilize layer. We'd
still like to use RTLD_DEEPBIND, but we need to work out the issues
first.
Change-Id: Ic44b5a9de9a4e7a1163cbc68e4d5e692315b285c
Bob Ellison [Mon, 13 Jul 2020 17:28:10 +0000 (11:28 -0600)]
scripts: udpate_deps retry on clone or fetch failure
Duplicate change from
b636386a7824eb4e6a0d99962e1491ac68d3a295
on KhronosGroup/Vulkan-ValidationLayers, to keep update_deps.py
in sync across all repos. Original commit message is:
We see spurious failures to connect to github when trying to
run update_deps.py (up to 7% of runs, depending on the machine).
This is an annoyance when running by hand, but a headache and
a serious resource waste when running in automation (as a single
broken "git clone" or "git fetch" can cause the whole run to fail).
These changes allow update_deps.py to automatically retry
"git fetch" and "git clone" operations on failure.
These changes will be duplicated in follow-on PRs to the
other repositories that include "update_deps.py", to keep
them all in sync. These are KhronosGroup/Vulkan-Tools,
KhronosGroup/Vulkan-Loader, LunarG/VulkanSamples, and
LunarG/VulkanTools.
I'm also including a "technical debt" update here, because
VulkanTools/scripts/update_deps.py had diverged from the other
"update_deps.py" versions, to add a way to avoid building a
dependency if that dependency is not supported on the current
build platform. This should be harmless to the other
repositories (though potentially useful in the future). The
original commit was
aaabc9df034f1fdf9a976a6293d0983b079143ee
with description:
In update deps, this will check that a dependency is actually supported
on the platform being built. This is needed because the loader is a
dependency on all platforms other than Windows.
Charles Giessen [Thu, 9 Jul 2020 20:20:10 +0000 (14:20 -0600)]
loader: Make RTLD_DEEPBIND conditional on ASAN
Address Sanitizer (ASAN) is broken by the inclusion of RTLD_DEEPBIND. This commit
removes that dlopen flag if ASAN is detected during compilation.
Change-Id: Ibc3cc329b2f6335a3d5982691b6491efc8c3bbe9
Mike Schuchardt [Thu, 2 Jul 2020 21:59:18 +0000 (14:59 -0700)]
build: Roll GN DEPS file
Sync standalone GN toolchain revisions with current ANGLE revisions
Nicolas Caramelli [Tue, 7 Jul 2020 19:56:13 +0000 (21:56 +0200)]
Remove duplicate key / value in scripts/common_codegen.py
Shannon McPherson [Mon, 6 Jul 2020 17:20:11 +0000 (11:20 -0600)]
build: Update known-good files for 1.2.146 header
Changes:
- Updated `known_good.json`
- Generated new source files
Change-Id: Ifbd578d254d544a454e7e84738330eae9983c462
Nicolas Caramelli [Sat, 4 Jul 2020 20:53:59 +0000 (22:53 +0200)]
loader: Add support for directfb surface extension
The new VK_EXT_directfb_surface extension is a WSI extension and
thereforce needs loader support like the other surface extensions.
Alexander Batashev [Sun, 5 Jul 2020 10:27:38 +0000 (13:27 +0300)]
loader: Fix symbol lookup order
Some Vulkan implementations may rely on external libraries.
One example is mesa driver, that uses libLLVM.so. If user
application also links with LLVM, some clashes may take place.
This patch ensures that library's own symbols are looked up
before any other symbols in current process.
Sylvain Defresne [Thu, 2 Jul 2020 16:05:01 +0000 (18:05 +0200)]
Convert GN libs lists to frameworks
GN recently added support for Apple frameworks to link, rather than
overloading the libs lists. This pulls .frameworks out of the libs
lists, so that GN can stop supporting .frameworks in libs in the
future.
Bug: chromium:
1052560
Charles Giessen [Wed, 1 Jul 2020 21:34:23 +0000 (15:34 -0600)]
loader: fix wrongly returned error code
vkEnumerateInstanceExtensionProperties was returning INITIALIZATION_FAILED
when a single malformed manifest file was found. This was due to the way
loader_scan_icd only returns an error if no valid ICD's were found.
Change-Id: I84b39774b766d20d607c990bddc921b1c2a4297a
Charles Giessen [Thu, 2 Jul 2020 21:26:41 +0000 (15:26 -0600)]
loader: fix TSAN warning
The trampoline vkEnumerateDeviceExtensionProperties locked/unlocked the
loader mutex, but the terminator function also unlocked, causeing a double
free. Removing the locking in the terminator fixes the problem.
Change-Id: I714b243f3410a7fdc371b740def5ab962ae74a6f
Shannon McPherson [Tue, 9 Jun 2020 19:34:36 +0000 (13:34 -0600)]
build: Update known-good files for 1.2.145 header
Changes:
- Updated `known_good.json`
- Propagated `loader_genvk.py` changes
- Modified scripts to accommodate new genvk functionality
- Generated new source files
Change-Id: If54251171bb3c70cef305d1e954aa02124432106
Jan Beich [Fri, 19 Jun 2020 10:19:08 +0000 (10:19 +0000)]
build: include system headers last
Charles Giessen [Mon, 15 Jun 2020 19:20:11 +0000 (13:20 -0600)]
loader: Use MoltenVK in app bundle if found
The loader now loads the first ICD in an app bundle if one exists.
This is to prevent multiple copies of MoltenVK being loaded.
Change-Id: I1e4b8e854e5d709c6e229c9591f4a8856e3b2b41
Lenny Komow [Thu, 11 Jun 2020 15:33:04 +0000 (09:33 -0600)]
loader: Fix crash in vkGetDeviceQueue2
This function allows an driver to return a null handle. A previous
change caused that to crash.
Change-Id: Ic2e375b1959bb5a16a6c4854715521e4d392a616
dan sinclair [Tue, 9 Jun 2020 17:14:55 +0000 (13:14 -0400)]
scripts: Use named params for generator options
When calling in the vulkan header python generator the options have
changed in 1.2.142 which causes the options passed by the loader to be
off by one. This ends up setting the emitExtensions to the value of the
sortProcedure and eventually causes the script to fail.
This CL updates the loader to used named parameters for the generator so
that the addition of the genpath does not throw off the parameter
positioning.
Change-Id: I14fda7e90be985216c5243457a22fdcb01b5c82b
Shannon McPherson [Mon, 25 May 2020 22:43:56 +0000 (16:43 -0600)]
Build: Update known-good files for 1.2.141 header
Change-Id: Ib5f2fab581fb98fa1391c8fde1009bb8bd1c09c7
Charles Giessen [Mon, 28 Oct 2019 20:15:11 +0000 (14:15 -0600)]
loader: add per-application override layer settings
An array of strings was added to the override layer to provide
per-application overrides. The loader will now look for an override profile
which contains an app_key entry that matches the path & name of the currently
running executable. Previous behavior with a global override still works as
intended.
This changes is in conjunction with the VkConfig rewrite to allow for more
than one override profile to be enabled.
Changes to be committed:
modified: loader/loader.c
modified: loader/loader.h
modified: loader/vk_loader_platform.h
Change-Id: I9ddbc98a098d48064110db6c29998eddb336fcda
Charles Giessen [Tue, 12 May 2020 20:25:47 +0000 (14:25 -0600)]
loader: Preload ICD use its own mutex
Previously, if a layer called a pre-instance function
while being initialized (inside vkCreateInstance) a deadlock
would occur because the preload icd call used the same mutex.
Change-Id: I085ecfbcab26d746d77ca8466b4f63a13f6bea10
Shannon McPherson [Tue, 5 May 2020 17:02:53 +0000 (11:02 -0600)]
build: Fix `loader_genvk.py` error logging
A modification to one line of code was missed when updating the loader
genvk file for the 1.2.140 header update and when the change was
incorporated it exposed the newly added `logDiag` function which can be
found in `reflib.py` in Vulkan-Docs. Instead of adding another script to
the Loader repo, `write` functionality was reinstated in
`loader_genvk.py`.
Change-Id: Idf792b24c86120a8c278f46ac8a47013c4c37f16
Shannon McPherson [Mon, 4 May 2020 17:29:45 +0000 (11:29 -0600)]
build: Update known-good for 1.2.140 header
Changes:
- Updated `known_good.json`
- Propagated `loader_genvk.py` changes
- Generated new source files
- Modified `.gitattributes` to ensure generated source files should
always have LF line endings because that is how it will be generated on
all platforms going forward. Upstream change in Vulkan-Docs explicitly
generates code with LF line endings.
- Removed automatic CRLF to LF conversion git setting in `.appveyor.yml`
Change-Id: I1ca36b80dfabe83fa16e36116d1ad43c0a65ff78
Petr Kraus [Tue, 28 Apr 2020 20:49:14 +0000 (22:49 +0200)]
docs: Fix typo
Lenny Komow [Fri, 24 Apr 2020 16:14:48 +0000 (10:14 -0600)]
loader: Check for null when creating a queue
Without a null check when creating a queue, it becomes impossible to
test for the case where the provided queue is null. Normally I would
prefer to check the return code, but these functions are void return.
Change-Id: I391be85526944b4d39377cfc33545e74c1ce327d
Petr Kraus [Sat, 18 Apr 2020 15:12:51 +0000 (17:12 +0200)]
docs: Fix link in interface docs
Corentin Wallez [Thu, 16 Apr 2020 09:08:59 +0000 (11:08 +0200)]
BUILD.gn: Generate libvulkan.so.1 on Linux
On Linux the standard name to use the Vulkan loader is libvulkan.so.1,
so we add a copy step to the GN build that copies libvulkan.so to
libvulkan.so.1.
Also ran `gn format` on BUILD.gn
Charles Giessen [Wed, 15 Apr 2020 17:52:27 +0000 (11:52 -0600)]
tests: fix non-msvc windows test building
Building the tests outside of msvc wouldn't work due to improper setup.
This commit fixes the typos and missing debug/release switches for
google-test.
Change-Id: Ifdc2cdab8236c35ba9e14663fffaa412f40aaa6a
Charles Giessen [Sat, 11 Apr 2020 07:45:19 +0000 (01:45 -0600)]
loader: Fix deadlock introduced by preloading ICDs
The call to `loader_unload_preloaded_icds()` in vkDestroyInstance happens before the
loader_lock mutex was released, causing a deadlock due to the mutex not allowing
self re-entrant locking.
The fix is simply unload the ICDs after this lock was released.
Change-Id: I3f5774463b9872127893ed00183693dcf17a35d1
Charles Giessen [Mon, 2 Mar 2020 22:04:30 +0000 (15:04 -0700)]
loader: Preload ICD's to speed up common path
The ideal of having the loader be stateless causes serious slowdowns
in application startup due to the need to load then unload ICD's
repeatedly while calling pre vkCreateInstance functions. By pre-
loading the ICD's which are found using loader_icd_scan, the
unecessary reloading of ICD's is avoided.
The preloaded ICD's will be unloaded with vkDestroyInstance. This
allows subsequent vkCreateInstance calls to use the most recent ICD
on the system, preventing issue where a new driver was installed
but an application couldn't use it unless they unloaded the loader
library completely.
Changes to be committed:
modified: loader/loader.c
modified: loader/loader.h
modified: loader/trampoline.c
Change-Id: Id169f94bea15e569b75c3a663b25444cc6c52c40
Lenny Komow [Wed, 8 Apr 2020 21:28:22 +0000 (15:28 -0600)]
build: Find headers package from external dir
A previous change allowed finding vulkan headers in the external
directory. This change modifies that to use the find_package()
interface through CMake. This allows versioning to work properly.
Change-Id: Ic00c45545d343286dce5c1ea4108e186d2bb6268
Kévin Petit [Thu, 9 Apr 2020 12:54:21 +0000 (13:54 +0100)]
Log debug messages with verbose severity instead of info
Both the loader and VK_EXT_debug_utils define four levels of severity,
map them one to one.
Signed-off-by: Kévin Petit <kpet@free.fr>
Shannon McPherson [Wed, 8 Apr 2020 21:52:42 +0000 (15:52 -0600)]
build: Update known-good for 1.2.137 header
Updated `known_good.json` and generated new source files
Change-Id: If8edd83ec20ef78e0067a43d5acbee80cfe00ead
Lenny Komow [Fri, 21 Dec 2018 21:58:28 +0000 (14:58 -0700)]
tests: Update layer path test to strip empty paths
Change-Id: Ib6f209650894e44955b82aa47a5e24f2d3640acc
Lenny Komow [Fri, 21 Dec 2018 21:57:50 +0000 (14:57 -0700)]
loader: Strip out empty search paths
Change-Id: Ibb0dfba07207716ccda0181cb2317dafc5bef2f4
David Hubbard [Fri, 21 Dec 2018 19:09:57 +0000 (13:09 -0600)]
loader: Fix clang-format formatting issues
David Hubbard [Fri, 21 Dec 2018 18:56:49 +0000 (12:56 -0600)]
loader: Remove duplicate search paths on posix
Windows platforms remove duplicate search paths due to registry keys
that are not device-specific but need to be searched. For the most
part, mac and linux do not need to do that. But if duplicate paths
crop up on a posix platform, it can cause the same device showing up
twice in the vkEnumeratePhysicalDevices results. There may be other
places it causes unexpected results as well.
VkPhysicalDeviceIDProperties.deviceUUID can be used later to tell that
the two entries are actually the same device and not a multi-GPU
system, but finding the root cause at that point is going to be very
difficult.
Jamie Madill [Sun, 20 Oct 2019 13:40:46 +0000 (09:40 -0400)]
build: Fix not finding registry path in some cases
The Vulkan Headers detection script was coded to look for the Vulkan
registry in ${VULKAN_REGISTRY_PATH_HINT}/share/vulkan/registry. When
using the Vulkan-Headers repo the registry is located in just
${VULKAN_REGISTRY_PATH_HINT}/registry. This fix should allow both uses.
Wang YanQing [Thu, 26 Mar 2020 07:07:10 +0000 (15:07 +0800)]
docs: Improve vkNegotiateLoaderLayerInterfaceVersion's description
The current description about the version number negotiation between
loader and layer is easy to cause disagreement, and the description
about the version number negotiation between loader and ICD is much
more readable, so I think it is better to adopt the same way as the
vk_icdNegotiateLoaderICDInterfaceVersion description to describe the
vkNegotiateLoaderLayerInterfaceVersion.
Signed-off-by: Wang YanQing <udknight@gmail.com>
Aaron Franke [Sat, 21 Mar 2020 06:57:59 +0000 (02:57 -0400)]
Add newlines to two DXGI files
Wang YanQing [Wed, 25 Mar 2020 05:42:20 +0000 (13:42 +0800)]
docs: Correct one minor discrepancy in "Implicit vs Explicit Layers"
No place mentions the way previously that we could use environment
variable to enable explicit layers, so I think it is better to move
the notice in brackets to the more proper place.
Lenny Komow [Wed, 1 Apr 2020 19:26:02 +0000 (13:26 -0600)]
build: Enable building static loader on MacOS
Ricardo Garcia [Thu, 2 Apr 2020 12:41:47 +0000 (14:41 +0200)]
Allow vkGetInstanceProcAddr to resolve itself with no instance
Fixes #365
Charles Giessen [Mon, 30 Mar 2020 17:55:28 +0000 (11:55 -0600)]
loader: fix mispelling of implement
This somehow went under the radar for the spelling mistakes commit
previously.
Change-Id: I377e145d949b9e659dc89dc3bb912931eb9daca4
Mike Weiblen [Thu, 27 Feb 2020 19:12:54 +0000 (12:12 -0700)]
tests: Use complete version from header
Change-Id: Ic194ff680af778d7221b60be14be20db57930244
Mike Weiblen [Thu, 27 Feb 2020 19:12:38 +0000 (12:12 -0700)]
loader: Use complete version from header
Change-Id: I97b4f2aa42f24cea082ac574dfcedd853f02caf8
Wang YanQing [Thu, 26 Mar 2020 03:32:41 +0000 (11:32 +0800)]
docs: Fix wrong type name in InterceptFunctionName prototype
The right type name of InterceptFunctionName's first argument
is VkEnumerateInstanceExtensionPropertiesChan instead of the
VkEnumerateInstanceExtensionProperties.
Signed-off-by: Wang YanQing <udknight@gmail.com>
Charles Giessen [Tue, 10 Mar 2020 17:06:18 +0000 (11:06 -0600)]
scripts: stubs in dispatch table lacked matching return types
Generated functions stubs had either a return type of void or
VkResult. Recent vulkan extensions had functions which returned
uint32_t, uint64_t, and VkDeviceAddress. The
dispatch_table_helper_generator didn't account for this and GCC would
complain about mismatching types. While likely not an issue, it did
create very noisy builds.
Modified files:
loader/generated/vk_dispatch_table_helper.h
scripts/dispatch_table_helper_generator.py
Change-Id: Iba229093461b75fd6ccd195cf60e200a22b8678f
Charles Giessen [Wed, 18 Mar 2020 06:39:00 +0000 (00:39 -0600)]
loader: check for duplicates in device extension count
Previously, the logic to get the pProperyCount in
terminator_EnumerateDeviceExtensionProperties when pProperties is null did
not check for duplicates. This meant that the subsequent call to
vkEnumerateDeviceExtensionProperties could write fewer extensions out as
duplicates aren't allowed. This commit should make it so that two calls
to vkEnumerateDeviceExtensionProperties return the same pPropertyCount's
Change-Id: I5d5513673322c02ed78dff5bb85605334beb5c6c
Mark Lobodzinski [Wed, 18 Mar 2020 15:52:53 +0000 (09:52 -0600)]
travis: Remove GN build failures from 'allowed' list
GN build failures will now cause the travis builds to fail.
Change-Id: I985e4b8da6c151fc5c18cd5a82e4d074fcfb838d
Shannon McPherson [Tue, 17 Mar 2020 18:11:59 +0000 (12:11 -0600)]
build: Update known-good for 1.2.135 header
Updated `CMakeLists.txt` and `common_codegen.py` to allow access to beta
types and commands when including `vulkan.h`. Generated new loader
header files.
Change-Id: I7241ff08cf9d70cd22472735f53d8f6d72fb8a46
Simon McVittie [Tue, 17 Mar 2020 19:03:37 +0000 (19:03 +0000)]
FindVulkanHeaders: Match header lines more precisely
In recent versions of Vulkan-Headers, we need to avoid matching the line
that defines VK_HEADER_VERSION_COMPLETE, because that would result in
thinking the micro version was 1 instead of the correct 134.
Change-Id: I9047e207c5a0bd4612908f16a9742c3cb1659348
Fixes: https://github.com/KhronosGroup/Vulkan-Loader/issues/352
Signed-off-by: Simon McVittie <smcv@collabora.com>
Joshua Ashton [Thu, 12 Mar 2020 22:57:49 +0000 (22:57 +0000)]
loader: Handle no surface for surface caps 2 funcs
Change-Id: I8b7b586bd7f3e15e5e0d41a325c1dd51dfd48427
Joshua Ashton [Thu, 12 Mar 2020 04:42:26 +0000 (04:42 +0000)]
loader: Migrate get surface caps 2 funcs to wsi
This was not exported correctly unlike other wsi funcs
Fixes #342
Change-Id: I456e3c495a05da8ff3063d7de9d970c0e52d45c8
Charles Giessen [Thu, 12 Mar 2020 18:03:41 +0000 (12:03 -0600)]
loader: Fix skipping all layers if one bad is found
The logic for loaderScanForLayers would jump to out if any issue was found
loading any layer. This prevented any correct layers from being detected.
The other fix is in loader_get_json to return if the length is zero,
which would cause a VK_ERROR_OUT_OF_HOST_MEMORY to be thrown because
cJSON_Parse would fail.
Change-Id: Ie7a5de5d0f38edd9b9012b9cd22fecd9ed86eb5c
Charles Giessen [Tue, 10 Mar 2020 22:59:13 +0000 (16:59 -0600)]
loader: fix crash when json doesn't contain an object
When `loaderAddLayerProperties` has a json that doesn't contain an object as
the topmost value, it segfaults when looking for the `file_format_version`.
This commit fixes it by making sure the json is of the correct type before
proceding.
Files modified:
loader/loader.c
Change-Id: I4a624e3627d5f35a1a37ec4a17b03a3926ba5907
Shannon McPherson [Wed, 11 Mar 2020 17:20:15 +0000 (11:20 -0600)]
build: Update known-good for 1.2.134 header
Change-Id: I01d0ff7ac2adcaca8630eb58755ebc8852c39c8d
Mark Lobodzinski [Thu, 20 Feb 2020 19:05:43 +0000 (12:05 -0700)]
loader: Remove standard_val refs from LoaderLayerIF doc
Change-Id: I1f76bda5ff497def8522690367ee86d19a40e5e2
dan sinclair [Wed, 19 Feb 2020 02:40:29 +0000 (21:40 -0500)]
Move BUILD_TESTS option up as well
dan sinclair [Wed, 19 Feb 2020 02:22:13 +0000 (21:22 -0500)]
Allow Vulkan-Headers to be in externals.
This CL updates the CMake files to allow Vulkan-Headers to be in the
external folder. If the externals/Vulkan-Headers folder is present the
scripts will use that version of the headers.
Lenny Komow [Wed, 19 Feb 2020 22:48:15 +0000 (15:48 -0700)]
loader: Remove queue info count check
The loader isn't supposed to do error checking unless layers are unable
to do so. This is a check that belongs in the layers
Change-Id: I89428210138d147be1b8d5c548377adeabe34d64
Bas Nieuwenhuizen [Sun, 19 Jan 2020 18:47:31 +0000 (19:47 +0100)]
loader: Deal with failure loading implicit layer libraries.
If the error is not dealt with, we'll end up calling dlclose(NULL)
later.
Georg Lehmann [Sat, 15 Feb 2020 17:41:34 +0000 (18:41 +0100)]
loader: correct the name of vkNegotiateLayerInterfaceVersion
There is no vkNegotiateLayerInterfaceVersion as far as I know.
The correct name is vkNegotiateLoaderLayerInterfaceVersion.
Shannon McPherson [Mon, 17 Feb 2020 21:49:43 +0000 (14:49 -0700)]
build: Update known-good for 1.2.133 header
Change-Id: I2899494f9f76a914aee6b376e278d19e1b03e271
Cody Northrop [Thu, 6 Feb 2020 15:08:09 +0000 (08:08 -0700)]
loader: Avoid clang warning about parentheses
GN build was getting the following:
error: using the result of an assignment as a condition without
parentheses [-Werror,-Wparentheses]
Fixes #326
Charles Giessen [Wed, 5 Feb 2020 20:54:15 +0000 (13:54 -0700)]
loader: secure_getenv change logging WARN to INFO
Validation Layer tests failed due to using LOADER_WARN_BIT, changing it to LOADER_INFO_BIT as
its more appropriate.
Change-Id: I3abf97796e1f1167f22538343bf22781d1125317
Charles Giessen [Mon, 27 Jan 2020 20:26:48 +0000 (13:26 -0700)]
loader: don't unconditionally add std-val meta layer
Previously, the standard-validation meta layer would always be added
to the list in loaderScanForLayers. This results in erroneous reporting
of its existance when querying for layers. This code is no longer
needed as the std-val meta layer is a proper layer which is included
in the sdk.
Changes to be committed:
modified: loader/loader.c
modified: loader/loader.h
modified: loader/trampoline.c
Change-Id: Ib8dacf82db95cd50b02cb51b1ae688d2873cbbee
Lenny Komow [Wed, 5 Feb 2020 08:31:43 +0000 (09:31 +0100)]
loader: Fix buffer size updates in registry search
This causes the loader to properly update buffer sizes when reading
Windows registries.
Change-Id: I5fa0d86757177c8acac45871862995e3bacfc732
Lenny Komow [Tue, 4 Feb 2020 21:45:33 +0000 (22:45 +0100)]
loader: Add core 1.2 functions to gpa_helper
Change-Id: Ida875db5067265d67ddeae2843d5cf6a258c2693
Charles Giessen [Mon, 3 Feb 2020 17:28:04 +0000 (10:28 -0700)]
loader: add null check to loaderValidateLayers
The loader will now make sure to check if utf8 is null before
validating the string, preventing needless segfaults.
Change-Id: I48139e56719e3c518b85f2ded1ca0b682447413f
Charles Giessen [Tue, 4 Feb 2020 18:35:29 +0000 (11:35 -0700)]
loader: Warn when loader_secure_getenv() fails
Whenever a call to loader_secure_getenv() fails and returns a
NULL, the loader will now issue a warning that the environment
variable requested will be ignored.
Change-Id: I2ebdfad2f842cf3dda69a359da31124e6f1eabc2
Lenny Komow [Sat, 1 Feb 2020 01:52:04 +0000 (18:52 -0700)]
build: Regenerate files for debug utils changes
Change-Id: Ia59f3c34addca92cfa22f4396ea30deb445a1ffc
Lenny Komow [Fri, 31 Jan 2020 22:25:46 +0000 (15:25 -0700)]
loader: Fix debug utils terminators being skipped
Change-Id: I9e08b59669bd301e3c5361ae4ea16102461fb34b
Shannon McPherson [Tue, 28 Jan 2020 22:07:22 +0000 (15:07 -0700)]
build: Update known-good for 1.2.132 header
Change-Id: I8607a9a279525391298eb2aceb0078faa8f32fce
Charles Giessen [Mon, 20 Jan 2020 16:57:46 +0000 (09:57 -0700)]
Fix spelling mistakes
Several comments and one error message contained spelling mistakes.
This commit fixes it.
Changes to be committed:
modified: loader/loader.c
modified: loader/vk_loader_platform.h
Change-Id: Ida86de154b1c1e80c1d251ce71246a06ab038e2d
Lenny Komow [Mon, 27 Jan 2020 16:56:52 +0000 (09:56 -0700)]
loader: Update comments for shared aliases
Change-Id: Ic21f144a99345d6ab78d019bfec852390e415fb7
Shannon McPherson [Fri, 24 Jan 2020 20:57:45 +0000 (13:57 -0700)]
loader: Update copyright date to include 2020
`loader.rc` copyright date was updated
Change-Id: Id520e571bb0fa3705f945deb8eeca1eda29011a1
Mark Lobodzinski [Wed, 22 Jan 2020 21:00:20 +0000 (14:00 -0700)]
loader: Improve 1.2 promoted extension fix
Change-Id: I33ea7c685c0d91119fed20b503408c7709210833
Mark Lobodzinski [Wed, 22 Jan 2020 19:47:46 +0000 (12:47 -0700)]
loader: Fix handling of promoted device extensions
Change-Id: Ia301f1bcde6f9fa7252ee4a665821b4a3d72d269
Mike Schuchardt [Thu, 16 Jan 2020 00:15:27 +0000 (16:15 -0800)]
Fix GN build
Vulkan-Headers uses a new build_override include to toggle x11 support
Mike Schuchardt [Fri, 20 Dec 2019 22:19:40 +0000 (14:19 -0800)]
build: Header update for 1.2.131
Change-Id: I1adcfac93f39d869085e90f0fab69faccbfbe77d
Mike Schuchardt [Tue, 22 Oct 2019 04:12:53 +0000 (21:12 -0700)]
scripts: Tweak extension detection
Use tag type instead of feature name
Lenny Komow [Fri, 30 Aug 2019 16:53:16 +0000 (10:53 -0600)]
scripts: Add support for Vulkan 1.2 codegen
Change-Id: I37985dae01a0d17d02d3ba8e8a290cb2d155239b
Lenny Komow [Fri, 30 Aug 2019 16:54:56 +0000 (10:54 -0600)]
loader: Add support for Vulkan 1.2
Change-Id: Iad8d930ad6ff9eb9493fa3e72178f0d00698b09d
Charles Giessen [Mon, 13 Jan 2020 20:14:40 +0000 (13:14 -0700)]
loader: Remove loader_platform_basename dead code
The loader_platform_basename function is not being used anywhere
else and was last modified 4 years ago. Considering the amount of
TODO comments and mentions to replace this, there doesn't seem
like a pressing need to keep it.
Changes to be committed:
modified: loader/vk_loader_platform.h
Change-Id: Icd7a4d1104889e0519081831fbfaaaa46690438c
Lenny Komow [Thu, 12 Dec 2019 22:38:07 +0000 (15:38 -0700)]
loader: Add custom terminator to tool properties
Since vkGetPhysicalDeviceToolPropertiesEXT is implemented in the layers
and not drivers, this changes the terminator to never call into the
driver.
Change-Id: I3beb92ab5c327672f21a17b857068968099c2345
Caio Marcelo de Oliveira Filho [Tue, 10 Dec 2019 19:23:23 +0000 (11:23 -0800)]
build: Fix Vulkan registry detection
Fix incomplete VULKAN_REGISTRY_PATH_HINT for the case where
VULKAN_HEADERS_INSTALL_DIR is not specified. The hint extracted the
DIRECTORY of the include dir (e.g. "/usr"), but missed the rest of the
expected path for finding vk.xml (e.g. "/usr/share/vulkan/registry").
Tested with CMake 3.16.0.
Fixes: 18664450a ("build: Fix Vulkan headers detection with CMake.")
Lenny Komow [Wed, 11 Dec 2019 22:09:29 +0000 (15:09 -0700)]
codegen: Fix crash in tooling info terminator
Change-Id: I5835b73874bd3a8de9330c3244f456545c342ff3
Mark Lobodzinski [Mon, 9 Dec 2019 22:51:19 +0000 (15:51 -0700)]
build: Update for 1.1.130 header version
Change-Id: Ie76beb6ec3eb24ca8a0d2d9c16646ca062e3278c
Nico Weber [Fri, 6 Dec 2019 02:01:05 +0000 (21:01 -0500)]
Fix a bug found by clang's -Wsizeof-array-div.
Tobin Ehlis [Wed, 27 Nov 2019 19:31:37 +0000 (12:31 -0700)]
build:Add def file for Windows GN build
Add vulkan-1.def as a source file for windows GN build and rename
windows target to "vulkan-1" so that functions are correclty
exported for GetProcAddress() lookup.
Fixes #292
Shannon McPherson [Tue, 26 Nov 2019 20:01:27 +0000 (13:01 -0700)]
build: Update known-good for 1.1.129 header
Change-Id: I4a16e33c467a266f84aa38cc699c1e26d44f5b7c
Mike Schuchardt [Sat, 23 Nov 2019 03:35:35 +0000 (19:35 -0800)]
build: Add Cfgmgr32.lib to GN build
Appears to be needed for registry queries
Lenny Komow [Fri, 27 Sep 2019 20:49:37 +0000 (14:49 -0600)]
loader: Remove code for building a static loader
Change-Id: Id795e795a52ace1bf3c0c0fdbc5aed19d05bef01
Lenny Komow [Fri, 27 Sep 2019 20:16:26 +0000 (14:16 -0600)]
repo: Remove the option to build a static loader
This option should not have been used, as an application that statically
links to the loader is likely to break as a result of driver updates.
Change-Id: I6bc05ac6fac601f439274fd8efeb0cd76564ccd1
David 'Digit' Turner [Tue, 19 Nov 2019 17:52:26 +0000 (18:52 +0100)]
build: Fix Vulkan headers detection with CMake.
The logic used to find the location of the Vulkan headers and
registry used simple find_path() calls with HINTS. Unfortunately,
this doesn't work when using a custom toolchain file that sets
CMAKE_FIND_ROOT_PATH_INCLUDE to ONLY, which can happen when
cross-compiling with a custom sysroot.
This patch changes the logic so that:
- If VULKAN_HEADERS_INSTALL_DIR is specified on the command-line,
or if it is set in the environment, or if VULKAN_SDK is set in
the environment, the corresponding paths will be searched for
the Vulkan headers and register, ignoring the
CMAKE_FIND_ROOT_PATH. This does not affect other parts of the
build.
- Otherwise, use a regular find_path() call which may be restricted
to the CMAKE_FIND_ROOT_PATH depending on previous configuration
settings.
This should be equivalent to the previous behaviour, except when
CMAKE_FIND_ROOT_PATH_INCLUDE is set to ONLY.
Jonah Ryan-Davis [Fri, 8 Nov 2019 21:26:45 +0000 (16:26 -0500)]
loader: Use unsafe file search for GN builds
ANGLE is failing to locate validation layers on some platforms because
it cannot access VK_ICD_FILENAMES and VK_LAYER_PATH. This ensures that
these variables will always be picked up.
Shannon McPherson [Mon, 18 Nov 2019 18:07:23 +0000 (11:07 -0700)]
build: Update known-good for 1.1.128 header
Change-Id: I05a369dd1fa9db2a53884193c5740f105c62b197
Jonah Ryan-Davis [Wed, 6 Nov 2019 20:02:37 +0000 (15:02 -0500)]
Fix build errors on Windows GN
DXGI was changed to load dynamically. These changes need
to be propagated to GN.
Shannon McPherson [Mon, 4 Nov 2019 17:48:06 +0000 (10:48 -0700)]
build: Update known-good for 1.1.127 header
Change-Id: I4abc51b448f786b3633b6cfcba0c18f873bb684d