*
* The workaround below necessitates this workaround.
*/
- gen6_PIPE_CONTROL(&p->cp->builder,
+ gen6_PIPE_CONTROL(p->builder,
GEN6_PIPE_CONTROL_CS_STALL |
GEN6_PIPE_CONTROL_PIXEL_SCOREBOARD_STALL,
NULL, 0, false);
* "Before a PIPE_CONTROL with Write Cache Flush Enable =1, a
* PIPE_CONTROL with any non-zero post-sync-op is required."
*/
- gen6_PIPE_CONTROL(&p->cp->builder,
+ gen6_PIPE_CONTROL(p->builder,
GEN6_PIPE_CONTROL_WRITE_IMM,
p->workaround_bo, 0, false);
}
* requires driver to send a PIPE_CONTROL with a CS stall along with a
* Depth Flush prior to this command."
*/
- gen6_PIPE_CONTROL(&p->cp->builder,
+ gen6_PIPE_CONTROL(p->builder,
GEN6_PIPE_CONTROL_DEPTH_CACHE_FLUSH |
GEN6_PIPE_CONTROL_CS_STALL,
0, 0, false);
* to emit a sequence of PIPE_CONTROLs prior to emitting depth related
* commands.
*/
- gen6_PIPE_CONTROL(&p->cp->builder,
+ gen6_PIPE_CONTROL(p->builder,
GEN6_PIPE_CONTROL_DEPTH_STALL,
NULL, 0, false);
- gen6_PIPE_CONTROL(&p->cp->builder,
+ gen6_PIPE_CONTROL(p->builder,
GEN6_PIPE_CONTROL_DEPTH_CACHE_FLUSH,
NULL, 0, false);
- gen6_PIPE_CONTROL(&p->cp->builder,
+ gen6_PIPE_CONTROL(p->builder,
GEN6_PIPE_CONTROL_DEPTH_STALL,
NULL, 0, false);
}
* field set (DW1 Bit 1), must be issued prior to any change to the
* value in this field (Maximum Number of Threads in 3DSTATE_WM)"
*/
- gen6_PIPE_CONTROL(&p->cp->builder,
+ gen6_PIPE_CONTROL(p->builder,
GEN6_PIPE_CONTROL_PIXEL_SCOREBOARD_STALL,
NULL, 0, false);
* PIPE_CONTROL after 3DSTATE_CONSTANT_VS so that the command is kept being
* buffered by VS FF, to the point that the FF dies.
*/
- gen6_PIPE_CONTROL(&p->cp->builder,
+ gen6_PIPE_CONTROL(p->builder,
GEN6_PIPE_CONTROL_DEPTH_STALL |
GEN6_PIPE_CONTROL_INSTRUCTION_CACHE_INVALIDATE |
GEN6_PIPE_CONTROL_STATE_CACHE_INVALIDATE,
if (ilo_dev_gen(p->dev) == ILO_GEN(6))
gen6_wa_pipe_control_post_sync(p, false);
- gen6_PIPELINE_SELECT(&p->cp->builder, 0x0);
+ gen6_PIPELINE_SELECT(p->builder, 0x0);
}
}
if (ilo_dev_gen(p->dev) == ILO_GEN(6))
gen6_wa_pipe_control_post_sync(p, false);
- gen6_STATE_SIP(&p->cp->builder, 0);
+ gen6_STATE_SIP(p->builder, 0);
}
}
if (ilo_dev_gen(p->dev) == ILO_GEN(6))
gen6_wa_pipe_control_post_sync(p, false);
- gen6_state_base_address(&p->cp->builder, session->hw_ctx_changed);
+ gen6_state_base_address(p->builder, session->hw_ctx_changed);
/*
* From the Sandy Bridge PRM, volume 1 part 1, page 28:
gs_total_size = 0;
}
- gen6_3DSTATE_URB(&p->cp->builder, vs_total_size, gs_total_size,
+ gen6_3DSTATE_URB(p->builder, vs_total_size, gs_total_size,
vs_entry_size, gs_entry_size);
/*
{
/* 3DSTATE_VIEWPORT_STATE_POINTERS */
if (session->viewport_state_changed) {
- gen6_3DSTATE_VIEWPORT_STATE_POINTERS(&p->cp->builder,
+ gen6_3DSTATE_VIEWPORT_STATE_POINTERS(p->builder,
p->state.CLIP_VIEWPORT,
p->state.SF_VIEWPORT,
p->state.CC_VIEWPORT);
if (session->cc_state_blend_changed ||
session->cc_state_dsa_changed ||
session->cc_state_cc_changed) {
- gen6_3DSTATE_CC_STATE_POINTERS(&p->cp->builder,
+ gen6_3DSTATE_CC_STATE_POINTERS(p->builder,
p->state.BLEND_STATE,
p->state.DEPTH_STENCIL_STATE,
p->state.COLOR_CALC_STATE);
if (session->sampler_state_vs_changed ||
session->sampler_state_gs_changed ||
session->sampler_state_fs_changed) {
- gen6_3DSTATE_SAMPLER_STATE_POINTERS(&p->cp->builder,
+ gen6_3DSTATE_SAMPLER_STATE_POINTERS(p->builder,
p->state.vs.SAMPLER_STATE,
0,
p->state.wm.SAMPLER_STATE);
{
/* 3DSTATE_SCISSOR_STATE_POINTERS */
if (session->scissor_state_changed) {
- gen6_3DSTATE_SCISSOR_STATE_POINTERS(&p->cp->builder,
+ gen6_3DSTATE_SCISSOR_STATE_POINTERS(p->builder,
p->state.SCISSOR_RECT);
}
if (session->binding_table_vs_changed ||
session->binding_table_gs_changed ||
session->binding_table_fs_changed) {
- gen6_3DSTATE_BINDING_TABLE_POINTERS(&p->cp->builder,
+ gen6_3DSTATE_BINDING_TABLE_POINTERS(p->builder,
p->state.vs.BINDING_TABLE_STATE,
p->state.gs.BINDING_TABLE_STATE,
p->state.wm.BINDING_TABLE_STATE);
if (ilo_dev_gen(p->dev) >= ILO_GEN(7.5)) {
/* 3DSTATE_INDEX_BUFFER */
if (DIRTY(IB) || session->batch_bo_changed) {
- gen6_3DSTATE_INDEX_BUFFER(&p->cp->builder,
+ gen6_3DSTATE_INDEX_BUFFER(p->builder,
&vec->ib, false);
}
/* 3DSTATE_VF */
if (session->primitive_restart_changed) {
- gen7_3DSTATE_VF(&p->cp->builder, vec->draw->primitive_restart,
+ gen7_3DSTATE_VF(p->builder, vec->draw->primitive_restart,
vec->draw->restart_index);
}
}
/* 3DSTATE_INDEX_BUFFER */
if (DIRTY(IB) || session->primitive_restart_changed ||
session->batch_bo_changed) {
- gen6_3DSTATE_INDEX_BUFFER(&p->cp->builder,
+ gen6_3DSTATE_INDEX_BUFFER(p->builder,
&vec->ib, vec->draw->primitive_restart);
}
}
/* 3DSTATE_VERTEX_BUFFERS */
if (DIRTY(VB) || DIRTY(VE) || session->batch_bo_changed)
- gen6_3DSTATE_VERTEX_BUFFERS(&p->cp->builder, vec->ve, &vec->vb);
+ gen6_3DSTATE_VERTEX_BUFFERS(p->builder, vec->ve, &vec->vb);
/* 3DSTATE_VERTEX_ELEMENTS */
if (DIRTY(VE) || DIRTY(VS)) {
prepend_generate_ids = true;
}
- gen6_3DSTATE_VERTEX_ELEMENTS(&p->cp->builder, ve,
+ gen6_3DSTATE_VERTEX_ELEMENTS(p->builder, ve,
last_velement_edgeflag, prepend_generate_ids);
}
}
{
/* 3DSTATE_VF_STATISTICS */
if (session->hw_ctx_changed)
- gen6_3DSTATE_VF_STATISTICS(&p->cp->builder, false);
+ gen6_3DSTATE_VF_STATISTICS(p->builder, false);
}
static void
struct gen6_pipeline_session *session)
{
/* 3DPRIMITIVE */
- gen6_3DPRIMITIVE(&p->cp->builder, vec->draw, &vec->ib);
+ gen6_3DPRIMITIVE(p->builder, vec->draw, &vec->ib);
p->state.has_gen6_wa_pipe_control = false;
}
/* 3DSTATE_CONSTANT_VS */
if (emit_3dstate_constant_vs) {
- gen6_3DSTATE_CONSTANT_VS(&p->cp->builder,
+ gen6_3DSTATE_CONSTANT_VS(p->builder,
&p->state.vs.PUSH_CONSTANT_BUFFER,
&p->state.vs.PUSH_CONSTANT_BUFFER_size,
1);
if (emit_3dstate_vs) {
const int num_samplers = vec->sampler[PIPE_SHADER_VERTEX].count;
- gen6_3DSTATE_VS(&p->cp->builder, vec->vs, num_samplers);
+ gen6_3DSTATE_VS(p->builder, vec->vs, num_samplers);
}
if (emit_3dstate_constant_vs && ilo_dev_gen(p->dev) == ILO_GEN(6))
{
/* 3DSTATE_CONSTANT_GS */
if (session->pcb_state_gs_changed)
- gen6_3DSTATE_CONSTANT_GS(&p->cp->builder, NULL, NULL, 0);
+ gen6_3DSTATE_CONSTANT_GS(p->builder, NULL, NULL, 0);
/* 3DSTATE_GS */
if (DIRTY(GS) || DIRTY(VS) ||
session->prim_changed || session->kernel_bo_changed) {
const int verts_per_prim = u_vertices_per_prim(session->reduced_prim);
- gen6_3DSTATE_GS(&p->cp->builder, vec->gs, vec->vs, verts_per_prim);
+ gen6_3DSTATE_GS(p->builder, vec->gs, vec->vs, verts_per_prim);
}
}
if (ilo_dev_gen(p->dev) == ILO_GEN(6))
gen6_wa_pipe_control_post_sync(p, false);
- gen6_3DSTATE_GS_SVB_INDEX(&p->cp->builder,
+ gen6_3DSTATE_GS_SVB_INDEX(p->builder,
0, p->state.so_num_vertices, p->state.so_max_vertices,
false);
* 0xFFFFFFFF in order to not cause overflow in that SVBI."
*/
for (i = 1; i < 4; i++) {
- gen6_3DSTATE_GS_SVB_INDEX(&p->cp->builder,
+ gen6_3DSTATE_GS_SVB_INDEX(p->builder,
i, 0, 0xffffffff, false);
}
}
}
}
- gen6_3DSTATE_CLIP(&p->cp->builder, vec->rasterizer,
+ gen6_3DSTATE_CLIP(p->builder, vec->rasterizer,
vec->fs, enable_guardband, 1);
}
}
{
/* 3DSTATE_SF */
if (DIRTY(RASTERIZER) || DIRTY(FS))
- gen6_3DSTATE_SF(&p->cp->builder, vec->rasterizer, vec->fs);
+ gen6_3DSTATE_SF(p->builder, vec->rasterizer, vec->fs);
}
void
if (ilo_dev_gen(p->dev) == ILO_GEN(6))
gen6_wa_pipe_control_post_sync(p, false);
- gen6_3DSTATE_DRAWING_RECTANGLE(&p->cp->builder, 0, 0,
+ gen6_3DSTATE_DRAWING_RECTANGLE(p->builder, 0, 0,
vec->fb.state.width, vec->fb.state.height);
}
}
{
/* 3DSTATE_CONSTANT_PS */
if (session->pcb_state_fs_changed) {
- gen6_3DSTATE_CONSTANT_PS(&p->cp->builder,
+ gen6_3DSTATE_CONSTANT_PS(p->builder,
&p->state.wm.PUSH_CONSTANT_BUFFER,
&p->state.wm.PUSH_CONSTANT_BUFFER_size,
1);
if (ilo_dev_gen(p->dev) == ILO_GEN(6) && session->hw_ctx_changed)
gen6_wa_pipe_control_wm_max_threads_stall(p);
- gen6_3DSTATE_WM(&p->cp->builder, vec->fs, num_samplers,
+ gen6_3DSTATE_WM(p->builder, vec->fs, num_samplers,
vec->rasterizer, dual_blend, cc_may_kill, 0);
}
}
gen6_wa_pipe_control_wm_multisample_flush(p);
}
- gen6_3DSTATE_MULTISAMPLE(&p->cp->builder,
+ gen6_3DSTATE_MULTISAMPLE(p->builder,
vec->fb.num_samples, packed_sample_pos,
vec->rasterizer->state.half_pixel_center);
- gen6_3DSTATE_SAMPLE_MASK(&p->cp->builder,
+ gen6_3DSTATE_SAMPLE_MASK(p->builder,
(vec->fb.num_samples > 1) ? vec->sample_mask : 0x1);
}
}
gen6_wa_pipe_control_wm_depth_flush(p);
}
- gen6_3DSTATE_DEPTH_BUFFER(&p->cp->builder, zs);
- gen6_3DSTATE_HIER_DEPTH_BUFFER(&p->cp->builder, zs);
- gen6_3DSTATE_STENCIL_BUFFER(&p->cp->builder, zs);
- gen6_3DSTATE_CLEAR_PARAMS(&p->cp->builder, clear_params);
+ gen6_3DSTATE_DEPTH_BUFFER(p->builder, zs);
+ gen6_3DSTATE_HIER_DEPTH_BUFFER(p->builder, zs);
+ gen6_3DSTATE_STENCIL_BUFFER(p->builder, zs);
+ gen6_3DSTATE_CLEAR_PARAMS(p->builder, clear_params);
}
}
if (ilo_dev_gen(p->dev) == ILO_GEN(6))
gen6_wa_pipe_control_post_sync(p, false);
- gen6_3DSTATE_POLY_STIPPLE_PATTERN(&p->cp->builder,
+ gen6_3DSTATE_POLY_STIPPLE_PATTERN(p->builder,
&vec->poly_stipple);
- gen6_3DSTATE_POLY_STIPPLE_OFFSET(&p->cp->builder, 0, 0);
+ gen6_3DSTATE_POLY_STIPPLE_OFFSET(p->builder, 0, 0);
}
/* 3DSTATE_LINE_STIPPLE */
if (ilo_dev_gen(p->dev) == ILO_GEN(6))
gen6_wa_pipe_control_post_sync(p, false);
- gen6_3DSTATE_LINE_STIPPLE(&p->cp->builder,
+ gen6_3DSTATE_LINE_STIPPLE(p->builder,
vec->rasterizer->state.line_stipple_pattern,
vec->rasterizer->state.line_stipple_factor + 1);
}
if (ilo_dev_gen(p->dev) == ILO_GEN(6))
gen6_wa_pipe_control_post_sync(p, false);
- gen6_3DSTATE_AA_LINE_PARAMETERS(&p->cp->builder);
+ gen6_3DSTATE_AA_LINE_PARAMETERS(p->builder);
}
}
{
/* SF_CLIP_VIEWPORT and CC_VIEWPORT */
if (ilo_dev_gen(p->dev) >= ILO_GEN(7) && DIRTY(VIEWPORT)) {
- p->state.SF_CLIP_VIEWPORT = gen7_SF_CLIP_VIEWPORT(&p->cp->builder,
+ p->state.SF_CLIP_VIEWPORT = gen7_SF_CLIP_VIEWPORT(p->builder,
vec->viewport.cso, vec->viewport.count);
- p->state.CC_VIEWPORT = gen6_CC_VIEWPORT(&p->cp->builder,
+ p->state.CC_VIEWPORT = gen6_CC_VIEWPORT(p->builder,
vec->viewport.cso, vec->viewport.count);
session->viewport_state_changed = true;
}
/* SF_VIEWPORT, CLIP_VIEWPORT, and CC_VIEWPORT */
else if (DIRTY(VIEWPORT)) {
- p->state.CLIP_VIEWPORT = gen6_CLIP_VIEWPORT(&p->cp->builder,
+ p->state.CLIP_VIEWPORT = gen6_CLIP_VIEWPORT(p->builder,
vec->viewport.cso, vec->viewport.count);
- p->state.SF_VIEWPORT = gen6_SF_VIEWPORT(&p->cp->builder,
+ p->state.SF_VIEWPORT = gen6_SF_VIEWPORT(p->builder,
vec->viewport.cso, vec->viewport.count);
- p->state.CC_VIEWPORT = gen6_CC_VIEWPORT(&p->cp->builder,
+ p->state.CC_VIEWPORT = gen6_CC_VIEWPORT(p->builder,
vec->viewport.cso, vec->viewport.count);
session->viewport_state_changed = true;
{
/* BLEND_STATE */
if (DIRTY(BLEND) || DIRTY(FB) || DIRTY(DSA)) {
- p->state.BLEND_STATE = gen6_BLEND_STATE(&p->cp->builder,
+ p->state.BLEND_STATE = gen6_BLEND_STATE(p->builder,
vec->blend, &vec->fb, vec->dsa);
session->cc_state_blend_changed = true;
/* COLOR_CALC_STATE */
if (DIRTY(DSA) || DIRTY(STENCIL_REF) || DIRTY(BLEND_COLOR)) {
p->state.COLOR_CALC_STATE =
- gen6_COLOR_CALC_STATE(&p->cp->builder, &vec->stencil_ref,
+ gen6_COLOR_CALC_STATE(p->builder, &vec->stencil_ref,
vec->dsa->alpha_ref, &vec->blend_color);
session->cc_state_cc_changed = true;
/* DEPTH_STENCIL_STATE */
if (DIRTY(DSA)) {
p->state.DEPTH_STENCIL_STATE =
- gen6_DEPTH_STENCIL_STATE(&p->cp->builder, vec->dsa);
+ gen6_DEPTH_STENCIL_STATE(p->builder, vec->dsa);
session->cc_state_dsa_changed = true;
}
/* SCISSOR_RECT */
if (DIRTY(SCISSOR) || DIRTY(VIEWPORT)) {
/* there should be as many scissors as there are viewports */
- p->state.SCISSOR_RECT = gen6_SCISSOR_RECT(&p->cp->builder,
+ p->state.SCISSOR_RECT = gen6_SCISSOR_RECT(p->builder,
&vec->scissor, vec->viewport.count);
session->scissor_state_changed = true;
if (!surface) {
surface_state[i] =
- gen6_SURFACE_STATE(&p->cp->builder, &fb->null_rt, true);
+ gen6_SURFACE_STATE(p->builder, &fb->null_rt, true);
}
else {
assert(surface && surface->is_rt);
surface_state[i] =
- gen6_SURFACE_STATE(&p->cp->builder, &surface->u.rt, true);
+ gen6_SURFACE_STATE(p->builder, &surface->u.rt, true);
}
}
*/
if (i == 0) {
surface_state[i] =
- gen6_SURFACE_STATE(&p->cp->builder, &fb->null_rt, true);
+ gen6_SURFACE_STATE(p->builder, &fb->null_rt, true);
i++;
}
(target < so->count) ? so->states[target] : NULL;
if (so_target) {
- surface_state[i] = gen6_so_SURFACE_STATE(&p->cp->builder,
+ surface_state[i] = gen6_so_SURFACE_STATE(p->builder,
so_target, so_info, i);
}
else {
(const struct ilo_view_cso *) view->states[i];
surface_state[i] =
- gen6_SURFACE_STATE(&p->cp->builder, &cso->surface, false);
+ gen6_SURFACE_STATE(p->builder, &cso->surface, false);
}
else {
surface_state[i] = 0;
count = util_last_bit(cbuf->enabled_mask);
for (i = 0; i < count; i++) {
if (cbuf->cso[i].resource) {
- surface_state[i] = gen6_SURFACE_STATE(&p->cp->builder,
+ surface_state[i] = gen6_SURFACE_STATE(p->builder,
&cbuf->cso[i].surface, false);
}
else {
if (size < session->num_surfaces[shader_type])
size = session->num_surfaces[shader_type];
- *binding_table_state = gen6_BINDING_TABLE_STATE(&p->cp->builder,
+ *binding_table_state = gen6_BINDING_TABLE_STATE(p->builder,
surface_state, size);
*binding_table_state_size = size;
}
for (i = 0; i < num_samplers; i++) {
border_color_state[i] = (samplers[i]) ?
- gen6_SAMPLER_BORDER_COLOR_STATE(&p->cp->builder, samplers[i]) : 0;
+ gen6_SAMPLER_BORDER_COLOR_STATE(p->builder, samplers[i]) : 0;
}
}
/* should we take the minimum of num_samplers and num_views? */
- *sampler_state = gen6_SAMPLER_STATE(&p->cp->builder,
+ *sampler_state = gen6_SAMPLER_STATE(p->builder,
samplers, views,
border_color_state,
MIN2(num_samplers, num_views));
void *pcb;
p->state.vs.PUSH_CONSTANT_BUFFER =
- gen6_push_constant_buffer(&p->cp->builder, total_size, &pcb);
+ gen6_push_constant_buffer(p->builder, total_size, &pcb);
p->state.vs.PUSH_CONSTANT_BUFFER_size = total_size;
if (cbuf0_size) {
void *pcb;
p->state.wm.PUSH_CONSTANT_BUFFER =
- gen6_push_constant_buffer(&p->cp->builder, cbuf0_size, &pcb);
+ gen6_push_constant_buffer(p->builder, cbuf0_size, &pcb);
p->state.wm.PUSH_CONSTANT_BUFFER_size = cbuf0_size;
if (cbuf0_size <= cbuf->cso[0].user_buffer_size) {
if (ilo_dev_gen(p->dev) == ILO_GEN(6))
gen6_wa_pipe_control_post_sync(p, false);
- gen6_PIPE_CONTROL(&p->cp->builder,
+ gen6_PIPE_CONTROL(p->builder,
GEN6_PIPE_CONTROL_INSTRUCTION_CACHE_INVALIDATE |
GEN6_PIPE_CONTROL_RENDER_CACHE_FLUSH |
GEN6_PIPE_CONTROL_DEPTH_CACHE_FLUSH |
if (ilo_dev_gen(p->dev) == ILO_GEN(6))
gen6_wa_pipe_control_post_sync(p, true);
- gen6_PIPE_CONTROL(&p->cp->builder,
+ gen6_PIPE_CONTROL(p->builder,
GEN6_PIPE_CONTROL_WRITE_TIMESTAMP,
bo, index * sizeof(uint64_t),
true);
if (ilo_dev_gen(p->dev) == ILO_GEN(6))
gen6_wa_pipe_control_post_sync(p, false);
- gen6_PIPE_CONTROL(&p->cp->builder,
+ gen6_PIPE_CONTROL(p->builder,
GEN6_PIPE_CONTROL_DEPTH_STALL |
GEN6_PIPE_CONTROL_WRITE_PS_DEPTH_COUNT,
bo, index * sizeof(uint64_t),
if (regs[i]) {
/* store lower 32 bits */
- gen6_MI_STORE_REGISTER_MEM(&p->cp->builder,
+ gen6_MI_STORE_REGISTER_MEM(p->builder,
bo, bo_offset, regs[i]);
/* store higher 32 bits */
- gen6_MI_STORE_REGISTER_MEM(&p->cp->builder,
+ gen6_MI_STORE_REGISTER_MEM(p->builder,
bo, bo_offset + 4, regs[i] + 4);
}
else {
- gen6_MI_STORE_DATA_IMM(&p->cp->builder,
+ gen6_MI_STORE_DATA_IMM(p->builder,
bo, bo_offset, 0, true);
}
}
const struct ilo_blitter *blitter,
struct gen6_rectlist_session *session)
{
- gen6_3DSTATE_CONSTANT_VS(&p->cp->builder, NULL, NULL, 0);
- gen6_3DSTATE_VS(&p->cp->builder, NULL, 0);
+ gen6_3DSTATE_CONSTANT_VS(p->builder, NULL, NULL, 0);
+ gen6_3DSTATE_VS(p->builder, NULL, 0);
gen6_wa_pipe_control_vs_const_flush(p);
- gen6_3DSTATE_CONSTANT_GS(&p->cp->builder, NULL, NULL, 0);
- gen6_3DSTATE_GS(&p->cp->builder, NULL, NULL, 0);
+ gen6_3DSTATE_CONSTANT_GS(p->builder, NULL, NULL, 0);
+ gen6_3DSTATE_GS(p->builder, NULL, NULL, 0);
- gen6_3DSTATE_CLIP(&p->cp->builder, NULL, NULL, false, 0);
- gen6_3DSTATE_SF(&p->cp->builder, NULL, NULL);
+ gen6_3DSTATE_CLIP(p->builder, NULL, NULL, false, 0);
+ gen6_3DSTATE_SF(p->builder, NULL, NULL);
}
static void
break;
}
- gen6_3DSTATE_CONSTANT_PS(&p->cp->builder, NULL, NULL, 0);
+ gen6_3DSTATE_CONSTANT_PS(p->builder, NULL, NULL, 0);
gen6_wa_pipe_control_wm_max_threads_stall(p);
- gen6_3DSTATE_WM(&p->cp->builder, NULL, 0, NULL, false, false, hiz_op);
+ gen6_3DSTATE_WM(p->builder, NULL, 0, NULL, false, false, hiz_op);
}
static void
if (blitter->uses & (ILO_BLITTER_USE_FB_DEPTH |
ILO_BLITTER_USE_FB_STENCIL)) {
- gen6_3DSTATE_DEPTH_BUFFER(&p->cp->builder,
+ gen6_3DSTATE_DEPTH_BUFFER(p->builder,
&blitter->fb.dst.u.zs);
}
if (blitter->uses & ILO_BLITTER_USE_FB_DEPTH) {
- gen6_3DSTATE_HIER_DEPTH_BUFFER(&p->cp->builder,
+ gen6_3DSTATE_HIER_DEPTH_BUFFER(p->builder,
&blitter->fb.dst.u.zs);
}
if (blitter->uses & ILO_BLITTER_USE_FB_STENCIL) {
- gen6_3DSTATE_STENCIL_BUFFER(&p->cp->builder,
+ gen6_3DSTATE_STENCIL_BUFFER(p->builder,
&blitter->fb.dst.u.zs);
}
- gen6_3DSTATE_CLEAR_PARAMS(&p->cp->builder,
+ gen6_3DSTATE_CLEAR_PARAMS(p->builder,
blitter->depth_clear_value);
}
gen6_wa_pipe_control_wm_multisample_flush(p);
- gen6_3DSTATE_MULTISAMPLE(&p->cp->builder, blitter->fb.num_samples,
+ gen6_3DSTATE_MULTISAMPLE(p->builder, blitter->fb.num_samples,
packed_sample_pos, true);
- gen6_3DSTATE_SAMPLE_MASK(&p->cp->builder,
+ gen6_3DSTATE_SAMPLE_MASK(p->builder,
(1 << blitter->fb.num_samples) - 1);
}
gen6_rectlist_wm_multisample(p, blitter, session);
- gen6_state_base_address(&p->cp->builder, true);
+ gen6_state_base_address(p->builder, true);
- gen6_3DSTATE_VERTEX_BUFFERS(&p->cp->builder,
+ gen6_3DSTATE_VERTEX_BUFFERS(p->builder,
&blitter->ve, &blitter->vb);
- gen6_3DSTATE_VERTEX_ELEMENTS(&p->cp->builder,
+ gen6_3DSTATE_VERTEX_ELEMENTS(p->builder,
&blitter->ve, false, false);
- gen6_3DSTATE_URB(&p->cp->builder,
+ gen6_3DSTATE_URB(p->builder,
p->dev->urb_size, 0, blitter->ve.count * 4 * sizeof(float), 0);
/* 3DSTATE_URB workaround */
if (p->state.gs.active) {
if (blitter->uses &
(ILO_BLITTER_USE_DSA | ILO_BLITTER_USE_CC)) {
- gen6_3DSTATE_CC_STATE_POINTERS(&p->cp->builder, 0,
+ gen6_3DSTATE_CC_STATE_POINTERS(p->builder, 0,
session->DEPTH_STENCIL_STATE, session->COLOR_CALC_STATE);
}
gen6_rectlist_wm(p, blitter, session);
if (blitter->uses & ILO_BLITTER_USE_VIEWPORT) {
- gen6_3DSTATE_VIEWPORT_STATE_POINTERS(&p->cp->builder,
+ gen6_3DSTATE_VIEWPORT_STATE_POINTERS(p->builder,
0, 0, session->CC_VIEWPORT);
}
gen6_rectlist_wm_depth(p, blitter, session);
- gen6_3DSTATE_DRAWING_RECTANGLE(&p->cp->builder, 0, 0,
+ gen6_3DSTATE_DRAWING_RECTANGLE(p->builder, 0, 0,
blitter->fb.width, blitter->fb.height);
- gen6_3DPRIMITIVE(&p->cp->builder, &blitter->draw, NULL);
+ gen6_3DPRIMITIVE(p->builder, &blitter->draw, NULL);
}
static void
{
if (blitter->uses & ILO_BLITTER_USE_DSA) {
session->DEPTH_STENCIL_STATE =
- gen6_DEPTH_STENCIL_STATE(&p->cp->builder, &blitter->dsa);
+ gen6_DEPTH_STENCIL_STATE(p->builder, &blitter->dsa);
}
if (blitter->uses & ILO_BLITTER_USE_CC) {
session->COLOR_CALC_STATE =
- gen6_COLOR_CALC_STATE(&p->cp->builder, &blitter->cc.stencil_ref,
+ gen6_COLOR_CALC_STATE(p->builder, &blitter->cc.stencil_ref,
blitter->cc.alpha_ref, &blitter->cc.blend_color);
}
if (blitter->uses & ILO_BLITTER_USE_VIEWPORT) {
session->CC_VIEWPORT =
- gen6_CC_VIEWPORT(&p->cp->builder, &blitter->viewport, 1);
+ gen6_CC_VIEWPORT(p->builder, &blitter->viewport, 1);
}
}
bo = p->workaround_bo;
}
- gen6_PIPE_CONTROL(&p->cp->builder, dw1, bo, 0, false);
+ gen6_PIPE_CONTROL(p->builder, dw1, bo, 0, false);
}
static void
* 3DSTATE_SAMPLER_STATE_POINTER_VS command. Only one PIPE_CONTROL
* needs to be sent before any combination of VS associated 3DSTATE."
*/
- gen6_PIPE_CONTROL(&p->cp->builder,
+ gen6_PIPE_CONTROL(p->builder,
GEN6_PIPE_CONTROL_DEPTH_STALL |
GEN6_PIPE_CONTROL_WRITE_IMM,
p->workaround_bo, 0, false);
* guarantee that the pipeline from WM onwards is already flushed
* (e.g., via a preceding MI_FLUSH)."
*/
- gen6_PIPE_CONTROL(&p->cp->builder,
+ gen6_PIPE_CONTROL(p->builder,
GEN6_PIPE_CONTROL_DEPTH_STALL,
NULL, 0, false);
if (!change_depth_buffer)
return;
- gen6_PIPE_CONTROL(&p->cp->builder,
+ gen6_PIPE_CONTROL(p->builder,
GEN6_PIPE_CONTROL_DEPTH_CACHE_FLUSH,
NULL, 0, false);
- gen6_PIPE_CONTROL(&p->cp->builder,
+ gen6_PIPE_CONTROL(p->builder,
GEN6_PIPE_CONTROL_DEPTH_STALL,
NULL, 0, false);
}
* between 3DPRIMITIVE commands, a PIPE_CONTROL command with Stall at
* Pixel Scoreboard set is required to be issued."
*/
- gen6_PIPE_CONTROL(&p->cp->builder,
+ gen6_PIPE_CONTROL(p->builder,
GEN6_PIPE_CONTROL_PIXEL_SCOREBOARD_STALL,
NULL, 0, false);
gen7_wa_pipe_control_vs_depth_stall(p);
- gen7_3DSTATE_URB_VS(&p->cp->builder,
+ gen7_3DSTATE_URB_VS(p->builder,
offset, vs_total_size, vs_entry_size);
- gen7_3DSTATE_URB_GS(&p->cp->builder, offset, 0, 0);
- gen7_3DSTATE_URB_HS(&p->cp->builder, offset, 0, 0);
- gen7_3DSTATE_URB_DS(&p->cp->builder, offset, 0, 0);
+ gen7_3DSTATE_URB_GS(p->builder, offset, 0, 0);
+ gen7_3DSTATE_URB_HS(p->builder, offset, 0, 0);
+ gen7_3DSTATE_URB_DS(p->builder, offset, 0, 0);
}
}
const int size = max_size / 2;
int offset = 0;
- gen7_3DSTATE_PUSH_CONSTANT_ALLOC_VS(&p->cp->builder, offset, size);
+ gen7_3DSTATE_PUSH_CONSTANT_ALLOC_VS(p->builder, offset, size);
offset += size;
- gen7_3DSTATE_PUSH_CONSTANT_ALLOC_PS(&p->cp->builder, offset, size);
+ gen7_3DSTATE_PUSH_CONSTANT_ALLOC_PS(p->builder, offset, size);
if (ilo_dev_gen(p->dev) == ILO_GEN(7))
gen7_wa_pipe_control_cs_stall(p, true, true);
{
/* 3DSTATE_VIEWPORT_STATE_POINTERS_{CC,SF_CLIP} */
if (session->viewport_state_changed) {
- gen7_3DSTATE_VIEWPORT_STATE_POINTERS_CC(&p->cp->builder,
+ gen7_3DSTATE_VIEWPORT_STATE_POINTERS_CC(p->builder,
p->state.CC_VIEWPORT);
- gen7_3DSTATE_VIEWPORT_STATE_POINTERS_SF_CLIP(&p->cp->builder,
+ gen7_3DSTATE_VIEWPORT_STATE_POINTERS_SF_CLIP(p->builder,
p->state.SF_CLIP_VIEWPORT);
}
}
{
/* 3DSTATE_BLEND_STATE_POINTERS */
if (session->cc_state_blend_changed) {
- gen7_3DSTATE_BLEND_STATE_POINTERS(&p->cp->builder,
+ gen7_3DSTATE_BLEND_STATE_POINTERS(p->builder,
p->state.BLEND_STATE);
}
/* 3DSTATE_CC_STATE_POINTERS */
if (session->cc_state_cc_changed) {
- gen7_3DSTATE_CC_STATE_POINTERS(&p->cp->builder,
+ gen7_3DSTATE_CC_STATE_POINTERS(p->builder,
p->state.COLOR_CALC_STATE);
}
/* 3DSTATE_DEPTH_STENCIL_STATE_POINTERS */
if (session->cc_state_dsa_changed) {
- gen7_3DSTATE_DEPTH_STENCIL_STATE_POINTERS(&p->cp->builder,
+ gen7_3DSTATE_DEPTH_STENCIL_STATE_POINTERS(p->builder,
p->state.DEPTH_STENCIL_STATE);
}
}
/* 3DSTATE_BINDING_TABLE_POINTERS_VS */
if (emit_3dstate_binding_table) {
- gen7_3DSTATE_BINDING_TABLE_POINTERS_VS(&p->cp->builder,
+ gen7_3DSTATE_BINDING_TABLE_POINTERS_VS(p->builder,
p->state.vs.BINDING_TABLE_STATE);
}
/* 3DSTATE_SAMPLER_STATE_POINTERS_VS */
if (emit_3dstate_sampler_state) {
- gen7_3DSTATE_SAMPLER_STATE_POINTERS_VS(&p->cp->builder,
+ gen7_3DSTATE_SAMPLER_STATE_POINTERS_VS(p->builder,
p->state.vs.SAMPLER_STATE);
}
/* 3DSTATE_CONSTANT_VS */
if (emit_3dstate_constant_vs) {
- gen7_3DSTATE_CONSTANT_VS(&p->cp->builder,
+ gen7_3DSTATE_CONSTANT_VS(p->builder,
&p->state.vs.PUSH_CONSTANT_BUFFER,
&p->state.vs.PUSH_CONSTANT_BUFFER_size,
1);
if (emit_3dstate_vs) {
const int num_samplers = vec->sampler[PIPE_SHADER_VERTEX].count;
- gen6_3DSTATE_VS(&p->cp->builder, vec->vs, num_samplers);
+ gen6_3DSTATE_VS(p->builder, vec->vs, num_samplers);
}
}
{
/* 3DSTATE_CONSTANT_HS and 3DSTATE_HS */
if (session->hw_ctx_changed) {
- gen7_3DSTATE_CONSTANT_HS(&p->cp->builder, 0, 0, 0);
- gen7_3DSTATE_HS(&p->cp->builder, NULL, 0);
+ gen7_3DSTATE_CONSTANT_HS(p->builder, 0, 0, 0);
+ gen7_3DSTATE_HS(p->builder, NULL, 0);
}
/* 3DSTATE_BINDING_TABLE_POINTERS_HS */
if (session->hw_ctx_changed)
- gen7_3DSTATE_BINDING_TABLE_POINTERS_HS(&p->cp->builder, 0);
+ gen7_3DSTATE_BINDING_TABLE_POINTERS_HS(p->builder, 0);
}
static void
{
/* 3DSTATE_TE */
if (session->hw_ctx_changed)
- gen7_3DSTATE_TE(&p->cp->builder);
+ gen7_3DSTATE_TE(p->builder);
}
static void
{
/* 3DSTATE_CONSTANT_DS and 3DSTATE_DS */
if (session->hw_ctx_changed) {
- gen7_3DSTATE_CONSTANT_DS(&p->cp->builder, 0, 0, 0);
- gen7_3DSTATE_DS(&p->cp->builder, NULL, 0);
+ gen7_3DSTATE_CONSTANT_DS(p->builder, 0, 0, 0);
+ gen7_3DSTATE_DS(p->builder, NULL, 0);
}
/* 3DSTATE_BINDING_TABLE_POINTERS_DS */
if (session->hw_ctx_changed)
- gen7_3DSTATE_BINDING_TABLE_POINTERS_DS(&p->cp->builder, 0);
+ gen7_3DSTATE_BINDING_TABLE_POINTERS_DS(p->builder, 0);
}
{
/* 3DSTATE_CONSTANT_GS and 3DSTATE_GS */
if (session->hw_ctx_changed) {
- gen7_3DSTATE_CONSTANT_GS(&p->cp->builder, 0, 0, 0);
- gen7_3DSTATE_GS(&p->cp->builder, NULL, 0);
+ gen7_3DSTATE_CONSTANT_GS(p->builder, 0, 0, 0);
+ gen7_3DSTATE_GS(p->builder, NULL, 0);
}
/* 3DSTATE_BINDING_TABLE_POINTERS_GS */
if (session->binding_table_gs_changed) {
- gen7_3DSTATE_BINDING_TABLE_POINTERS_GS(&p->cp->builder,
+ gen7_3DSTATE_BINDING_TABLE_POINTERS_GS(p->builder,
p->state.gs.BINDING_TABLE_STATE);
}
}
const int stride = so_info->stride[i] * 4; /* in bytes */
int base = 0;
- gen7_3DSTATE_SO_BUFFER(&p->cp->builder, i, base, stride,
+ gen7_3DSTATE_SO_BUFFER(p->builder, i, base, stride,
vec->so.states[i]);
}
for (; i < 4; i++)
- gen7_3DSTATE_SO_BUFFER(&p->cp->builder, i, 0, 0, NULL);
+ gen7_3DSTATE_SO_BUFFER(p->builder, i, 0, 0, NULL);
}
/* 3DSTATE_SO_DECL_LIST */
if (dirty_sh && vec->so.enabled)
- gen7_3DSTATE_SO_DECL_LIST(&p->cp->builder, so_info);
+ gen7_3DSTATE_SO_DECL_LIST(p->builder, so_info);
/* 3DSTATE_STREAMOUT */
if (DIRTY(SO) || DIRTY(RASTERIZER) || dirty_sh) {
const int output_count = ilo_shader_get_kernel_param(shader,
ILO_KERNEL_OUTPUT_COUNT);
- gen7_3DSTATE_STREAMOUT(&p->cp->builder, buffer_mask, output_count,
+ gen7_3DSTATE_STREAMOUT(p->builder, buffer_mask, output_count,
vec->rasterizer->state.rasterizer_discard);
}
}
{
/* 3DSTATE_SBE */
if (DIRTY(RASTERIZER) || DIRTY(FS))
- gen7_3DSTATE_SBE(&p->cp->builder, vec->rasterizer, vec->fs);
+ gen7_3DSTATE_SBE(p->builder, vec->rasterizer, vec->fs);
/* 3DSTATE_SF */
if (DIRTY(RASTERIZER) || DIRTY(FB)) {
struct pipe_surface *zs = vec->fb.state.zsbuf;
gen7_wa_pipe_control_cs_stall(p, true, true);
- gen7_3DSTATE_SF(&p->cp->builder, vec->rasterizer,
+ gen7_3DSTATE_SF(p->builder, vec->rasterizer,
(zs) ? zs->format : PIPE_FORMAT_NONE);
}
}
const bool cc_may_kill = (vec->dsa->dw_alpha ||
vec->blend->alpha_to_coverage);
- gen7_3DSTATE_WM(&p->cp->builder, vec->fs,
+ gen7_3DSTATE_WM(p->builder, vec->fs,
vec->rasterizer, cc_may_kill, 0);
}
/* 3DSTATE_BINDING_TABLE_POINTERS_PS */
if (session->binding_table_fs_changed) {
- gen7_3DSTATE_BINDING_TABLE_POINTERS_PS(&p->cp->builder,
+ gen7_3DSTATE_BINDING_TABLE_POINTERS_PS(p->builder,
p->state.wm.BINDING_TABLE_STATE);
}
/* 3DSTATE_SAMPLER_STATE_POINTERS_PS */
if (session->sampler_state_fs_changed) {
- gen7_3DSTATE_SAMPLER_STATE_POINTERS_PS(&p->cp->builder,
+ gen7_3DSTATE_SAMPLER_STATE_POINTERS_PS(p->builder,
p->state.wm.SAMPLER_STATE);
}
/* 3DSTATE_CONSTANT_PS */
if (session->pcb_state_fs_changed) {
- gen7_3DSTATE_CONSTANT_PS(&p->cp->builder,
+ gen7_3DSTATE_CONSTANT_PS(p->builder,
&p->state.wm.PUSH_CONSTANT_BUFFER,
&p->state.wm.PUSH_CONSTANT_BUFFER_size,
1);
session->hw_ctx_changed)
gen7_wa_pipe_control_ps_max_threads_stall(p);
- gen7_3DSTATE_PS(&p->cp->builder, vec->fs, num_samplers, dual_blend);
+ gen7_3DSTATE_PS(p->builder, vec->fs, num_samplers, dual_blend);
}
/* 3DSTATE_SCISSOR_STATE_POINTERS */
if (session->scissor_state_changed) {
- gen6_3DSTATE_SCISSOR_STATE_POINTERS(&p->cp->builder,
+ gen6_3DSTATE_SCISSOR_STATE_POINTERS(p->builder,
p->state.SCISSOR_RECT);
}
clear_params = 0;
}
- gen6_3DSTATE_DEPTH_BUFFER(&p->cp->builder, zs);
- gen6_3DSTATE_HIER_DEPTH_BUFFER(&p->cp->builder, zs);
- gen6_3DSTATE_STENCIL_BUFFER(&p->cp->builder, zs);
- gen7_3DSTATE_CLEAR_PARAMS(&p->cp->builder, clear_params);
+ gen6_3DSTATE_DEPTH_BUFFER(p->builder, zs);
+ gen6_3DSTATE_HIER_DEPTH_BUFFER(p->builder, zs);
+ gen6_3DSTATE_STENCIL_BUFFER(p->builder, zs);
+ gen7_3DSTATE_CLEAR_PARAMS(p->builder, clear_params);
}
}
(vec->fb.num_samples > 1) ? &p->packed_sample_position_4x :
&p->packed_sample_position_1x;
- gen6_3DSTATE_MULTISAMPLE(&p->cp->builder,
+ gen6_3DSTATE_MULTISAMPLE(p->builder,
vec->fb.num_samples, packed_sample_pos,
vec->rasterizer->state.half_pixel_center);
- gen7_3DSTATE_SAMPLE_MASK(&p->cp->builder,
+ gen7_3DSTATE_SAMPLE_MASK(p->builder,
(vec->fb.num_samples > 1) ? vec->sample_mask : 0x1,
vec->fb.num_samples);
}
struct gen6_pipeline_session *session)
{
/* 3DPRIMITIVE */
- gen7_3DPRIMITIVE(&p->cp->builder, vec->draw, &vec->ib);
+ gen7_3DPRIMITIVE(p->builder, vec->draw, &vec->ib);
p->state.has_gen6_wa_pipe_control = false;
}
const int size = max_size / 2;
int offset = 0;
- gen7_3DSTATE_PUSH_CONSTANT_ALLOC_VS(&p->cp->builder, offset, size);
+ gen7_3DSTATE_PUSH_CONSTANT_ALLOC_VS(p->builder, offset, size);
offset += size;
- gen7_3DSTATE_PUSH_CONSTANT_ALLOC_PS(&p->cp->builder, offset, size);
+ gen7_3DSTATE_PUSH_CONSTANT_ALLOC_PS(p->builder, offset, size);
gen7_wa_pipe_control_cs_stall(p, true, true);
}
const int offset =
(ilo_dev_gen(p->dev) == ILO_GEN(7.5) && p->dev->gt == 3) ? 32768 : 16384;
- gen7_3DSTATE_URB_VS(&p->cp->builder, offset, p->dev->urb_size - offset,
+ gen7_3DSTATE_URB_VS(p->builder, offset, p->dev->urb_size - offset,
blitter->ve.count * 4 * sizeof(float));
- gen7_3DSTATE_URB_GS(&p->cp->builder, offset, 0, 0);
- gen7_3DSTATE_URB_HS(&p->cp->builder, offset, 0, 0);
- gen7_3DSTATE_URB_DS(&p->cp->builder, offset, 0, 0);
+ gen7_3DSTATE_URB_GS(p->builder, offset, 0, 0);
+ gen7_3DSTATE_URB_HS(p->builder, offset, 0, 0);
+ gen7_3DSTATE_URB_DS(p->builder, offset, 0, 0);
}
static void
const struct ilo_blitter *blitter,
struct gen6_rectlist_session *session)
{
- gen7_3DSTATE_CONSTANT_VS(&p->cp->builder, NULL, NULL, 0);
- gen6_3DSTATE_VS(&p->cp->builder, NULL, 0);
+ gen7_3DSTATE_CONSTANT_VS(p->builder, NULL, NULL, 0);
+ gen6_3DSTATE_VS(p->builder, NULL, 0);
- gen7_3DSTATE_CONSTANT_HS(&p->cp->builder, NULL, NULL, 0);
- gen7_3DSTATE_HS(&p->cp->builder, NULL, 0);
+ gen7_3DSTATE_CONSTANT_HS(p->builder, NULL, NULL, 0);
+ gen7_3DSTATE_HS(p->builder, NULL, 0);
- gen7_3DSTATE_TE(&p->cp->builder);
+ gen7_3DSTATE_TE(p->builder);
- gen7_3DSTATE_CONSTANT_DS(&p->cp->builder, NULL, NULL, 0);
- gen7_3DSTATE_DS(&p->cp->builder, NULL, 0);
+ gen7_3DSTATE_CONSTANT_DS(p->builder, NULL, NULL, 0);
+ gen7_3DSTATE_DS(p->builder, NULL, 0);
- gen7_3DSTATE_CONSTANT_GS(&p->cp->builder, NULL, NULL, 0);
- gen7_3DSTATE_GS(&p->cp->builder, NULL, 0);
+ gen7_3DSTATE_CONSTANT_GS(p->builder, NULL, NULL, 0);
+ gen7_3DSTATE_GS(p->builder, NULL, 0);
- gen7_3DSTATE_STREAMOUT(&p->cp->builder, 0x0, 0, false);
+ gen7_3DSTATE_STREAMOUT(p->builder, 0x0, 0, false);
- gen6_3DSTATE_CLIP(&p->cp->builder, NULL, NULL, false, 0);
+ gen6_3DSTATE_CLIP(p->builder, NULL, NULL, false, 0);
gen7_wa_pipe_control_cs_stall(p, true, true);
- gen7_3DSTATE_SF(&p->cp->builder, NULL, blitter->fb.dst.base.format);
- gen7_3DSTATE_SBE(&p->cp->builder, NULL, NULL);
+ gen7_3DSTATE_SF(p->builder, NULL, blitter->fb.dst.base.format);
+ gen7_3DSTATE_SBE(p->builder, NULL, NULL);
}
static void
break;
}
- gen7_3DSTATE_WM(&p->cp->builder, NULL, NULL, false, hiz_op);
+ gen7_3DSTATE_WM(p->builder, NULL, NULL, false, hiz_op);
- gen7_3DSTATE_CONSTANT_PS(&p->cp->builder, NULL, NULL, 0);
+ gen7_3DSTATE_CONSTANT_PS(p->builder, NULL, NULL, 0);
gen7_wa_pipe_control_ps_max_threads_stall(p);
- gen7_3DSTATE_PS(&p->cp->builder, NULL, 0, false);
+ gen7_3DSTATE_PS(p->builder, NULL, 0, false);
}
static void
if (blitter->uses & (ILO_BLITTER_USE_FB_DEPTH |
ILO_BLITTER_USE_FB_STENCIL)) {
- gen6_3DSTATE_DEPTH_BUFFER(&p->cp->builder,
+ gen6_3DSTATE_DEPTH_BUFFER(p->builder,
&blitter->fb.dst.u.zs);
}
if (blitter->uses & ILO_BLITTER_USE_FB_DEPTH) {
- gen6_3DSTATE_HIER_DEPTH_BUFFER(&p->cp->builder,
+ gen6_3DSTATE_HIER_DEPTH_BUFFER(p->builder,
&blitter->fb.dst.u.zs);
}
if (blitter->uses & ILO_BLITTER_USE_FB_STENCIL) {
- gen6_3DSTATE_STENCIL_BUFFER(&p->cp->builder,
+ gen6_3DSTATE_STENCIL_BUFFER(p->builder,
&blitter->fb.dst.u.zs);
}
- gen7_3DSTATE_CLEAR_PARAMS(&p->cp->builder,
+ gen7_3DSTATE_CLEAR_PARAMS(p->builder,
blitter->depth_clear_value);
}
gen7_wa_pipe_control_cs_stall(p, true, true);
- gen6_3DSTATE_MULTISAMPLE(&p->cp->builder, blitter->fb.num_samples,
+ gen6_3DSTATE_MULTISAMPLE(p->builder, blitter->fb.num_samples,
packed_sample_pos, true);
- gen7_3DSTATE_SAMPLE_MASK(&p->cp->builder,
+ gen7_3DSTATE_SAMPLE_MASK(p->builder,
(1 << blitter->fb.num_samples) - 1, blitter->fb.num_samples);
}
{
gen7_rectlist_wm_multisample(p, blitter, session);
- gen6_state_base_address(&p->cp->builder, true);
+ gen6_state_base_address(p->builder, true);
- gen6_3DSTATE_VERTEX_BUFFERS(&p->cp->builder,
+ gen6_3DSTATE_VERTEX_BUFFERS(p->builder,
&blitter->ve, &blitter->vb);
- gen6_3DSTATE_VERTEX_ELEMENTS(&p->cp->builder,
+ gen6_3DSTATE_VERTEX_ELEMENTS(p->builder,
&blitter->ve, false, false);
gen7_rectlist_pcb_alloc(p, blitter, session);
gen7_rectlist_urb(p, blitter, session);
if (blitter->uses & ILO_BLITTER_USE_DSA) {
- gen7_3DSTATE_DEPTH_STENCIL_STATE_POINTERS(&p->cp->builder,
+ gen7_3DSTATE_DEPTH_STENCIL_STATE_POINTERS(p->builder,
session->DEPTH_STENCIL_STATE);
}
if (blitter->uses & ILO_BLITTER_USE_CC) {
- gen7_3DSTATE_CC_STATE_POINTERS(&p->cp->builder,
+ gen7_3DSTATE_CC_STATE_POINTERS(p->builder,
session->COLOR_CALC_STATE);
}
gen7_rectlist_wm(p, blitter, session);
if (blitter->uses & ILO_BLITTER_USE_VIEWPORT) {
- gen7_3DSTATE_VIEWPORT_STATE_POINTERS_CC(&p->cp->builder,
+ gen7_3DSTATE_VIEWPORT_STATE_POINTERS_CC(p->builder,
session->CC_VIEWPORT);
}
gen7_rectlist_wm_depth(p, blitter, session);
- gen6_3DSTATE_DRAWING_RECTANGLE(&p->cp->builder, 0, 0,
+ gen6_3DSTATE_DRAWING_RECTANGLE(p->builder, 0, 0,
blitter->fb.width, blitter->fb.height);
- gen7_3DPRIMITIVE(&p->cp->builder, &blitter->draw, NULL);
+ gen7_3DPRIMITIVE(p->builder, &blitter->draw, NULL);
}
static void
{
if (blitter->uses & ILO_BLITTER_USE_DSA) {
session->DEPTH_STENCIL_STATE =
- gen6_DEPTH_STENCIL_STATE(&p->cp->builder, &blitter->dsa);
+ gen6_DEPTH_STENCIL_STATE(p->builder, &blitter->dsa);
}
if (blitter->uses & ILO_BLITTER_USE_CC) {
session->COLOR_CALC_STATE =
- gen6_COLOR_CALC_STATE(&p->cp->builder, &blitter->cc.stencil_ref,
+ gen6_COLOR_CALC_STATE(p->builder, &blitter->cc.stencil_ref,
blitter->cc.alpha_ref, &blitter->cc.blend_color);
}
if (blitter->uses & ILO_BLITTER_USE_VIEWPORT) {
session->CC_VIEWPORT =
- gen6_CC_VIEWPORT(&p->cp->builder, &blitter->viewport, 1);
+ gen6_CC_VIEWPORT(p->builder, &blitter->viewport, 1);
}
}