iris: emit shader packets

This commit is contained in:
Kenneth Graunke
2018-01-22 22:40:51 -08:00
parent 1cf21cc813
commit cfd5fcc256
+17
View File
@@ -1525,6 +1525,23 @@ iris_upload_render_state(struct iris_context *ice,
}
}
for (int stage = 0; stage <= MESA_SHADER_FRAGMENT; stage++) {
if (!(dirty & (IRIS_DIRTY_VS << stage)))
continue;
if (ice->shaders.prog[stage]) {
iris_batch_emit(batch, ice->shaders.prog[stage]->derived_data,
iris_derived_program_state_size(stage));
} else {
if (stage == MESA_SHADER_TESS_EVAL) {
iris_emit_cmd(batch, GENX(3DSTATE_HS), hs);
iris_emit_cmd(batch, GENX(3DSTATE_DS), ds);
} else if (stage == MESA_SHADER_GEOMETRY) {
iris_emit_cmd(batch, GENX(3DSTATE_GS), gs);
}
}
}
for (int stage = 0; stage <= MESA_SHADER_FRAGMENT; stage++) {
if (!(dirty & (IRIS_DIRTY_SAMPLER_STATES_VS << stage)))
continue;