layers:Rename cmd buffer flags for clarity
Fixes #870
CBSTATUS_ALL was not clear so changed to more descriptive
CBSTATUS_ALL_STATE_SET. This mask is used to flag all of the pipeline
state for a cmd buffer as "set." The setting can then be adjusted based
on which state was flagged as dynamic in the pipeline state object.
diff --git a/layers/core_validation.cpp b/layers/core_validation.cpp
index 0390dc3..e07929d 100644
--- a/layers/core_validation.cpp
+++ b/layers/core_validation.cpp
@@ -4205,12 +4205,12 @@
// Account for any dynamic state not set via this PSO
if (!pPipe->graphicsPipelineCI.pDynamicState ||
!pPipe->graphicsPipelineCI.pDynamicState->dynamicStateCount) { // All state is static
- pCB->status |= CBSTATUS_ALL;
+ pCB->status |= CBSTATUS_ALL_STATE_SET;
} else {
// First consider all state on
// Then unset any state that's noted as dynamic in PSO
// Finally OR that into CB statemask
- CBStatusFlags psoDynStateMask = CBSTATUS_ALL;
+ CBStatusFlags psoDynStateMask = CBSTATUS_ALL_STATE_SET;
for (uint32_t i = 0; i < pPipe->graphicsPipelineCI.pDynamicState->dynamicStateCount; i++) {
switch (pPipe->graphicsPipelineCI.pDynamicState->pDynamicStates[i]) {
case VK_DYNAMIC_STATE_LINE_WIDTH:
diff --git a/layers/core_validation_types.h b/layers/core_validation_types.h
index 6539d83..592d491 100644
--- a/layers/core_validation_types.h
+++ b/layers/core_validation_types.h
@@ -399,7 +399,7 @@
CBSTATUS_STENCIL_WRITE_MASK_SET = 0x00000020, // Stencil write mask has been set
CBSTATUS_STENCIL_REFERENCE_SET = 0x00000040, // Stencil reference has been set
CBSTATUS_INDEX_BUFFER_BOUND = 0x00000080, // Index buffer has been set
- CBSTATUS_ALL = 0x0000007F, // All dynamic state set (intentionally exclude index buffer)
+ CBSTATUS_ALL_STATE_SET = 0x0000007F, // All state set (intentionally exclude index buffer)
// clang-format on
};