summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2017-05-18Add missing FindKMS.cmake fileHEADmasterKeith Packard1-0/+33
Signed-off-by: Keith Packard <keithp@keithp.com>
2017-05-17Add VK_KEITHP_kms_display extensionKeith Packard13-3/+114
This allows the application to provide an existing DRM device file descriptor into the vulkan drivers instead of having the driver open the device itself. There is additional information provided about the desired mode to set on the device; that will be used to apply a mode set on the first presentation request and to restore the mode after a VT switch has occurred. Signed-off-by: Keith Packard <keithp@keithp.com>
2017-05-02layers: Migrate surface support check to corePetr Kraus3-72/+24
- fix memory leak of `pQueueFamilyIndexSupport` - remove vestige of queue family support check
2017-05-02layers: Convert capability handling to dataChris Forbes1-154/+69
Replace the huge switch + duplicated calls with a map of ptr-to-member.
2017-05-02layers: Fix validation of compute pipelinesChris Forbes1-1/+1
skip handling was inverted for this case.
2017-05-02layers: Remove check for imageExtent == currentExtentCort Stratton1-12/+0
The condition tested in this check is only valid on platforms where the swapchain dimensions must match the surface dimensions (e.g. Windows, Xlib). In such cases, the surface *must* report minExtent == maxExtent == currentExtent, and this check would already be handled by the code directly above the deleted check. Platforms like Android allow the swapchain's imageExtent to be anywhere within the surface minExtent/maxExtent range; if this does not match the surface dimensions, it will be scaled accordingly.
2017-05-02layers: Invert old 'pass' checks for shader validationChris Forbes1-193/+154
Make this consistent with everything else, which uses 'skip'.
2017-05-02cube: Throttle rendering rather than presentationDamien Leone2-24/+7
It is currently impossible to reliably throttle presentation per the Vulkan spec. The previous code was relying on fences returned by vkAcquireNextImageKHR() to throttle. The only information this fence holds is whether it is possible to render to that image since the *last time* it was presented, which could have happened several frames ago. Instead, we can throttle the rendering by passing a fence to vkQueueSubmit(). The previous code (only the cube.c version) was using a fence there to synchronize a vkMapMemory() in demo_update_data_buffer(), which doesn't seem necessary. Before this commit, we were effectively throttling to the number of frames in the swapchain rather than on FRAME_LAG. In the FIFO present mode, this could schedule too much work in the presentation channel (since we have to account for VBLANK events) and thus causing undesired side effects, such as stutters when trying to move the cube window on a desktop, which is I assume why the throttle code was added in the first place.
2017-05-01tests: Fix LongSemaphoreChain bad indexingChris Forbes1-2/+9
If semaphores.size() == 1, we'd call operator[] with -1. You get away with this on most STLs, but the MS debug STL (right) complains that this is nonsense.
2017-05-01layers: Fix LayoutFromPresentWithoutAccessMemoryReadChris Forbes1-6/+10
This wasn't updated when I relaxed the implementation in a previous PR. Make this into a positive test since it's now correct usage.
2017-05-01tests: gh1602 - Add define for PRIxLEAST64Mark Young1-1/+4
In C++, you need to define __STDC_FORMAT_MACROS prior to including 'inttypes.h' in order for it to properly expose PRIxLEAST64. For some reason, many platforms expose this anyways without the define, but some dont. Change-Id: I1f6b6401540c1b84d95525cbe1ebc649f6f2d393
2017-05-01layers: Don't insist on memory dependency for presentChris Forbes1-4/+11
When transitioning to/from VK_IMAGE_LAYOUT_PRESENT_SRC_KHR we don't need to insist on VK_ACCESS_MEMORY_READ_BIT. On the transition TO, it's automatically handled; in the transition FROM, it's a WAR hazard rather than RAW/WAW so only the execution dependency is needed. Fixes #1717.
2017-04-29layers: Rewrite VerifyQueueStateToSeq to be less wastefulChris Forbes1-25/+51
When we have the same queue appearing multiple times in the dependency tree of the operations between queue->seq and seq, we would scrub that part of the submission list recursively, potentially to a great depth, eventually blowing the stack. [This used to work fine when it was done as part of RetireWorkOnQueue, as we'd have brought queue->seq up as we went, and the recursive call would end up doing no work.] Instead, explicitly track where we're up to on each queue as well as where we'd like to be, and use an explicit stack of work to do rather than using the call stack. Fixes crash in VkLayerTests.LongSemaphoreChain with 32k semaphores. V2: Explain what's going on V3: Tweak for windows build
2017-04-29tests: Add a test for a long semaphore chainChris Forbes1-0/+44
This is adapted from the long fence chain test, but uses intra-queue semaphores between each empty batch instead of just dropping fences. This triggers pathological recursion in CV, leading to a stack overflow.
2017-04-29external_revisions: bump spirv-toolsChris Forbes5-5/+5
CV needs the new bitpattern interface for specialization. V2: also bump for android V3: also bump headers V4: also bump shaderc for android build
2017-04-28layers: Change size of D32_SFLOAT_S8_UINTDave Houlton1-1/+1
Change the size of the other format with 'optional' bytes, to be consistent with the X8_D24_UNORM_PACK32 change. We'll now assume the optional bytes when calculating buffer/image sizes for these formats. Change-Id: I7c194b85611795cc680f76de04513c3b45a88c4b
2017-04-28layers: Change size of X8_D24_UNORM_PACK32Tony Barbour1-1/+1
Change-Id: If049e2afaea83f0a705a7031888d4278784be49d
2017-04-28tests: Update vkCreateFramebuffer testsCort Stratton3-62/+66
- Add tests for width/height/layers of zero. - Fix one VU check that wasn't using its corresponding error code. - Migrate string-based tests to error-code-based variants. - database update.
2017-04-28layers: Add check for VkFramebuffer dimensions of zeroCort Stratton1-0/+19
2017-04-27layers: Guard checks of pQueueFamilyIndicesTony Barbour1-4/+4
Only examine pQueueFamilyIndices if sharingMode is VK_SHARING_MODE_CONCURRENT This fixes a crash in CTS when sharing mode was VK_SHARING_MODE_EXCLUSIVE and queueFamilyIndexCount was VK_QUEUE_FAMILY_IGNORED Change-Id: I72b1f140e8949e711723e98bdaead15655ab07a5
2017-04-27tests:Test VALIDATION_ERROR_00302Tobin Ehlis2-8/+12
InvalidBarriers test was already checking case VALIDATION_ERROR_00302 but it was doing so based on setting COLOR aspect bit. Add another case where depth bit is excluded and verify that error is correctly triggered.
2017-04-27layers:Add barrier imageAspect check for DS imageTobin Ehlis2-1/+17
Fixes #1703 Add validation check to make sure that both depth & stencil aspects of DS images are transitioned in image memory barrier.
2017-04-26demo/smoke Android build update: use latest cmake with Android Studioguanghuafan4-78/+88
2017-04-26winsdk: Make copyright signature editableLenny Komow1-1/+4
Change-Id: Ie28b5d1e5ba7fbd727122399ef1f35d1eb54305a
2017-04-27layers: Remove GLOBAL_CB_NODE::imageSubresourceMapChris Forbes3-9/+1
This served no purpose. We can get the same result in the one place that matters, by consulting GLOBAL_CB_NODE::imageLayoutMap
2017-04-26tests: clang-format of layer_validation_tests.cppDave Houlton1-28/+22
Change-Id: Ia893e5544b445be37f3906c560f085450efbc6bc
2017-04-26tests: Add VU code to error string (DEBUG only)Dave Houlton1-0/+6
With thousands of VUs and many with similar text strings, it can be difficult to identify a particular error message at a glance. This adds the VU code to the end of the message string (in DEBUG builds). Change-Id: I8ff2dfbac4973613193b6410bda885c187cf5920
2017-04-26loader: gh1681 - Restrict error in JSONMark Young1-3/+9
Restrict the loader's JSON errors when reading ICD manifest files to only return an overall error if there are no valid drivers. Change-Id: I10edb1cdc7e4db9cfdc0b3595416f0614ed22867
2017-04-26ci: Add myself to mail recipientsChris Forbes1-0/+1
2017-04-26layers: Fix some function name passingChris Forbes1-6/+6
- This was constructing a temporary std::string for no reason - Missing () as other similar cases use.
2017-04-26layers: Drop unused param for SetSparseMemBindingChris Forbes1-5/+4
There is only one function that can call this, and we didn't care anyway.
2017-04-26layers: fix typo in vkCmdExecuteCommands error stringsChris Forbes1-3/+3
2017-04-26layers: Drop dead device param to CreatePassDAGChris Forbes1-2/+2
2017-04-26layers: Simplify slightlyChris Forbes1-9/+5
2017-04-26layers: Fix format utils SSCALED/USCALED descriptionsChris Forbes1-2/+2
These aren't about colorspaces -- comment was previously mangled from sRGB case.
2017-04-26layers: Inline deleteCommandBuffers into sole callerChris Forbes1-12/+4
2017-04-26layers: Fix more VkBool32 vs boolChris Forbes1-1/+1
2017-04-26layers: Fix 'secondary' typoChris Forbes1-1/+1
2017-04-26layers: Fix more signedness noiseChris Forbes1-1/+1
2017-04-26layers: Use format utils rather than open-coded list in SCChris Forbes1-54/+10
2017-04-26layers: Drop layer_data from some leaf funcs that dont use itChris Forbes1-9/+8
2017-04-26layers: Fix some signedness messChris Forbes1-1/+1
2017-04-26layers: Fix some confused VkBool32 vs boolChris Forbes2-4/+4
These aren't the same type!
2017-04-26layers: Simplify DESCRIPTOR_POOL_STATEChris Forbes1-21/+8
Just use safe_* here rather than copying things manually.
2017-04-26layers: Remove dead update_cmd_buf_and_mem_referencesChris Forbes1-22/+0
No callers.
2017-04-25layers:Validate display_timing swapchainCountTobin Ehlis2-1/+15
For the VK_GOOGLE_display_timing extension validate that the swapchainCount in the VkPresentTimesInfoGOOGLE extension struct matches the swapchainCount in the VkPresentInfoKHR struct. Update unique ID database.
2017-04-25layers:Validate objects for display_timingTobin Ehlis3-12/+16
Update object_tracker validation for swapchain objects in new functions for VK_GOOGLE_display_timing extension. Add in missing Error IDs and update database.
2017-04-25layers: Fix enum use in GetStateStructPtrFromObjectChris Forbes1-14/+14
Everything around this was updated to use the new enums, but not this function. Mostly works by accident since many of these coincide.
2017-04-25layers: Inline VkCommandBuffer overload of clear_cmd_buf_...Chris Forbes1-5/+1
This was silly. On the very next line, we called GetCBNode again.
2017-04-25layers: Drop dead string conversion for command typesChris Forbes1-98/+0
No callers.