<div dir="ltr">On 20 August 2013 11:30, Paul Berry <span dir="ltr"><<a href="mailto:stereotype441@gmail.com" target="_blank">stereotype441@gmail.com</a>></span> wrote:<br><div class="gmail_extra"><div class="gmail_quote">
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">---<br>
src/mesa/drivers/dri/i965/brw_context.h | 11 +++++++++++<br>
1 file changed, 11 insertions(+)<br>
<br>
diff --git a/src/mesa/drivers/dri/i965/brw_context.h b/src/mesa/drivers/dri/i965/brw_context.h<br>
index 55d1174..4f6c767 100644<br>
--- a/src/mesa/drivers/dri/i965/brw_context.h<br>
+++ b/src/mesa/drivers/dri/i965/brw_context.h<br>
@@ -1162,7 +1162,18 @@ struct brw_context<br>
} vs;<br>
<br>
struct {<br>
+ struct brw_vec4_gs_prog_data *prog_data;<br>
+<br>
+ drm_intel_bo *scratch_bo;<br>
+ /** Offset in the program cache to the GS program */<br>
+ uint32_t prog_offset;<br>
+<br>
+ uint32_t bind_bo_offset;<br>
+ } vec4_gs;<br>
+<br>
+ struct {<br>
struct brw_gs_prog_data *prog_data;<br>
+ drm_intel_bo *const_bo;<br></blockquote><div><br>From our in-person code review yesterday:<br><br></div><div>1. There are several fields in vs that are present in brw->vs but missing from brw->vec4_gs (state_offset, surf_offset, sampler_offset, sdc_offset, regs, classes, ra_reg_to_grf). Probably some of these need to be added to brw->vec4_gs, and others need to be moved into a more global spot (perhaps a new brw->vec4 substructure). We may want to consider making a C-style base class that brw->vs and brw->vec4_gs can use to share common elements.<br>
<br></div><div>2. It looks like const_bo got added to the wrong place.<br><br></div><div>3. It's confusing that fixed functionality geometry shaders use brw->gs but user-defined geometry shaders use brw->vec4_gs. We agreed that it would be better to rename brw->gs to brw->ff_gs and brw->vec4_gs to brw->gs. Note that there are similar names in other patches that should also be changed, e.g. CACHE_NEW_VEC4_GS_PROG and BRW_VEC4_GS_PROG.<br>
</div><div> <br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<br>
bool prog_active;<br>
/** Offset in the program cache to the CLIP program pre-gen6 */<br>
<span class=""><font color="#888888">--<br>
1.8.3.4<br>
<br>
</font></span></blockquote></div><br></div></div>