struct intel_bo *workaround_bo;
- uint32_t packed_sample_position_1x;
- uint32_t packed_sample_position_4x;
- uint32_t packed_sample_position_8x[2];
+ uint32_t sample_pattern_1x;
+ uint32_t sample_pattern_2x;
+ uint32_t sample_pattern_4x;
+ uint32_t sample_pattern_8x[2];
+ uint32_t sample_pattern_16x[4];
bool hw_ctx_changed;
struct {
uint32_t BINDING_TABLE_STATE;
- int BINDING_TABLE_STATE_size;
- uint32_t SURFACE_STATE[ILO_MAX_VS_SURFACES];
+ uint32_t SURFACE_STATE[ILO_MAX_SURFACES];
uint32_t SAMPLER_STATE;
uint32_t SAMPLER_BORDER_COLOR_STATE[ILO_MAX_SAMPLERS];
uint32_t PUSH_CONSTANT_BUFFER;
struct {
uint32_t BINDING_TABLE_STATE;
- int BINDING_TABLE_STATE_size;
- uint32_t SURFACE_STATE[ILO_MAX_GS_SURFACES];
+ uint32_t SURFACE_STATE[ILO_MAX_SURFACES];
bool active;
} gs;
struct {
uint32_t BINDING_TABLE_STATE;
- int BINDING_TABLE_STATE_size;
- uint32_t SURFACE_STATE[ILO_MAX_WM_SURFACES];
+ uint32_t SURFACE_STATE[ILO_MAX_SURFACES];
uint32_t SAMPLER_STATE;
uint32_t SAMPLER_BORDER_COLOR_STATE[ILO_MAX_SAMPLERS];
uint32_t PUSH_CONSTANT_BUFFER;
int PUSH_CONSTANT_BUFFER_size;
} wm;
+
+ struct {
+ uint32_t BINDING_TABLE_STATE;
+ uint32_t SURFACE_STATE[ILO_MAX_SURFACES];
+ uint32_t SAMPLER_STATE;
+ uint32_t SAMPLER_BORDER_COLOR_STATE[ILO_MAX_SAMPLERS];
+ uint32_t PUSH_CONSTANT_BUFFER;
+ int PUSH_CONSTANT_BUFFER_size;
+ } cs;
} state;
};
-struct gen6_draw_session {
+struct ilo_render_draw_session {
uint32_t pipe_dirty;
/* commands */
bool binding_table_vs_changed;
bool binding_table_gs_changed;
bool binding_table_fs_changed;
+};
- int num_surfaces[PIPE_SHADER_TYPES];
+struct ilo_render_rectlist_session {
+ uint32_t vb_start;
+ uint32_t vb_end;
+};
+
+struct ilo_render_launch_grid_session {
+ const unsigned *thread_group_offset;
+ const unsigned *thread_group_dim;
+ unsigned thread_group_size;
+ const struct pipe_constant_buffer *input;
+ uint32_t pc;
+
+ uint32_t idrt;
+ int idrt_size;
};
int
ilo_render_get_draw_commands_len_gen7(const struct ilo_render *render,
const struct ilo_state_vector *vec);
+int
+ilo_render_get_draw_commands_len_gen8(const struct ilo_render *render,
+ const struct ilo_state_vector *vec);
+
static inline int
ilo_render_get_draw_commands_len(const struct ilo_render *render,
const struct ilo_state_vector *vec)
{
- if (ilo_dev_gen(render->dev) >= ILO_GEN(7))
+ if (ilo_dev_gen(render->dev) >= ILO_GEN(8))
+ return ilo_render_get_draw_commands_len_gen8(render, vec);
+ else if (ilo_dev_gen(render->dev) >= ILO_GEN(7))
return ilo_render_get_draw_commands_len_gen7(render, vec);
else
return ilo_render_get_draw_commands_len_gen6(render, vec);
void
ilo_render_emit_draw_commands_gen6(struct ilo_render *render,
const struct ilo_state_vector *vec,
- struct gen6_draw_session *session);
+ struct ilo_render_draw_session *session);
void
ilo_render_emit_draw_commands_gen7(struct ilo_render *render,
const struct ilo_state_vector *vec,
- struct gen6_draw_session *session);
+ struct ilo_render_draw_session *session);
+
+void
+ilo_render_emit_draw_commands_gen8(struct ilo_render *render,
+ const struct ilo_state_vector *vec,
+ struct ilo_render_draw_session *session);
static inline void
ilo_render_emit_draw_commands(struct ilo_render *render,
const struct ilo_state_vector *vec,
- struct gen6_draw_session *session)
+ struct ilo_render_draw_session *session)
{
const unsigned batch_used = ilo_builder_batch_used(render->builder);
- if (ilo_dev_gen(render->dev) >= ILO_GEN(7))
+ if (ilo_dev_gen(render->dev) >= ILO_GEN(8))
+ ilo_render_emit_draw_commands_gen8(render, vec, session);
+ else if (ilo_dev_gen(render->dev) >= ILO_GEN(7))
ilo_render_emit_draw_commands_gen7(render, vec, session);
else
ilo_render_emit_draw_commands_gen6(render, vec, session);
ilo_render_get_rectlist_commands_len_gen6(const struct ilo_render *render,
const struct ilo_blitter *blitter);
+int
+ilo_render_get_rectlist_commands_len_gen8(const struct ilo_render *render,
+ const struct ilo_blitter *blitter);
+
static inline int
ilo_render_get_rectlist_commands_len(const struct ilo_render *render,
const struct ilo_blitter *blitter)
{
- return ilo_render_get_rectlist_commands_len_gen6(render, blitter);
+ if (ilo_dev_gen(render->dev) >= ILO_GEN(8))
+ return ilo_render_get_rectlist_commands_len_gen8(render, blitter);
+ else
+ return ilo_render_get_rectlist_commands_len_gen6(render, blitter);
}
void
ilo_render_emit_rectlist_commands_gen6(struct ilo_render *r,
- const struct ilo_blitter *blitter);
+ const struct ilo_blitter *blitter,
+ const struct ilo_render_rectlist_session *session);
void
ilo_render_emit_rectlist_commands_gen7(struct ilo_render *r,
- const struct ilo_blitter *blitter);
+ const struct ilo_blitter *blitter,
+ const struct ilo_render_rectlist_session *session);
+
+void
+ilo_render_emit_rectlist_commands_gen8(struct ilo_render *r,
+ const struct ilo_blitter *blitter,
+ const struct ilo_render_rectlist_session *session);
static inline void
ilo_render_emit_rectlist_commands(struct ilo_render *render,
- const struct ilo_blitter *blitter)
+ const struct ilo_blitter *blitter,
+ const struct ilo_render_rectlist_session *session)
{
const unsigned batch_used = ilo_builder_batch_used(render->builder);
- if (ilo_dev_gen(render->dev) >= ILO_GEN(7))
- ilo_render_emit_rectlist_commands_gen7(render, blitter);
+ if (ilo_dev_gen(render->dev) >= ILO_GEN(8))
+ ilo_render_emit_rectlist_commands_gen8(render, blitter, session);
+ else if (ilo_dev_gen(render->dev) >= ILO_GEN(7))
+ ilo_render_emit_rectlist_commands_gen7(render, blitter, session);
else
- ilo_render_emit_rectlist_commands_gen6(render, blitter);
+ ilo_render_emit_rectlist_commands_gen6(render, blitter, session);
assert(ilo_builder_batch_used(render->builder) <= batch_used +
ilo_render_get_rectlist_commands_len(render, blitter));
}
+int
+ilo_render_get_launch_grid_commands_len(const struct ilo_render *render,
+ const struct ilo_state_vector *vec);
+
+void
+ilo_render_emit_launch_grid_commands(struct ilo_render *render,
+ const struct ilo_state_vector *vec,
+ const struct ilo_render_launch_grid_session *session);
+
int
ilo_render_get_draw_dynamic_states_len(const struct ilo_render *render,
const struct ilo_state_vector *vec);
void
ilo_render_emit_draw_dynamic_states(struct ilo_render *render,
const struct ilo_state_vector *vec,
- struct gen6_draw_session *session);
+ struct ilo_render_draw_session *session);
int
ilo_render_get_rectlist_dynamic_states_len(const struct ilo_render *render,
void
ilo_render_emit_rectlist_dynamic_states(struct ilo_render *render,
- const struct ilo_blitter *blitter);
+ const struct ilo_blitter *blitter,
+ struct ilo_render_rectlist_session *session);
+
+int
+ilo_render_get_launch_grid_dynamic_states_len(const struct ilo_render *render,
+ const struct ilo_state_vector *vec);
+
+void
+ilo_render_emit_launch_grid_dynamic_states(struct ilo_render *render,
+ const struct ilo_state_vector *vec,
+ struct ilo_render_launch_grid_session *session);
int
ilo_render_get_draw_surface_states_len(const struct ilo_render *render,
void
ilo_render_emit_draw_surface_states(struct ilo_render *render,
const struct ilo_state_vector *vec,
- struct gen6_draw_session *session);
+ struct ilo_render_draw_session *session);
+
+int
+ilo_render_get_launch_grid_surface_states_len(const struct ilo_render *render,
+ const struct ilo_state_vector *vec);
+
+void
+ilo_render_emit_launch_grid_surface_states(struct ilo_render *render,
+ const struct ilo_state_vector *vec,
+ struct ilo_render_launch_grid_session *session);
void
gen6_wa_pre_pipe_control(struct ilo_render *r, uint32_t dw1);
void
gen6_draw_common_select(struct ilo_render *r,
const struct ilo_state_vector *ilo,
- struct gen6_draw_session *session);
+ struct ilo_render_draw_session *session);
void
gen6_draw_common_sip(struct ilo_render *r,
const struct ilo_state_vector *ilo,
- struct gen6_draw_session *session);
+ struct ilo_render_draw_session *session);
void
gen6_draw_common_base_address(struct ilo_render *r,
const struct ilo_state_vector *ilo,
- struct gen6_draw_session *session);
+ struct ilo_render_draw_session *session);
void
gen6_draw_vf(struct ilo_render *r,
const struct ilo_state_vector *ilo,
- struct gen6_draw_session *session);
+ struct ilo_render_draw_session *session);
void
gen6_draw_vf_statistics(struct ilo_render *r,
const struct ilo_state_vector *ilo,
- struct gen6_draw_session *session);
+ struct ilo_render_draw_session *session);
void
gen6_draw_vs(struct ilo_render *r,
const struct ilo_state_vector *ilo,
- struct gen6_draw_session *session);
+ struct ilo_render_draw_session *session);
void
gen6_draw_clip(struct ilo_render *r,
const struct ilo_state_vector *ilo,
- struct gen6_draw_session *session);
+ struct ilo_render_draw_session *session);
void
gen6_draw_sf_rect(struct ilo_render *r,
const struct ilo_state_vector *ilo,
- struct gen6_draw_session *session);
+ struct ilo_render_draw_session *session);
void
gen6_draw_wm_raster(struct ilo_render *r,
const struct ilo_state_vector *ilo,
- struct gen6_draw_session *session);
+ struct ilo_render_draw_session *session);
+
+void
+gen7_draw_common_pcb_alloc(struct ilo_render *r,
+ const struct ilo_state_vector *vec,
+ struct ilo_render_draw_session *session);
+
+void
+gen7_draw_common_pointers_1(struct ilo_render *r,
+ const struct ilo_state_vector *vec,
+ struct ilo_render_draw_session *session);
+
+void
+gen7_draw_common_urb(struct ilo_render *r,
+ const struct ilo_state_vector *vec,
+ struct ilo_render_draw_session *session);
+
+void
+gen7_draw_common_pointers_2(struct ilo_render *r,
+ const struct ilo_state_vector *vec,
+ struct ilo_render_draw_session *session);
+
+void
+gen7_draw_vs(struct ilo_render *r,
+ const struct ilo_state_vector *vec,
+ struct ilo_render_draw_session *session);
+
+void
+gen7_draw_ds(struct ilo_render *r,
+ const struct ilo_state_vector *vec,
+ struct ilo_render_draw_session *session);
+
+void
+gen7_draw_te(struct ilo_render *r,
+ const struct ilo_state_vector *vec,
+ struct ilo_render_draw_session *session);
+
+void
+gen7_draw_hs(struct ilo_render *r,
+ const struct ilo_state_vector *vec,
+ struct ilo_render_draw_session *session);
+
+void
+gen7_draw_gs(struct ilo_render *r,
+ const struct ilo_state_vector *vec,
+ struct ilo_render_draw_session *session);
+
+void
+gen7_draw_sol(struct ilo_render *r,
+ const struct ilo_state_vector *vec,
+ struct ilo_render_draw_session *session);
+
+void
+gen7_draw_vf_draw(struct ilo_render *r,
+ const struct ilo_state_vector *vec,
+ struct ilo_render_draw_session *session);
#endif /* ILO_RENDER_GEN_H */