mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-22 11:20:11 +01:00
freedreno/a5xx: Drop fd5_compute_stateobj
It wasn't really doing anything useful. Signed-off-by: Rob Clark <robdclark@chromium.org> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8795>
This commit is contained in:
parent
6ed94905a6
commit
d2bcbb6792
1 changed files with 3 additions and 18 deletions
|
|
@ -32,10 +32,6 @@
|
||||||
#include "fd5_context.h"
|
#include "fd5_context.h"
|
||||||
#include "fd5_emit.h"
|
#include "fd5_emit.h"
|
||||||
|
|
||||||
struct fd5_compute_stateobj {
|
|
||||||
struct ir3_shader *shader;
|
|
||||||
};
|
|
||||||
|
|
||||||
|
|
||||||
static void *
|
static void *
|
||||||
fd5_create_compute_state(struct pipe_context *pctx,
|
fd5_create_compute_state(struct pipe_context *pctx,
|
||||||
|
|
@ -55,17 +51,7 @@ fd5_create_compute_state(struct pipe_context *pctx,
|
||||||
}
|
}
|
||||||
|
|
||||||
struct ir3_compiler *compiler = ctx->screen->compiler;
|
struct ir3_compiler *compiler = ctx->screen->compiler;
|
||||||
struct fd5_compute_stateobj *so = CALLOC_STRUCT(fd5_compute_stateobj);
|
return ir3_shader_create_compute(compiler, cso, &ctx->debug, pctx->screen);
|
||||||
so->shader = ir3_shader_create_compute(compiler, cso, &ctx->debug, pctx->screen);
|
|
||||||
return so;
|
|
||||||
}
|
|
||||||
|
|
||||||
static void
|
|
||||||
fd5_delete_compute_state(struct pipe_context *pctx, void *hwcso)
|
|
||||||
{
|
|
||||||
struct fd5_compute_stateobj *so = hwcso;
|
|
||||||
ir3_shader_state_delete(pctx, so->shader);
|
|
||||||
free(so);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/* maybe move to fd5_program? */
|
/* maybe move to fd5_program? */
|
||||||
|
|
@ -152,13 +138,12 @@ cs_program_emit(struct fd_ringbuffer *ring, struct ir3_shader_variant *v,
|
||||||
static void
|
static void
|
||||||
fd5_launch_grid(struct fd_context *ctx, const struct pipe_grid_info *info)
|
fd5_launch_grid(struct fd_context *ctx, const struct pipe_grid_info *info)
|
||||||
{
|
{
|
||||||
struct fd5_compute_stateobj *so = ctx->compute;
|
|
||||||
struct ir3_shader_key key = {};
|
struct ir3_shader_key key = {};
|
||||||
struct ir3_shader_variant *v;
|
struct ir3_shader_variant *v;
|
||||||
struct fd_ringbuffer *ring = ctx->batch->draw;
|
struct fd_ringbuffer *ring = ctx->batch->draw;
|
||||||
unsigned nglobal = 0;
|
unsigned nglobal = 0;
|
||||||
|
|
||||||
v = ir3_shader_variant(so->shader, key, false, &ctx->debug);
|
v = ir3_shader_variant(ctx->compute, key, false, &ctx->debug);
|
||||||
if (!v)
|
if (!v)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
|
@ -232,5 +217,5 @@ fd5_compute_init(struct pipe_context *pctx)
|
||||||
struct fd_context *ctx = fd_context(pctx);
|
struct fd_context *ctx = fd_context(pctx);
|
||||||
ctx->launch_grid = fd5_launch_grid;
|
ctx->launch_grid = fd5_launch_grid;
|
||||||
pctx->create_compute_state = fd5_create_compute_state;
|
pctx->create_compute_state = fd5_create_compute_state;
|
||||||
pctx->delete_compute_state = fd5_delete_compute_state;
|
pctx->delete_compute_state = ir3_shader_state_delete;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue