[Mesa-dev] [PATCH 04/23] i965: Move up duplicated fields from stage-specific prog_data to brw_stage_prog_data.

Paul Berry stereotype441 at gmail.com
Tue Dec 17 14:11:21 PST 2013


On 2 December 2013 11:31, Francisco Jerez <currojerez at riseup.net> wrote:

> diff --git a/src/mesa/drivers/dri/i965/brw_program.c
> b/src/mesa/drivers/dri/i965/brw_program.c
> index 9a517be..a494bc2 100644
> --- a/src/mesa/drivers/dri/i965/brw_program.c
> +++ b/src/mesa/drivers/dri/i965/brw_program.c
> @@ -525,3 +525,31 @@ brw_destroy_shader_time(struct brw_context *brw)
>     drm_intel_bo_unreference(brw->shader_time.bo);
>     brw->shader_time.bo = NULL;
>  }
> +
> +bool
> +brw_stage_prog_data_compare(const void *in_a, const void *in_b)
> +{
> +   const struct brw_stage_prog_data *a = in_a;
> +   const struct brw_stage_prog_data *b = in_b;
>

Since this function is only called from the derived class compare funcs, it
doesn't have to match the signature of cache_aux_compare_func.  I'd prefer
if we made the parameters const brw_stage_prog_data *'s and got a little
extra type safety.

But I won't be a stickler about it.  With or without the change, this patch
is:

Reviewed-by: Paul Berry <stereotype441 at gmail.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/mesa-dev/attachments/20131217/03669e6a/attachment.html>


More information about the mesa-dev mailing list