mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-08 15:38:09 +02:00
compiler/glsl: Move glsl specific _mesa_glsl_initialize_types out and glsl_symbol_table of glsl_types.h
To make sure C-ABI compat, struct _mesa_glsl_parse_state; struct gl_shader_program; struct gl_builtin_uniform_desc; are wrapped with extern "C" And getting _mesa_glsl_initialize_variables c-compat for consistence Signed-off-by: Yonggang Luo <luoyonggang@gmail.com> Reviewed-by: Caio Oliveira <caio.oliveira@intel.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26804>
This commit is contained in:
parent
188c349e51
commit
18abdb8596
2 changed files with 19 additions and 12 deletions
|
|
@ -37,6 +37,18 @@
|
|||
#include "ir_hierarchical_visitor.h"
|
||||
#include "util/glheader.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
struct _mesa_glsl_parse_state;
|
||||
struct gl_shader_program;
|
||||
struct gl_builtin_uniform_desc;
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
||||
/**
|
||||
|
|
@ -2418,9 +2430,6 @@ visit_exec_list(exec_list *list, ir_visitor *visitor);
|
|||
*/
|
||||
void validate_ir_tree(exec_list *instructions);
|
||||
|
||||
struct _mesa_glsl_parse_state;
|
||||
struct gl_shader_program;
|
||||
|
||||
/**
|
||||
* Detect whether an unlinked shader contains static recursion
|
||||
*
|
||||
|
|
@ -2453,10 +2462,6 @@ detect_recursion_linked(struct gl_shader_program *prog,
|
|||
void
|
||||
clone_ir_list(void *mem_ctx, exec_list *out, const exec_list *in);
|
||||
|
||||
extern void
|
||||
_mesa_glsl_initialize_variables(exec_list *instructions,
|
||||
struct _mesa_glsl_parse_state *state);
|
||||
|
||||
extern void
|
||||
reparent_ir(exec_list *list, void *mem_ctx);
|
||||
|
||||
|
|
@ -2470,6 +2475,13 @@ mode_string(const ir_variable *var);
|
|||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
|
||||
extern void
|
||||
_mesa_glsl_initialize_types(struct _mesa_glsl_parse_state *state);
|
||||
|
||||
extern void
|
||||
_mesa_glsl_initialize_variables(struct exec_list *instructions,
|
||||
struct _mesa_glsl_parse_state *state);
|
||||
|
||||
extern void _mesa_print_ir(FILE *f, struct exec_list *instructions,
|
||||
struct _mesa_glsl_parse_state *state);
|
||||
|
||||
|
|
|
|||
|
|
@ -41,8 +41,6 @@ extern "C" {
|
|||
|
||||
typedef struct glsl_type glsl_type;
|
||||
typedef struct glsl_struct_field glsl_struct_field;
|
||||
struct _mesa_glsl_parse_state;
|
||||
struct glsl_symbol_table;
|
||||
|
||||
extern void
|
||||
glsl_type_singleton_init_or_ref(void);
|
||||
|
|
@ -50,9 +48,6 @@ glsl_type_singleton_init_or_ref(void);
|
|||
extern void
|
||||
glsl_type_singleton_decref(void);
|
||||
|
||||
extern void
|
||||
_mesa_glsl_initialize_types(struct _mesa_glsl_parse_state *state);
|
||||
|
||||
void encode_type_to_blob(struct blob *blob, const glsl_type *type);
|
||||
|
||||
const glsl_type *decode_type_from_blob(struct blob_reader *blob);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue