i965/nir: Move the type_size_*_bytes functions to brw_nir.h
authorJason Ekstrand <jason.ekstrand@intel.com>
Thu, 26 May 2016 00:26:42 +0000 (17:26 -0700)
committerJason Ekstrand <jason.ekstrand@intel.com>
Thu, 26 May 2016 21:13:38 +0000 (14:13 -0700)
Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
Reviewed-by: Kristian Høgsberg <krh@bitplanet.net>
src/mesa/drivers/dri/i965/brw_nir.c
src/mesa/drivers/dri/i965/brw_nir.h

index 45551a1c460f4417670214dac24d722aadf7eb17..62ed0e8e1d4df220f29c5ac6d0498d104fcbde1a 100644 (file)
@@ -337,18 +337,6 @@ brw_nir_lower_fs_outputs(nir_shader *nir)
    nir_lower_io(nir, nir_var_shader_out, type_size_scalar);
 }
 
-static int
-type_size_scalar_bytes(const struct glsl_type *type)
-{
-   return type_size_scalar(type) * 4;
-}
-
-static int
-type_size_vec4_bytes(const struct glsl_type *type)
-{
-   return type_size_vec4(type) * 16;
-}
-
 static void
 brw_nir_lower_uniforms(nir_shader *nir, bool is_scalar)
 {
index 2711606511d5173393d7d172d5606d3f24270a20..041f337667f2aa064e9a9174c6fd316fa6039a02 100644 (file)
 
 #include "brw_context.h"
 #include "brw_reg.h"
+#include "brw_shader.h"
 #include "compiler/nir/nir.h"
 
 #ifdef __cplusplus
 extern "C" {
 #endif
 
+static inline int
+type_size_scalar_bytes(const struct glsl_type *type)
+{
+   return type_size_scalar(type) * 4;
+}
+
+static inline int
+type_size_vec4_bytes(const struct glsl_type *type)
+{
+   return type_size_vec4(type) * 16;
+}
+
 /* Flags set in the instr->pass_flags field by i965 analysis passes */
 enum {
    BRW_NIR_NON_BOOLEAN           = 0x0,