summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/softpipe/sp_state.h
diff options
context:
space:
mode:
authorDave Airlie <[email protected]>2016-04-26 14:32:52 +1000
committerDave Airlie <[email protected]>2016-04-27 09:01:03 +1000
commite749c30cebe071da450e28cb47b1b7deb8284a39 (patch)
treef979efb8e10bd77e8f83166efcd3777af4594a1c /src/gallium/drivers/softpipe/sp_state.h
parentf78bcb7638be3c2612fd1ab0371361a8b53104c7 (diff)
softpipe: add support for compute shaders. (v2)
This enables ARB_compute_shader on softpipe. I've only tested this with piglit so far, and I hopefully plan on integrating it with my vulkan work. I'll get to testing it with deqp more later. The basic premise is to create up to 1024 restartable TGSI machines, and execute workgroups of those machines. v1.1: free machines. v2: deqp fixes - add samplers support, finish atomic operations, fix load/store writemasks. Acked-by: Roland Scheidegger <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
Diffstat (limited to 'src/gallium/drivers/softpipe/sp_state.h')
-rw-r--r--src/gallium/drivers/softpipe/sp_state.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/gallium/drivers/softpipe/sp_state.h b/src/gallium/drivers/softpipe/sp_state.h
index 2fc48ab13d8..0ced70c305d 100644
--- a/src/gallium/drivers/softpipe/sp_state.h
+++ b/src/gallium/drivers/softpipe/sp_state.h
@@ -131,6 +131,13 @@ struct sp_so_state {
struct pipe_stream_output_info base;
};
+/** Subclass of pipe_compute_state */
+struct sp_compute_shader {
+ struct pipe_compute_state shader;
+ struct tgsi_token *tokens;
+ struct tgsi_shader_info info;
+ int max_sampler; /* -1 if no samplers */
+};
void
softpipe_init_blend_funcs(struct pipe_context *pipe);
@@ -213,4 +220,10 @@ void
softpipe_cleanup_geometry_sampling(struct softpipe_context *ctx);
+void
+softpipe_launch_grid(struct pipe_context *context,
+ const struct pipe_grid_info *info);
+
+void
+softpipe_update_compute_samplers(struct softpipe_context *softpipe);
#endif