uint32_t key_size,
uint32_t *kernel_out,
void *prog_data_out);
-bool iris_blorp_upload_shader(struct blorp_batch *blorp_batch,
+bool iris_blorp_upload_shader(struct blorp_batch *blorp_batch, uint32_t stage,
const void *key, uint32_t key_size,
const void *kernel, uint32_t kernel_size,
const struct brw_stage_prog_data *prog_data,
}
bool
-iris_blorp_upload_shader(struct blorp_batch *blorp_batch,
+iris_blorp_upload_shader(struct blorp_batch *blorp_batch, uint32_t stage,
const void *key, uint32_t key_size,
const void *kernel, UNUSED uint32_t kernel_size,
const struct brw_stage_prog_data *prog_data_templ,
&prog_data_tmp, &vue_map, &program_size);
bool result =
- blorp->upload_shader(batch, &key, sizeof(key), program, program_size,
+ blorp->upload_shader(batch, MESA_SHADER_NONE,
+ &key, sizeof(key), program, program_size,
(void *)&prog_data_tmp, sizeof(prog_data_tmp),
¶ms->sf_prog_kernel, ¶ms->sf_prog_data);
const void *key, uint32_t key_size,
uint32_t *kernel_out, void *prog_data_out);
bool (*upload_shader)(struct blorp_batch *batch,
+ uint32_t stage,
const void *key, uint32_t key_size,
const void *kernel, uint32_t kernel_size,
const struct brw_stage_prog_data *prog_data,
&prog_data);
bool result =
- blorp->upload_shader(batch, prog_key, sizeof(*prog_key),
+ blorp->upload_shader(batch, MESA_SHADER_FRAGMENT,
+ prog_key, sizeof(*prog_key),
program, prog_data.base.program_size,
&prog_data.base, sizeof(prog_data),
¶ms->wm_prog_kernel, ¶ms->wm_prog_data);
&prog_data);
bool result =
- blorp->upload_shader(batch, &blorp_key, sizeof(blorp_key),
+ blorp->upload_shader(batch, MESA_SHADER_FRAGMENT,
+ &blorp_key, sizeof(blorp_key),
program, prog_data.base.program_size,
&prog_data.base, sizeof(prog_data),
¶ms->wm_prog_kernel, ¶ms->wm_prog_data);
blorp_compile_vs(blorp, mem_ctx, b.shader, &vs_prog_data);
bool result =
- blorp->upload_shader(batch, &blorp_key, sizeof(blorp_key),
+ blorp->upload_shader(batch, MESA_SHADER_VERTEX,
+ &blorp_key, sizeof(blorp_key),
program, vs_prog_data.base.base.program_size,
&vs_prog_data.base.base, sizeof(vs_prog_data),
¶ms->vs_prog_kernel, ¶ms->vs_prog_data);
&prog_data);
bool result =
- blorp->upload_shader(batch, &blorp_key, sizeof(blorp_key),
+ blorp->upload_shader(batch, MESA_SHADER_FRAGMENT,
+ &blorp_key, sizeof(blorp_key),
program, prog_data.base.program_size,
&prog_data.base, sizeof(prog_data),
¶ms->wm_prog_kernel, ¶ms->wm_prog_data);
}
static bool
-upload_blorp_shader(struct blorp_batch *batch,
+upload_blorp_shader(struct blorp_batch *batch, uint32_t stage,
const void *key, uint32_t key_size,
const void *kernel, uint32_t kernel_size,
const struct brw_stage_prog_data *prog_data,
.sampler_count = 0,
};
- /* The stage in anv_shader_bin is only useful for pipeline shaders, so just pass
- * a dummy value here so we don't need to change BLORP API.
- *
- * TODO: Plumb the stage information to BLORP.
- */
- gl_shader_stage stage = MESA_SHADER_NONE;
struct anv_shader_bin *bin =
anv_pipeline_cache_upload_kernel(&device->default_pipeline_cache, stage,
key, key_size, kernel, kernel_size,
}
static bool
-brw_blorp_upload_shader(struct blorp_batch *batch,
+brw_blorp_upload_shader(struct blorp_batch *batch, uint32_t stage,
const void *key, uint32_t key_size,
const void *kernel, uint32_t kernel_size,
const struct brw_stage_prog_data *prog_data,