summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorDave Airlie <[email protected]>2017-04-18 13:22:32 +1000
committerDave Airlie <[email protected]>2017-04-19 09:00:43 +1000
commitfd420a7417c30e17b55c24d74b0fb399bfe3a2d4 (patch)
tree2f7044ccf411dfe3d2292d4c7009e8a6dd981e17 /src
parent25a5ee391d786b6d0b48b2b9aa0553e6972d97a0 (diff)
radv: add support for 32 descriptor sets.
This bumps the limit to the number of sets to 32, now that we have proper support for it. It also uses 1u in a few places to make things a bit safer. Reviewed-by: Bas Nieuwenhuizen <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
Diffstat (limited to 'src')
-rw-r--r--src/amd/vulkan/radv_cmd_buffer.c12
-rw-r--r--src/amd/vulkan/radv_descriptor_set.h2
2 files changed, 7 insertions, 7 deletions
diff --git a/src/amd/vulkan/radv_cmd_buffer.c b/src/amd/vulkan/radv_cmd_buffer.c
index d95daff2c79..8877f20b9ea 100644
--- a/src/amd/vulkan/radv_cmd_buffer.c
+++ b/src/amd/vulkan/radv_cmd_buffer.c
@@ -1381,7 +1381,7 @@ radv_flush_descriptors(struct radv_cmd_buffer *cmd_buffer,
}
for (i = 0; i < MAX_SETS; i++) {
- if (!(cmd_buffer->state.descriptors_dirty & (1 << i)))
+ if (!(cmd_buffer->state.descriptors_dirty & (1u << i)))
continue;
struct radv_descriptor_set *set = cmd_buffer->state.descriptors[i];
if (!set)
@@ -1957,7 +1957,7 @@ void radv_bind_descriptor_set(struct radv_cmd_buffer *cmd_buffer,
struct radeon_winsys *ws = cmd_buffer->device->ws;
cmd_buffer->state.descriptors[idx] = set;
- cmd_buffer->state.descriptors_dirty |= (1 << idx);
+ cmd_buffer->state.descriptors_dirty |= (1u << idx);
if (!set)
return;
@@ -2067,7 +2067,7 @@ void radv_meta_push_descriptor_set(
descriptorWriteCount, pDescriptorWrites, 0, NULL);
cmd_buffer->state.descriptors[set] = push_set;
- cmd_buffer->state.descriptors_dirty |= (1 << set);
+ cmd_buffer->state.descriptors_dirty |= (1u << set);
}
void radv_CmdPushDescriptorSetKHR(
@@ -2092,7 +2092,7 @@ void radv_CmdPushDescriptorSetKHR(
descriptorWriteCount, pDescriptorWrites, 0, NULL);
cmd_buffer->state.descriptors[set] = push_set;
- cmd_buffer->state.descriptors_dirty |= (1 << set);
+ cmd_buffer->state.descriptors_dirty |= (1u << set);
cmd_buffer->state.push_descriptors_dirty = true;
}
@@ -2116,7 +2116,7 @@ void radv_CmdPushDescriptorSetWithTemplateKHR(
descriptorUpdateTemplate, pData);
cmd_buffer->state.descriptors[set] = push_set;
- cmd_buffer->state.descriptors_dirty |= (1 << set);
+ cmd_buffer->state.descriptors_dirty |= (1u << set);
cmd_buffer->state.push_descriptors_dirty = true;
}
@@ -2207,7 +2207,7 @@ void radv_CmdBindPipeline(
for (unsigned i = 0; i < MAX_SETS; i++) {
if (cmd_buffer->state.descriptors[i])
- cmd_buffer->state.descriptors_dirty |= (1 << i);
+ cmd_buffer->state.descriptors_dirty |= (1u << i);
}
switch (pipelineBindPoint) {
diff --git a/src/amd/vulkan/radv_descriptor_set.h b/src/amd/vulkan/radv_descriptor_set.h
index a9f4bc6497e..a90eb5c3076 100644
--- a/src/amd/vulkan/radv_descriptor_set.h
+++ b/src/amd/vulkan/radv_descriptor_set.h
@@ -26,7 +26,7 @@
#include <vulkan/vulkan.h>
-#define MAX_SETS 8
+#define MAX_SETS 32
struct radv_descriptor_set_binding_layout {
VkDescriptorType type;