Tobin Ehlis [Thu, 22 Dec 2016 18:19:15 +0000 (11:19 -0700)]
scripts:Update stat script output
Improve stats script to output the filename and line numbers where a
unique error enum is being re-used. This makes it simple to pick
through the duplicates and evaluate them.
Tobin Ehlis [Thu, 22 Dec 2016 18:00:07 +0000 (11:00 -0700)]
layers:Fix unique error enum
ResetCommandBuffer valid commandBuffer handle is id *00094, not *00090.
This was causing 90, which is for allocation, to be incorrectly reused.
Lenny Komow [Fri, 23 Dec 2016 21:12:18 +0000 (14:12 -0700)]
build: Parameterize def file name
Change-Id: I697c856b7c7532a38823302a4decf78cdea583ae
Frank Henigman [Fri, 23 Dec 2016 19:22:36 +0000 (14:22 -0500)]
layers: remove unused variable
Mike Weiblen [Thu, 15 Dec 2016 19:24:24 +0000 (12:24 -0700)]
layers: Update Valid Usage enums (VL-61, final)
Update Valid Usage enums in a subsection of core_validation.cpp.
Refactored some helper functions to add parameter for msgCode.
Removed check that was redundant with object_tracker.
Update VU status in the database.
Fix a couple other typos.
This completes Jira task VL-61.
Change-Id: Ie7f11741892c68331b70bb1b611f5c80fe930018
Dave Houlton [Thu, 1 Dec 2016 23:43:06 +0000 (16:43 -0700)]
layers: add VU checks in image.cpp (Jira VL-66)
Updated existing validation checks in image.cpp to new VU
enums with minor refactoring only. Left TODOs for other
VUs that will require more extensive redesign. Updated VU
database to match. Also minor updates to
layer_validation_tests to account for changed error
messages.
Change-Id: Ib6cc0e360ceeaae256b0cd0f1d272fe127c95419
Tobin Ehlis [Wed, 21 Dec 2016 19:37:16 +0000 (12:37 -0700)]
layers:Refactor CmdDispatchIndirect()
Refactor CmdDispatchIndirect() to use pre/post pattern. Use shared
validate/update functions along with extra code to handle the
validation and state update of the buffer used for indirect call.
Tobin Ehlis [Wed, 21 Dec 2016 19:26:38 +0000 (12:26 -0700)]
layers:Refactor CmdDispatch()
Refactor CmdDispatch() to use pre/post pattern. Updated the DrawType
helper functions for use with Dispatch functions as well. For the
update helper, broke that out into a separate DrawDispatch helper
that does common work, and then a Draw helper that calls the
DrawDispatch helper and then does some extra work only relevant
for draw calls.
Tobin Ehlis [Wed, 21 Dec 2016 19:22:11 +0000 (12:22 -0700)]
layers:Refactor CmdDrawIndexedIndirect()
Refactor CmdDrawIndexedIndirect() to use pre/post pattern.
Tobin Ehlis [Wed, 21 Dec 2016 18:21:36 +0000 (11:21 -0700)]
layers:Refactor CmdDrawIndirect() to use pre/post
Refactor CmdDrawIndirect() to use pre/post pattern and helper functions
for DrawType validate and update. There's a bit of extra validation and
state update that goes along with the buffer passed to this function vs
the Draw & DrawIndexed versions.
Tobin Ehlis [Wed, 21 Dec 2016 18:04:13 +0000 (11:04 -0700)]
layers:Refactor CmdDrawIndexed()
Refactor CmdDrawIndexed() to use Pre/Post pattern. Added validate and
update helper functions that should work for all four CmdDraw*
functions and initiall changed CmdDraw() and CmdDrawIndexed() to use
the helpers. Will update remaining two functions in follow-on CLs.
Tobin Ehlis [Wed, 21 Dec 2016 17:28:54 +0000 (10:28 -0700)]
layers:Improve perf warning for unused vtx buffer
Fixes #1282
Track if a vtx buffer is ever used by a cmd buffer and only flag perf
warning if cmd buffer has a Draw added with a bound vtx buffer that has
never been used.
Tobin Ehlis [Wed, 21 Dec 2016 16:54:09 +0000 (09:54 -0700)]
layers:Kill synchAndPrintDSConfig() function
Delete synchAndPrintDSConfig() and related functions.
Lots of informational prints that aren't needed.
Tobin Ehlis [Wed, 21 Dec 2016 16:21:06 +0000 (09:21 -0700)]
layers:Split ValidateAndUpdateDrawState()
Split ValidateAndUpdateDrawState() to isolate validation and state
updates into ValidateDrawState() & UpdateDrawState() functions.
Refactored CmdDraw() to use Pre/Post patter with all state updates now
occurring in the Post function. Made some initial updates to other
Draw/Dispatch functions to call each new function in-line, but will
refactor these functions to use Pre/Post in follow-on commits.
Tobin Ehlis [Wed, 21 Dec 2016 15:30:22 +0000 (08:30 -0700)]
layers:Split validatePipelineDrawtimeState()
Split validatePipelineDrawtimeState() into validate & update functions.
Also rename validatePipelineDrawtimeState() to
ValidatePipelineDrawtimeState().
Tobin Ehlis [Wed, 21 Dec 2016 15:15:27 +0000 (08:15 -0700)]
layers:Rename two functions to CamelCase
Tobin Ehlis [Wed, 21 Dec 2016 14:52:20 +0000 (07:52 -0700)]
layers:Add PostCallRecordCmdDraw()
Add PostCallRecordCmdDraw() to perform state updates for CmdDraw()
function. Don't quite have all state updates in there yet. Remaining
state updates will be in follow-on commit.
Tobin Ehlis [Mon, 19 Dec 2016 22:59:16 +0000 (15:59 -0700)]
layers:Separate state update from addCmd()
Update addCmd() function to only perform validation and rename it to
ValidateCmd(). Separate out the state update of last_cmd in cmd buffer
to new UpdateCmdBufferLastCmd() function.
Made sure that everywhere ValidateCmd() is called now also calls
UpdateCmdBufferLastCmd(). Currently just calling them back-to-back but
will continue with further updates that put the ValidateCmd() call into
the PreCallValidate*() function and the UpdateCmdBufferLastCmd() into
the PostCallRecord*() function.
Also included some comments on work that needs to be done while
breaking up CmdDraw() for pre/post functions.
Tobin Ehlis [Mon, 19 Dec 2016 22:20:53 +0000 (15:20 -0700)]
layers:Pass cmd buffer as log_msg object
Fix some old TODOs where cmdBuffer was not being correctly passed into
log_msg as the src object.
Tobin Ehlis [Mon, 19 Dec 2016 22:16:37 +0000 (15:16 -0700)]
layers:Remove unneeded return value
MarkStoreImagesAndBuffersAsWritten() only updates state and the return
value was a constant false. Update function to remove the return value.
Michael Jurka [Mon, 19 Dec 2016 15:31:43 +0000 (16:31 +0100)]
loader: clean up comment and variable
Make one variable's name plural to clarify that it
contains more than one layer. Also, clean up a
comment that wrapped prematurely to the next line.
Rene Lindsay [Fri, 23 Dec 2016 00:11:09 +0000 (17:11 -0700)]
tests: Fix tests for VALIDATION_ERROR_01263+01264
Change-Id: I4e080ae2b7fa77d722a6065e8d2511a35a31ca32
Michael Jurka [Mon, 19 Dec 2016 15:31:43 +0000 (16:31 +0100)]
Use Python instead of greadlink to get full path on macOS
Python is built-in on Macs; this avoids an unnecessary dependency on greadlink
Lenny Komow [Thu, 22 Dec 2016 22:29:43 +0000 (15:29 -0700)]
loader: Fix out of memory in enumerate phys devs
Change-Id: I9f25875f065f7db58f9c8841965ba1f2f974de90
Tobin Ehlis [Thu, 22 Dec 2016 17:42:36 +0000 (10:42 -0700)]
layers:Update dispatchable object printing
Fixes #1188
Uniformly print all dispatchable handles in error messages as pointers
with the "%p" print specifier.
Lenny Komow [Tue, 20 Dec 2016 22:35:11 +0000 (15:35 -0700)]
loader: Update term phys devices dynamically
Change-Id: Ib474a7af431746d9e820e188681d2a9310e94a0d
Lenny Komow [Tue, 20 Dec 2016 00:11:40 +0000 (17:11 -0700)]
loader: Update tramp phys devices dynamically
Change-Id: I693598b5c9f72ecee10661e3af9420941b2bd67c
Cody Northrop [Thu, 22 Dec 2016 18:12:49 +0000 (11:12 -0700)]
android: Preserve toolchain build if present
Similar to
a2e6ddd1 which preserves it for desktop.
Frank Henigman [Thu, 22 Dec 2016 03:21:41 +0000 (22:21 -0500)]
loader: guard gcc feature appropriately
Macro __GNUC__ should be used to guard gcc-specific code.
Also exclude clang because though it defines __GNUC__ it
doesn't accept this particular gcc feature.
Change-Id: I703289cad58e7675f4c4ca5e7635fc8fb35ae77e
Courtney Goeltzenleuchter [Wed, 21 Dec 2016 23:44:28 +0000 (16:44 -0700)]
Merge pull request #1300 from KhronosGroup/161221-fix_string_validation
loader: Fix validation error
Courtney Goeltzenleuchter [Wed, 21 Dec 2016 23:24:34 +0000 (16:24 -0700)]
loader: Fix validation error
The string length validation will not detect strings
that exceed the max length.
For example, when i = max_length-1 and utf8[i] is a valid
character (>= 0x20 and < 0x7f) no error is thrown and
the next iteration will end the loop.
This change extends the loop and the if check to
catch this issue.
Jamie Madill [Wed, 21 Dec 2016 18:09:59 +0000 (13:09 -0500)]
loader: Fix Clang warning in table_ops.h
This fixes the following warning:
error: cast between incompatible calling conventions 'cdecl' and 'stdcall'; calls through this pointer may abort at runtime
This was revelated by building the loader with Clang on Windows in
32-bits mode. In 64-bits this warning doesn't appear, presumably due
to different calling conventions.
Change-Id: I7018be38859695436487f582f515bfb08ca28e06
Michael Jurka [Mon, 19 Dec 2016 15:31:43 +0000 (16:31 +0100)]
layers: Add missing <string> dependency
Change-Id: Ib3c74be1e1d3c168720aaef4dafed1a6a04c7d9b
Rene Lindsay [Tue, 20 Dec 2016 21:05:37 +0000 (14:05 -0700)]
tests: Insert missing vkQueueWaitIdle()
This does not actually fix the Unexpected error message,
since the real problem is in the validation layers...
The call to vkQueueSubmit is triggering 2 error messages.
Is one redundant?
Change-Id: I4e28cc778dff7581c83cbe53240d1706f60253a7
Jeremy Hayes [Tue, 20 Dec 2016 22:20:25 +0000 (15:20 -0700)]
cmake: speed up the build
Remove old dependencies from cmake, which was causing long build times
even when nothing had changed.
Change-Id: Ie162606b54352306ae6400aa18e942d8cffb7782
Mike Weiblen [Tue, 20 Dec 2016 03:41:58 +0000 (20:41 -0700)]
layers: Update Valid Usage enums (VL-61, partial)
Update Valid Usage enums in a subsection of core_validation.cpp by
adding a parameter to helper functions insideRenderPass() and
outsideRenderPass(). Update that VU status in the database.
Fix a couple other typos.
This partially implements Jira task VL-61.
Change-Id: I8d1fe99a237c4cd22216a1236f47f72fffd4fd00
Mark Lobodzinski [Thu, 15 Dec 2016 21:14:28 +0000 (14:14 -0700)]
scripts: Remove enum/struct_validate_helper funcs
From vk_helper.py. These were not used in the codebase.
Change-Id: I3cc80e34eb831122ce8c54dbc004a003e02a47fe
Mark Lobodzinski [Thu, 15 Dec 2016 20:54:20 +0000 (13:54 -0700)]
layers: Remove unused header from threading/PV
vk_struct_validate_helper.h not used.
Change-Id: I19757e96900e0500f4db9355c38a497936706bba
Mark Lobodzinski [Thu, 15 Dec 2016 20:15:12 +0000 (13:15 -0700)]
layers: Remove redundant CreateRenderpass checks
From the image layer. The check for valid attachment layouts
and load/storeOps already performed in the parameter validation
layer. Also removed now-dead support function and unneeded
header file.
Change-Id: I4f1ad1ba899a712ba21ae32e3b3e2d947b640f4d
Mark Lobodzinski [Thu, 15 Dec 2016 20:06:55 +0000 (13:06 -0700)]
layers: Remove enum_validate_helper from PV
A single call was used, replaced with an internal generated function
call and removed the old include. Added note with validation error
ID.
Change-Id: Ied88daf5bab003269c44ef2bef8b2eb81a9e9094
Mark Lobodzinski [Wed, 14 Dec 2016 21:34:06 +0000 (14:34 -0700)]
layers: Remove unused threadchecker header file
Change-Id: I7906b82c1c9c0397113508da74348ea28fe21add
Chris Forbes [Mon, 19 Dec 2016 22:33:11 +0000 (11:33 +1300)]
layers: Remove cmds vector from GLOBAL_CB_NODE
Now that cmd buffer printing has been removed, the only use of this is
to distinguish between cmd buffers invalidated before and after a
complete recording. This should eventually be folded into the state
machine, but removing the vector of cmds is a first step.
Signed-off-by: Chris Forbes <chrisforbes@google.com>
Jamie Madill [Mon, 19 Dec 2016 20:59:18 +0000 (15:59 -0500)]
layers: Fix size_t-int cast warning in descriptor_sets
Discovered in VS2015.
Change-Id: I2a42209a9ee9bd0e8f3da21c0f1a613315d5a6ce
Tobin Ehlis [Mon, 19 Dec 2016 18:16:14 +0000 (11:16 -0700)]
layers:Clean up descriptor set layout on destroy
Erase destroyed descriptorSetLayout from map.
Tobin Ehlis [Mon, 19 Dec 2016 17:57:29 +0000 (10:57 -0700)]
layers:Add validation flag for DestroyBuffer()
Tobin Ehlis [Mon, 19 Dec 2016 17:53:58 +0000 (10:53 -0700)]
layers:Refactor DestroyBuffer()
Update DestroyBuffer() to use Pre/Post pattern. All of the state
updates are now only performed if call down chain is not skipped.
Tobin Ehlis [Mon, 19 Dec 2016 17:20:43 +0000 (10:20 -0700)]
layers:Add GetQueryPoolResults() validation flag
Tobin Ehlis [Mon, 19 Dec 2016 17:11:50 +0000 (10:11 -0700)]
layers:Refactor GetQueryPoolResults() to pre/post
Refactor GetQueryPoolResults() to use Pre/Post pattern. Pulled all of
the validation into PreCallValidate* function. There was only one
state update occuring so pulled that code into PostCallRecord function.
Tobin Ehlis [Fri, 16 Dec 2016 22:02:44 +0000 (15:02 -0700)]
layers:Add validation flag for DestroyQueryPool()
Tobin Ehlis [Fri, 16 Dec 2016 21:56:41 +0000 (14:56 -0700)]
layers:Refactor DestroyQueryPool
Refactor DestroyQueryPool() to use Pre/Post pattern. This moves the map
update to after the call down the chain which is where it should live
so that it only executes when validation passes.
Tobin Ehlis [Thu, 15 Dec 2016 21:36:56 +0000 (14:36 -0700)]
layers:Add validation flag for DestroySemaphore()
Tobin Ehlis [Thu, 15 Dec 2016 21:35:21 +0000 (14:35 -0700)]
layers:Add validation flag for DestroyFence()
Tobin Ehlis [Thu, 15 Dec 2016 21:32:22 +0000 (14:32 -0700)]
layers:Refactor DestroySemaphore
Refactor DestroySemaphore() to use Pre/Post pattern.
Tobin Ehlis [Thu, 15 Dec 2016 21:18:39 +0000 (14:18 -0700)]
layers:Refactor DestroyFence
Refactor DestroyFence() to use Pre/Post pattern.
Tobin Ehlis [Thu, 15 Dec 2016 18:37:02 +0000 (11:37 -0700)]
layers:Rename QUEUE_NODE to QUEUE_STATE
Tobin Ehlis [Thu, 15 Dec 2016 18:34:33 +0000 (11:34 -0700)]
layers:Refactor GetDeviceQueue
Move the state update for GetDeviceQueue into Post* function.
Jamie Madill [Tue, 13 Dec 2016 22:02:57 +0000 (17:02 -0500)]
layers: Make generators Python 2.7-compatible.
ANGLE and Chromium are fixed with Python 2.7, so we need to update
the generator to something that is compatible with 2.7 and 3.2.
The unicode handling is different between the two, so switch
scripts to use unicode literals (u'txt' instead of 'txt').
Change-Id: I1570a45e302a09bb1f99eabc84f50b2ec599944d
Mark Lobodzinski [Sun, 18 Dec 2016 16:42:23 +0000 (09:42 -0700)]
layers: Update VU database for scissor/vp checks
Updated status for 1430-1434444.
Change-Id: Ie31ff617dd30b1ef3850398ef100e874c3c1acb4
Mark Lobodzinski [Mon, 19 Dec 2016 15:43:21 +0000 (08:43 -0700)]
tests: Add checks for new scissor/viewport validation
Added tests for checks 1430-1433.
Change-Id: I66090077eb18083765d7383777e0d1e9c0cadbbc
Mark Lobodzinski [Mon, 19 Dec 2016 14:59:10 +0000 (07:59 -0700)]
tests: Rename scissor/vp count test and fix errors
Renamed test to add additional validatin checks, fixed an
unexpected error in test.
Change-Id: I013102f716795713ea2597cd5e54a79346eada29
Mark Lobodzinski [Sun, 18 Dec 2016 16:43:01 +0000 (09:43 -0700)]
layers: Add scissor/viewport count checks
Change-Id: I35977325f662d3e4df84d02d2eefa4383fae9c05
Mark Lobodzinski [Thu, 15 Dec 2016 22:49:59 +0000 (15:49 -0700)]
layers: GH1261, Incorrect ParamValidation error msgs
Out-of-date dynamic state errors incorrectly specified that viewport
or scissor counts had to be greater than zero 'if the dynamic state
bit was not specified'. Removed this confusing condition.
Change-Id: Idf206e8671b04979b7a0f5e9597e4a7aec50333f
Tobin Ehlis [Mon, 19 Dec 2016 13:47:53 +0000 (06:47 -0700)]
scripts:Update unique error enums as of 12/19/16
Six updates and some new valid usages.
Cmd to do the update was:
python spec.py -update -remap 127-132:128-141:1465-1263:2168-1646,2:2373-1965
Rene Lindsay [Fri, 16 Dec 2016 21:57:18 +0000 (14:57 -0700)]
tests: Fix Unexpected errors in InvalidMemoryAliasing
Change-Id: Ic6f7ade06c35eb45f671e19c5cfd2ada0b2daa4f
Mark Lobodzinski [Mon, 19 Dec 2016 16:41:16 +0000 (09:41 -0700)]
header: Update to Vulkan version 1.0.38
- header: Updated vulkan.h
- scripts: Updated generator.py
- scripts: Updated vk.xml
- scripts: Merged recent genvk.py changes into lvl_genvk.py
- layers: Updated json files
- loader: Updated SOVERSION to 38
- header: Updated vulkan.hpp
Change-Id: Id0f83c248169bd8b1e03a14c90a5f9b1661cfcc7
Mark Lobodzinski [Fri, 16 Dec 2016 21:54:59 +0000 (14:54 -0700)]
tests: Fix unexpected errs in viewport/scissor check
Fixed some issues in PSOViewportScissorsCountMismatch along with
some clang-format stuff.
Change-Id: Ib4324ea20eb55fdda78ab108fb69d515028fd1d2
Mark Lobodzinski [Fri, 16 Dec 2016 21:30:01 +0000 (14:30 -0700)]
tests: Fix unexpected errors in CGP state check
Fixed 4 issues in PSOViewportStateNotSet along with some clang-format
stuff.
Change-Id: I646b37e72df6fd7926b2f4c3d3156542eea07f78
Mark Lobodzinski [Fri, 16 Dec 2016 21:21:04 +0000 (14:21 -0700)]
tests: Fix unexpected errors in CGP viewports check
Fixed 4 issues in PSOViewportCountWithoutDataAndDynViewportMismatch,
fixed some clang-format stuff.
Change-Id: Ibf273b2c1d9d4db4ba94f680e082e5d4bc40c29e
Mark Lobodzinski [Fri, 16 Dec 2016 21:01:17 +0000 (14:01 -0700)]
tests: Fix unexpected errors in CGP scissor check
Fixed 3 issues in PSOViewportCountWithoutDataAndDynScissorMismatch,
fixed some clang-format stuff.
Change-Id: I65ad1ff193acc18a6ee9e96521b5dd5f2f196eb9
Mark Lobodzinski [Fri, 16 Dec 2016 20:20:57 +0000 (13:20 -0700)]
layers: Update error enum database
Signified coverage, LVTs for a handful of checks.
Change-Id: I0e0ac413f9b76793b325b96ef030ce4b90656315
Mark Lobodzinski [Fri, 16 Dec 2016 20:06:41 +0000 (13:06 -0700)]
layers: Remove redundant CV checks
These CreateGraphicsPipeline checks are covered in
parameter_validation.
Change-Id: I4c273aa2cd88791d2f6cfa7a5b6c48e629706a85
Mark Lobodzinski [Fri, 16 Dec 2016 20:17:49 +0000 (13:17 -0700)]
tests: Change CreateGraphicsPipelines desired errors
Switched from strings to numeric IDs.
Change-Id: I2cc23a0f9e77df2bb1ed579a100951b2c79c2b0d
Mark Lobodzinski [Fri, 16 Dec 2016 20:08:00 +0000 (13:08 -0700)]
layers: Move new check into parameter validation
Added an old CreateGraphicsPipelines CV check into PV.
Change-Id: I68310859e4ffc926502549b46a2fcc82af0e3538
Mark Lobodzinski [Sun, 18 Dec 2016 15:57:03 +0000 (08:57 -0700)]
tests: Update test ID to move from CV into PV
Changed test to look for error enum instead of string in preparation
for moving the check into parameter validation.
Change-Id: Ib25f56a39386da459ede41971ac8b49c2831ee8b
Rene Lindsay [Fri, 16 Dec 2016 01:47:11 +0000 (18:47 -0700)]
tests: Fix Unexpected error in VkLayerTest.InvalidDynamicOffsetCases
Tobin Ehlis [Thu, 15 Dec 2016 14:51:20 +0000 (07:51 -0700)]
layers:Refactor consecutive descriptor count
Refactor GetConsecutiveDescriptorCountFromBinding() to use the fact
that bindings are now stored in-order. No longer need to chase binding
order through the map, just get current binding index and then parse
rest of the binding array in-order.
Tobin Ehlis [Mon, 12 Dec 2016 22:59:34 +0000 (15:59 -0700)]
layers:Store DescriptorSetLayout class in-order
Sort the bindings in the internal data structure of the
DescriptorSetLayout class so that they're stored in binding order.
This commit keeps the interface and mapping structures the same.
Further commits will take more use of the fact that layout is now
stored in binding order.
Tony Barbour [Thu, 15 Dec 2016 21:52:44 +0000 (14:52 -0700)]
tests: Remove test for nonCoherentAtomSize check
Change-Id: I7ba25d6e0b8bf0623e386d04041070fbc505a129
Tony Barbour [Thu, 15 Dec 2016 19:12:29 +0000 (12:12 -0700)]
layers: Remove check for nonCoherentAtomSize
It's come to our attention that this check, while matching the spec,
may be a little overzealous and could cause a lot of existing code
to start failing validation. We plan to address this with the spec
working group, and we're removing the check for now.
Change-Id: I7159b72fe0a2e81bf75bccddc9939da7086992b7
Jamie Madill [Wed, 14 Dec 2016 22:21:43 +0000 (17:21 -0500)]
loader: Fix Clang warnings.
error: equality comparison with extraneous parentheses
error: comparison of array equal to a null pointer is always false
error: using namespace directive in global context in header
Change-Id: I52b5d9062653b9429b9c42b40eca54e71b6d794b
Mike Weiblen [Sat, 10 Dec 2016 00:36:28 +0000 (17:36 -0700)]
layers: Update Valid Usage enums (VL-70)
Reviewed the following 5 files' invocation of log_msg()
for opportunities to update for Valid Usage enums.
layers/threading.h
layers/vk_layer_logging.h
layers/descriptor_sets.cpp
layers/swapchain.cpp
layers/unique_objects.cpp
Split some composite checks apart, to better match the meaning of
individual VUs.
Added VU enums to a new file, and expanded the stats collection
script to include the new file.
Changed some placeholder uses of msgCode=="0" to
"VALIDATION_ERROR_UNDEFINED".
(0 is the value of the enum VALIDATION_ERROR_00000 which was misleading)
When Valid Usage enums were referenced, also updated the VU database.
Tweak #include order for Windows, to undo clang-format reordering.
Completes Jira task VL-70.
Change-Id: I550922b194e733f41316ae493098f70a54cbd64e
Jamie Madill [Thu, 15 Dec 2016 14:35:36 +0000 (09:35 -0500)]
layers: PR1276, Fix Clang compiler warnings
fixes
- error: using namespace directive in global context in header
- error: comparison of integers of different signs: 'uint32_t'
(aka 'unsigned int') and 'int'
Change-Id: If56d5b9c33f0de813fbb67120650a887eb9368b0
Mark Lobodzinski [Thu, 15 Dec 2016 14:42:57 +0000 (07:42 -0700)]
layers: Updated val error database with new checks
Updated status, applicable tests for errors 00669 and 02160.
Change-Id: Ia52d31f00820882fe2837928b6ab1702c57f26f5
Mark Lobodzinski [Thu, 15 Dec 2016 14:41:13 +0000 (07:41 -0700)]
tests: Add tests for GH1260, check for SparseBinding
Added a new test that checks two error cases -- if an image or buffer
is created with sparse_aliased or sparse_residency, it must also
have the sparse_binding bit set.
Change-Id: I08f9ff2cd67bc3dc6b9fcaf7672f7e2480008e72
Mark Lobodzinski [Wed, 14 Dec 2016 20:37:04 +0000 (13:37 -0700)]
layers: Updated error enums for sparse_binding checks
Change-Id: Ib76fcb782a54edf6e53d17fed0bcb25eecca22d9
Maciej Jesionowski [Wed, 14 Dec 2016 10:01:21 +0000 (11:01 +0100)]
layers: GH1260, SPARSE_BINDING_BIT validation
- add error message for size (error 00663)
- add error messages for buffer and image flags (error 00669 and 02160)
- remove obsolete TODOs
- fix a typo in vkCreateImage validation, add error code
Change-Id: I50d6111c4aed1b348119a9664ec299f7c2cb7884
Tony Barbour [Mon, 12 Dec 2016 18:50:20 +0000 (11:50 -0700)]
tests: Fix WriteDescriptorSetIntegrityCheck
Use correct descriptor types to create descriptor pool and pass
the intended number of VkDescriptorBufferInfo structures
Change-Id: I382d75858acbe30d408cbf5bf4f6dc46d1db605e
Tony Barbour [Tue, 13 Dec 2016 23:30:36 +0000 (16:30 -0700)]
tests: Fix issue with validation of positive tests
Change-Id: I466487c9a53d2b5ea1e8aa1c312c97ef6d5bb581
Mike Schuchardt [Tue, 13 Dec 2016 21:04:57 +0000 (14:04 -0700)]
layers: Fix object tracker memory leak
Upon repeated calls, GetDisplayPlaneSupportedDisplaysKHR will call
CreateObject multiple times with the same VkDisplayKHR handle. Add a
check in CreateObject for an existing tracking object before allocating
a new one.
Change-Id: I50f634fbe8b7e69edbfeb4e6f0c050b7fccaa6e4
Jamie Madill [Wed, 14 Dec 2016 18:05:05 +0000 (13:05 -0500)]
scripts: Add quiet option option to vk_helper.py.
Chromium typically does not allow build steps to output anything
during a build. This option allows for ANGLE to suppress normal
script output during execution.
Change-Id: I72695a80a5f25e9a2cf3f01832f3de63ca95b091
Chris Forbes [Thu, 8 Dec 2016 22:00:21 +0000 (11:00 +1300)]
layers: Complain in AcquireNextImageKHR if the swapchain is replaced
V2: Tweak error language for Ian
Signed-off-by: Chris Forbes <chrisforbes@google.com>
Chris Forbes [Thu, 8 Dec 2016 21:39:26 +0000 (10:39 +1300)]
layers: Track whether a swapchain has been replaced
If a swapchain is used as VkSwapchainCreateInfoKHR::oldSwapchain, then
it is replaced. This occurs even if the new swapchain creation fails.
Signed-off-by: Chris Forbes <chrisforbes@google.com>
Tobin Ehlis [Wed, 14 Dec 2016 00:33:41 +0000 (17:33 -0700)]
tests:Update InvalidMemoryAliasing for warning
The aliasing check was moved from error to warning to updating the test
to match.
Mark Young [Wed, 14 Dec 2016 00:19:32 +0000 (17:19 -0700)]
loader: Removed some unnecessary code.
Now that all WSI paths need the ICD structs, I can get rid of
a code path no longer used.
Change-Id: Ib5073cd2074fcd66453dae5b6c89870c81f7f958
Piers Daniell [Tue, 13 Dec 2016 23:51:49 +0000 (16:51 -0700)]
Allocate for real ICD surfaces for the VK_KHR_display extension
This was done for all the other WSI extensions, just not VK_KHR_display
Tobin Ehlis [Tue, 13 Dec 2016 19:39:44 +0000 (12:39 -0700)]
layers:Fix uninitialized variable
Zero-init the map_range variable before checking for aliasing of a
mapped memory region.
Tobin Ehlis [Tue, 13 Dec 2016 19:26:44 +0000 (12:26 -0700)]
layers:Fix typo
aliase->aliased
Tobin Ehlis [Tue, 13 Dec 2016 19:16:58 +0000 (12:16 -0700)]
layers:Warn on buffer/image aliasing
The Buffer-Image Granularity section of the spec details what must be
done to avoid having a linear buffer alias with a tiled image, but it
does not state that such aliasing is a definite error.
Demoting this check to a warning.
Tony Barbour [Tue, 13 Dec 2016 21:36:23 +0000 (14:36 -0700)]
tests: Remove second destroy of the same buffer
Change-Id: I21a4ee1406cb1f8ede669488df776cee5ea3addc
Mike Weiblen [Tue, 6 Dec 2016 17:28:00 +0000 (10:28 -0700)]
layers: Update Valid Usage enums in log_msg
Update Valid Usage enums in core_validation and update
their status in the VU database.
This completes Jira task VL-65.
Change-Id: I51ed327ad65f3a5d1f64bba01ad576c6656f88df