mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-03 05:00:09 +01:00
dzn: Always align cached pipeline header size to input element align
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20617>
This commit is contained in:
parent
4565490b71
commit
25d460a818
1 changed files with 1 additions and 2 deletions
|
|
@ -562,12 +562,11 @@ dzn_pipeline_cache_lookup_gfx_pipeline(struct dzn_graphics_pipeline *pipeline,
|
|||
|
||||
const struct dzn_cached_gfx_pipeline_header *info =
|
||||
(const struct dzn_cached_gfx_pipeline_header *)(cached_blob->data);
|
||||
size_t offset = sizeof(*info);
|
||||
size_t offset = ALIGN_POT(sizeof(*info), alignof(D3D12_INPUT_ELEMENT_DESC));
|
||||
|
||||
assert(cached_blob->size >= sizeof(*info));
|
||||
|
||||
if (info->input_count > 0) {
|
||||
offset = ALIGN_POT(offset, alignof(D3D12_INPUT_LAYOUT_DESC));
|
||||
const D3D12_INPUT_ELEMENT_DESC *inputs =
|
||||
(const D3D12_INPUT_ELEMENT_DESC *)((uint8_t *)cached_blob->data + offset);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue