mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-08 04:48:08 +02:00
i965/gen4: Expose the guts of URB recalculation as a helper
Reviewed-by: Topi Pohjolainen <topi.pohjolainen@intel.com>
This commit is contained in:
parent
0ed6f196fc
commit
79b486f736
2 changed files with 12 additions and 5 deletions
|
|
@ -1361,6 +1361,8 @@ void brw_destroy_shader_time(struct brw_context *brw);
|
||||||
|
|
||||||
/* brw_urb.c
|
/* brw_urb.c
|
||||||
*/
|
*/
|
||||||
|
void brw_calculate_urb_fence(struct brw_context *brw, unsigned csize,
|
||||||
|
unsigned vsize, unsigned sfsize);
|
||||||
void brw_upload_urb_fence(struct brw_context *brw);
|
void brw_upload_urb_fence(struct brw_context *brw);
|
||||||
|
|
||||||
/* brw_curbe.c
|
/* brw_curbe.c
|
||||||
|
|
|
||||||
|
|
@ -112,12 +112,10 @@ static bool check_urb_layout(struct brw_context *brw)
|
||||||
/* Most minimal update, forces re-emit of URB fence packet after GS
|
/* Most minimal update, forces re-emit of URB fence packet after GS
|
||||||
* unit turned on/off.
|
* unit turned on/off.
|
||||||
*/
|
*/
|
||||||
static void recalculate_urb_fence( struct brw_context *brw )
|
void
|
||||||
|
brw_calculate_urb_fence(struct brw_context *brw, unsigned csize,
|
||||||
|
unsigned vsize, unsigned sfsize)
|
||||||
{
|
{
|
||||||
GLuint csize = brw->curbe.total_size;
|
|
||||||
GLuint vsize = brw_vue_prog_data(brw->vs.base.prog_data)->urb_entry_size;
|
|
||||||
GLuint sfsize = brw->sf.prog_data->urb_entry_size;
|
|
||||||
|
|
||||||
if (csize < limits[CS].min_entry_size)
|
if (csize < limits[CS].min_entry_size)
|
||||||
csize = limits[CS].min_entry_size;
|
csize = limits[CS].min_entry_size;
|
||||||
|
|
||||||
|
|
@ -208,6 +206,13 @@ done:
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static void recalculate_urb_fence( struct brw_context *brw )
|
||||||
|
{
|
||||||
|
brw_calculate_urb_fence(brw, brw->curbe.total_size,
|
||||||
|
brw_vue_prog_data(brw->vs.base.prog_data)->urb_entry_size,
|
||||||
|
brw->sf.prog_data->urb_entry_size);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
const struct brw_tracked_state brw_recalculate_urb_fence = {
|
const struct brw_tracked_state brw_recalculate_urb_fence = {
|
||||||
.dirty = {
|
.dirty = {
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue