[Mesa-dev] [PATCH] r600g: Avoid setting one gpu register multiple times in a r600_pipe_state
Mathias Fröhlich
Mathias.Froehlich at gmx.net
Sun Mar 13 08:24:13 PDT 2011
Hi Henri,
On Saturday, March 12, 2011 15:38:48 Henri Verbeet wrote:
> 2011/3/12 Mathias Fröhlich <Mathias.Froehlich at gmx.net>:
> > Attached is a patch to the r600g driver that avoids setting one specific
> > gpu register multiple times within a r600_pipe_state struct.
>
> Is this supposed to fix anything in particular? The patch makes sense
> to me as an optimization, but if it changes behaviour that would be a
> bug somewhere else.
It does not fix anything. This change is supposed to produce the same command
stream than before.
I discovered that r600_context_pipe_state_set is one of the userspace
functions that are high in profiles for my use cases, I was looking for
duplicate registers within a single pipe_state_set in all r600_pipe_state
structs around.
This was the only place where I found duplicate registers.
The effect of the patch is not measurable in performance, but I think that this
duplication can be easily avoided.
Mathias
More information about the mesa-dev
mailing list