| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
| |
When emitting the binding table for the fragment shader stage, we no
longer "walk all of the attachments, [inserting only] the color
attachments into the binding table". Instead, we iterate only over the
subpass's color attachments, which is the minimal possible iteration.
While killing the comment, also rename the variable 'attachments' to
'color_count', as it's no longer a count of all framebuffer attachments
but only the subpass's color attachment count.
|
|
|
|
|
|
|
|
|
|
|
|
| |
Prefix all anv_cmd_state dirty bit tokens with ANV_CMD_DIRTY. For
example:
old -> new
ANV_DYNAMIC_VIEWPORT_DIRTY -> ANV_CMD_DIRTY_DYNAMIC_VIEWPORT
ANV_CMD_BUFFER_PIPELINE_DIRTY -> ANV_CMD_DIRTY_PIPELINE
Change type of anv_cmd_state::dirty and ::compute_dirty from uint32_t to
the self-documenting type anv_cmd_dirty_mask_t.
|
| |
|
| |
|
| |
|
|
|
|
| |
We no longer need it as we have a better way to deal with dynamic offsets.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch reworks a bunch of stuff in the way we do descriptor set
layouts. Our previous approach had a couple of problems. First, it was
based on a misunderstanding of arrays in descriptor sets. Second, it
didn't properly handle descriptor sets where some bindings were missing
stages. The new apporach should be correct and also makes some operations,
particularly those on the hot-path, a bit easier.
We use the descriptor set layout for four things:
1) To determine the map from bindings to the actual flattened descriptor
set in vkUpdateDescriptorSets().
2) To determine the descriptor <-> binding table entry mapping to use in
anv_cmd_buffer_flush_descriptor_sets().
3) To determine the mappings of dynamic indices.
4) To determine the (set, binding, array index) -> binding table entry
mapping inside of shaders.
The new approach is directly taylored towards these operations.
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This prepares for merging VkAttachmentView into VkImageView. The two
surface states are:
anv_image_view::color_rt_surface_state:
RENDER_SURFACE_STATE when using image as a color render target.
anv_image_view::nonrt_surface_state;
RENDER_SURFACE_STATE when using image as a non render target.
No Crucible regressions.
|
|
|
|
| |
This prepares for merging VkAttachmentView into VkImageView.
|
| |
|
| |
|
|
|
|
|
|
| |
Remove anv_color_attachment_view and anv_depth_stencil_view, merging
them into anv_attachment_view. This prepares for merging
VkAttachmentView into VkImageView.
|
|
|
|
|
|
|
|
|
|
|
| |
Push the members of struct anv_surface_view into anv_image_view and
anv_buffer_view, then remove struct anv_surface_view. Observe that
anv_surface_view::range is not needed for anv_image_view, and so was
dropped there.
This prepares for the merge of VkAttachmentView into VkImageView. Remove
the common parent of anv_buffer_view and anv_image_view (that is,
anv_surface_view) will make the merge easier.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Rename all anv_*_view variables to follow this convention:
- sview -> anv_surface_view
- bview -> anv_buffer_view
- iview -> anv_image_view
- aview -> anv_attachment_view
- cview -> anv_color_attachment_view
- ds_view -> anv_depth_stencil_attachment_view
This clarifies existing code. And it will reduce noise in the upcoming
commits that merge VkAttachmentView into VkImageView.
|
|
|
|
|
|
|
| |
For a given struct anv_descriptor, all members are NULL (in which case
the descriptor is empty) or exactly one member is non-NULL.
To make struct anv_descriptor better reflect its set of valid states,
convert the struct into a tagged union.
|
|
|
|
| |
In most places, the variable type was the uninformative uint32_t.
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
| |
This makes more sense to me and it's more consistent with
anv_descriptor_set_layout.
|
|
|
|
|
|
| |
Previously, we simply had a big blob of stuff for "driver constants". Now,
we have a very specific data structure that contains the driver constants
that we care about.
|
|
|
|
|
| |
This function removes some duplicated code from
genN_cmd_buffer_emit_depth_stencil().
|
| |
|
|
|
|
|
| |
This doesn't add support for actually uploading them, it just ensures that
we have and update the shadow copy.
|
|
|
|
|
|
|
| |
With all the previous commits in place, we can now drop in support for
multiple platforms. First up is gen7 (Ivybridge).
Signed-off-by: Kristian Høgsberg Kristensen <[email protected]>
|
|
|
|
| |
Signed-off-by: Kristian Høgsberg Kristensen <[email protected]>
|
|
|
|
|
|
|
| |
We need this for generating surface state on the fly for dynamic buffer
views.
Signed-off-by: Kristian Høgsberg Kristensen <[email protected]>
|
|
|
|
|
|
|
| |
We're going to have to do this differently for earlier gens, so lets do
it in place only.
Signed-off-by: Kristian Høgsberg Kristensen <[email protected]>
|
|
|
|
| |
Signed-off-by: Kristian Høgsberg Kristensen <[email protected]>
|
|
|
|
| |
Signed-off-by: Kristian Høgsberg Kristensen <[email protected]>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
We'll organize gen specific code in three files per gen: pipeline,
cmd_buffer and state, eg:
gen8_cmd_buffer.c
gen8_pipeline.c
gen8_state.c
where gen8_cmd_buffer.c holds all vkCmd* entry points, gne8_pipeline.c
all gen specific code related to pipeline building and remaining state
code (sampler, surface state, dynamic state) in gen8_state.c.
Signed-off-by: Kristian Høgsberg Kristensen <[email protected]>
|
|
|
|
| |
Signed-off-by: Kristian Høgsberg Kristensen <[email protected]>
|
|
|
|
| |
Signed-off-by: Kristian Høgsberg Kristensen <[email protected]>
|
|
|
|
| |
Signed-off-by: Kristian Høgsberg Kristensen <[email protected]>
|
|
|
|
|
|
| |
Change type of anv_surface_view::format from VkFormat to const struct
anv_format*. This reduces the number of lookups in the VkFormat ->
anv_format table.
|
|
|
|
|
|
|
| |
This moves the translation of VkFormat to anv_format from
anv_fill_buffer_surface_state() to its caller.
A prep commit to reduce more VkFormat -> anv_format translations.
|
| |
|
| |
|
|
|
|
|
|
|
|
| |
Previously, the command buffer implementation was split between
anv_cmd_buffer.c and anv_cmd_emit.c. However, this naming convention was
confusing because none of the Vulkan entrypoints for anv_cmd_buffer were
actually in anv_cmd_buffer.c. This changes it so that anv_cmd_buffer.c is
what you think it is and the internals are in anv_batch_chain.c.
|
| |
|
| |
|
| |
|
|
|
|
| |
We'll need this to implement secondary command buffers.
|
| |
|
| |
|
|
|
|
|
|
| |
This is more generic and doesn't imply that it emits MI_BATCH_BUFFER_END.
While we're at it, we'll move NOOP adding from bo_finish to
end_batch_buffer.
|