remove more slang assembly-related code
authorBrian <brian@yutani.localnet.net>
Fri, 2 Feb 2007 22:17:46 +0000 (15:17 -0700)
committerBrian <brian@yutani.localnet.net>
Fri, 2 Feb 2007 22:17:46 +0000 (15:17 -0700)
src/mesa/shader/slang/slang_assemble_typeinfo.c
src/mesa/shader/slang/slang_assemble_typeinfo.h
src/mesa/shader/slang/slang_codegen.c
src/mesa/shader/slang/slang_compile.h
src/mesa/shader/slang/slang_storage.h

index 6a87ef3340b6660a5b7b4c2972d52472d33b7063..eafc452972b006ab33e8ad91cfb7dba41fed215d 100644 (file)
@@ -29,7 +29,7 @@
  */
 
 #include "imports.h"
-#include "slang_assemble.h"
+#include "slang_assemble_typeinfo.h"
 #include "slang_compile.h"
 #include "slang_error.h"
 #include "prog_instruction.h"
index 777dc21f3a70d4248c3c8eefa334b845933b3f5b..b2ca8b8633e1eb76a6610cb1a1c2e0efb129c265 100644 (file)
  * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
  */
 
-#if !defined SLANG_ASSEMBLE_TYPEINFO_H
-#define SLANG_ASSEMBLE_TYPEINFO_H
+#ifndef SLANG_ASSEMBLE_TYPEINFO_H
+#define SLANG_ASSEMBLE_TYPEINFO_H 1
 
-#if defined __cplusplus
-extern "C" {
-#endif
+#include "imports.h"
+#include "mtypes.h"
+#include "slang_utility.h"
+#include "slang_vartable.h"
+
+
+struct slang_operation_;
+
+
+/**
+ * Holds complete information about vector swizzle - the <swizzle>
+ * array contains vector component source indices, where 0 is "x", 1
+ * is "y", 2 is "z" and 3 is "w".
+ * Example: "xwz" --> { 3, { 0, 3, 2, not used } }.
+ */
+typedef struct slang_swizzle_
+{
+   GLuint num_components;
+   GLuint swizzle[4];
+} slang_swizzle;
+
+typedef struct slang_assembly_name_space_
+{
+   struct slang_function_scope_ *funcs;
+   struct slang_struct_scope_ *structs;
+   struct slang_variable_scope_ *vars;
+} slang_assembly_name_space;
+
+
+typedef struct slang_assemble_ctx_
+{
+   slang_atom_pool *atoms;
+   slang_assembly_name_space space;
+   slang_swizzle swz;
+   struct gl_program *program;
+   slang_var_table *vartable;
+
+   struct slang_function_ *CurFunction;
+   slang_atom CurLoopBreak;
+   slang_atom CurLoopCont;
+} slang_assemble_ctx;
+
+extern struct slang_function_ *
+_slang_locate_function(const struct slang_function_scope_ *funcs,
+                       slang_atom name, const struct slang_operation_ *params,
+                       GLuint num_params,
+                       const slang_assembly_name_space *space,
+                       slang_atom_pool *);
+
+
+extern GLboolean
+_slang_is_swizzle(const char *field, GLuint rows, slang_swizzle *swz);
+
+extern GLboolean
+_slang_is_swizzle_mask(const slang_swizzle *swz, GLuint rows);
+
+extern GLvoid
+_slang_multiply_swizzles(slang_swizzle *, const slang_swizzle *,
+                         const slang_swizzle *);
 
 
 /**
@@ -144,9 +200,5 @@ _slang_type_dim(slang_type_specifier_type);
 
 
 
-#ifdef __cplusplus
-}
-#endif
-
 #endif
 
index 03562018cab70a63429b132e8ca8d6b7f5bde7fe..d39cdd22a55fefb309b36827c3657db5cf7074d8 100644 (file)
@@ -30,7 +30,7 @@
 
 #include "imports.h"
 #include "macros.h"
-#include "slang_assemble.h"
+#include "slang_assemble_typeinfo.h"
 #include "slang_codegen.h"
 #include "slang_compile.h"
 #include "slang_storage.h"
index f2731cb574d5d944e2094f161964417228b7903e..0fe5443c7c4507c4733b988db4994ab09440e13a 100644 (file)
@@ -27,7 +27,7 @@
 
 #include "imports.h"
 #include "mtypes.h"
-#include "slang_assemble.h"
+#include "slang_assemble_typeinfo.h"
 #include "slang_compile_variable.h"
 #include "slang_compile_struct.h"
 #include "slang_compile_operation.h"
index b433e8bceca6a1e22cb9eaf7d0ac061cd2eadba6..642ffa38c4a199a2f33699f3d1e0d368f019fc0e 100644 (file)
@@ -26,7 +26,7 @@
 #define SLANG_STORAGE_H
 
 #include "slang_compile.h"
-#include "slang_assemble.h"
+#include "slang_assemble_typeinfo.h"
 
 #if defined __cplusplus
 extern "C" {