blorp: Add a binding_table_offset_to_pointer helper

On Gen11+, we have a feature that requires us to shift binding table
offsets by 3.  This adds a helper which gives the driver a hook to do
this if it so chooses.

Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14507>
This commit is contained in:
Jason Ekstrand
2020-05-11 13:49:55 -05:00
committed by Marge Bot
parent 3c3a8f853d
commit a83c91a261
4 changed files with 31 additions and 3 deletions

View File

@@ -177,6 +177,13 @@ blorp_alloc_binding_table(struct blorp_batch *blorp_batch,
batch->screen->vtbl.update_surface_base_address(batch, binder);
}
static uint32_t
blorp_binding_table_offset_to_pointer(struct blorp_batch *batch,
uint32_t offset)
{
return offset;
}
static void *
blorp_alloc_vertex_buffer(struct blorp_batch *blorp_batch,
uint32_t size,