diff --git a/src/gallium/drivers/i915/i915_state.c b/src/gallium/drivers/i915/i915_state.c index 8d786c02e41..af45247355d 100644 --- a/src/gallium/drivers/i915/i915_state.c +++ b/src/gallium/drivers/i915/i915_state.c @@ -667,28 +667,11 @@ i915_create_vs_state(struct pipe_context *pipe, const struct pipe_shader_state *templ) { struct i915_context *i915 = i915_context(pipe); - void *vertex_shader; - struct pipe_shader_state from_nir = {PIPE_SHADER_IR_TGSI}; - if (templ->type == PIPE_SHADER_IR_NIR) { - nir_shader *s = templ->ir.nir; + if (templ->type == PIPE_SHADER_IR_NIR) + NIR_PASS(_, templ->ir.nir, nir_lower_point_size, 1.0, 255.0); - NIR_PASS(_, s, nir_lower_point_size, 1.0, 255.0); - - /* The gallivm draw path doesn't support non-native-integers NIR shaders, - * st/mesa does native-integers for the screen as a whole rather than - * per-stage, and i915 FS can't do native integers. So, convert to TGSI, - * where the draw path *does* support non-native-integers. - */ - from_nir.tokens = nir_to_tgsi(s, pipe->screen); - templ = &from_nir; - } - - vertex_shader = draw_create_vertex_shader(i915->draw, templ); - - FREE((void *)from_nir.tokens); - - return vertex_shader; + return draw_create_vertex_shader(i915->draw, templ); } static void