2 * Copyright 2011 Adam Rak <adam.rak@streamnovation.com>
4 * Permission is hereby granted, free of charge, to any person obtaining a
5 * copy of this software and associated documentation files (the "Software"),
6 * to deal in the Software without restriction, including without limitation
7 * on the rights to use, copy, modify, merge, publish, distribute, sub
8 * license, and/or sell copies of the Software, and to permit persons to whom
9 * the Software is furnished to do so, subject to the following conditions:
11 * The above copyright notice and this permission notice (including the next
12 * paragraph) shall be included in all copies or substantial portions of the
15 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17 * FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL
18 * THE AUTHOR(S) AND/OR THEIR SUPPLIERS BE LIABLE FOR ANY CLAIM,
19 * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
20 * OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
21 * USE OR OTHER DEALINGS IN THE SOFTWARE.
24 * Adam Rak <adam.rak@streamnovation.com>
27 #ifndef EVERGREEN_COMPUTE_H
28 #define EVERGREEN_COMPUTE_H
30 #include "r600_pipe.h"
33 struct evergreen_compute_resource
;
34 struct compute_memory_item
;
36 struct r600_resource_global
{
37 struct r600_resource base
;
38 struct compute_memory_item
*chunk
;
41 void evergreen_init_atom_start_compute_cs(struct r600_context
*rctx
);
42 void evergreen_init_compute_state_functions(struct r600_context
*rctx
);
43 void evergreen_emit_cs_shader(struct r600_context
*rctx
, struct r600_atom
* atom
);
45 struct r600_resource
* r600_compute_buffer_alloc_vram(struct r600_screen
*screen
, unsigned size
);
46 struct pipe_resource
*r600_compute_global_buffer_create(struct pipe_screen
*screen
, const struct pipe_resource
*templ
);