[Mesa-dev] [PATCH 23/24] i965: Reduce cross-pollination between the DRI driver and compiler
Jason Ekstrand
jason at jlekstrand.net
Wed Mar 1 05:03:35 UTC 2017
A lot of compiler stuff was including brw_context.h as a convenient
grab-bag way of getting at a bunch of other includes. Also, a bunch of
non-compiler stuff is including compiler "internal" headers for no good
reason.
---
src/intel/blorp/blorp_priv.h | 2 +-
src/intel/tools/disasm.c | 4 ++--
src/intel/vulkan/anv_pipeline.c | 2 +-
src/intel/vulkan/anv_private.h | 2 +-
src/mesa/drivers/dri/i965/brw_clip.c | 1 -
src/mesa/drivers/dri/i965/brw_clip.h | 2 +-
src/mesa/drivers/dri/i965/brw_clip_line.c | 1 -
src/mesa/drivers/dri/i965/brw_clip_point.c | 1 -
src/mesa/drivers/dri/i965/brw_clip_tri.c | 1 -
src/mesa/drivers/dri/i965/brw_clip_unfilled.c | 1 -
src/mesa/drivers/dri/i965/brw_clip_util.c | 1 -
src/mesa/drivers/dri/i965/brw_compiler.c | 2 +-
src/mesa/drivers/dri/i965/brw_context.c | 1 -
src/mesa/drivers/dri/i965/brw_context.h | 2 +-
src/mesa/drivers/dri/i965/brw_cs.c | 4 +---
src/mesa/drivers/dri/i965/brw_defines.h | 2 ++
src/mesa/drivers/dri/i965/brw_disasm.c | 3 ++-
src/mesa/drivers/dri/i965/brw_draw.c | 1 -
src/mesa/drivers/dri/i965/brw_eu.c | 3 ++-
src/mesa/drivers/dri/i965/brw_eu_compact.c | 3 ++-
src/mesa/drivers/dri/i965/brw_eu_emit.c | 1 -
src/mesa/drivers/dri/i965/brw_eu_util.c | 1 -
src/mesa/drivers/dri/i965/brw_ff_gs.c | 2 +-
src/mesa/drivers/dri/i965/brw_ff_gs.h | 2 +-
src/mesa/drivers/dri/i965/brw_ff_gs_emit.c | 1 -
src/mesa/drivers/dri/i965/brw_fs.cpp | 2 +-
src/mesa/drivers/dri/i965/brw_fs_builder.h | 1 -
src/mesa/drivers/dri/i965/brw_fs_surface_builder.h | 1 -
src/mesa/drivers/dri/i965/brw_gs.c | 3 +--
src/mesa/drivers/dri/i965/brw_inst.h | 3 ++-
src/mesa/drivers/dri/i965/brw_interpolation_map.c | 1 -
src/mesa/drivers/dri/i965/brw_ir_vec4.h | 1 -
src/mesa/drivers/dri/i965/brw_link.cpp | 4 +---
src/mesa/drivers/dri/i965/brw_nir.c | 1 +
src/mesa/drivers/dri/i965/brw_nir_uniforms.cpp | 4 ++--
src/mesa/drivers/dri/i965/brw_program.c | 3 +--
src/mesa/drivers/dri/i965/brw_program.h | 2 +-
src/mesa/drivers/dri/i965/brw_program_cache.c | 2 +-
src/mesa/drivers/dri/i965/brw_sf.c | 1 -
src/mesa/drivers/dri/i965/brw_sf.h | 2 +-
src/mesa/drivers/dri/i965/brw_sf_emit.c | 1 -
src/mesa/drivers/dri/i965/brw_shader.cpp | 3 ++-
src/mesa/drivers/dri/i965/brw_shader.h | 3 ++-
src/mesa/drivers/dri/i965/brw_state_dump.c | 1 -
src/mesa/drivers/dri/i965/brw_state_upload.c | 1 +
src/mesa/drivers/dri/i965/brw_tcs.c | 3 +--
src/mesa/drivers/dri/i965/brw_tes.c | 3 +--
src/mesa/drivers/dri/i965/brw_vec4.cpp | 1 +
src/mesa/drivers/dri/i965/brw_vec4_builder.h | 1 -
src/mesa/drivers/dri/i965/brw_vec4_generator.cpp | 1 +
src/mesa/drivers/dri/i965/brw_vec4_gs_visitor.cpp | 1 +
src/mesa/drivers/dri/i965/brw_vec4_tcs.cpp | 1 +
src/mesa/drivers/dri/i965/brw_vec4_tes.cpp | 1 +
src/mesa/drivers/dri/i965/brw_vec4_vs_visitor.cpp | 2 +-
src/mesa/drivers/dri/i965/brw_vs.c | 2 +-
src/mesa/drivers/dri/i965/brw_vs.h | 3 +--
src/mesa/drivers/dri/i965/brw_vue_map.c | 3 ++-
src/mesa/drivers/dri/i965/brw_wm.c | 3 +--
src/mesa/drivers/dri/i965/brw_wm.h | 1 -
src/mesa/drivers/dri/i965/gen7_cs_state.c | 3 +--
src/mesa/drivers/dri/i965/intel_debug.h | 3 +++
src/mesa/drivers/dri/i965/intel_screen.c | 2 +-
62 files changed, 54 insertions(+), 66 deletions(-)
diff --git a/src/intel/blorp/blorp_priv.h b/src/intel/blorp/blorp_priv.h
index d9c03b1..c61ab08 100644
--- a/src/intel/blorp/blorp_priv.h
+++ b/src/intel/blorp/blorp_priv.h
@@ -27,7 +27,7 @@
#include <stdint.h>
#include "compiler/nir/nir.h"
-#include "brw_compiler.h"
+#include "compiler/brw_compiler.h"
#include "blorp.h"
diff --git a/src/intel/tools/disasm.c b/src/intel/tools/disasm.c
index 4ac7b90..fbc5c70 100644
--- a/src/intel/tools/disasm.c
+++ b/src/intel/tools/disasm.c
@@ -24,8 +24,8 @@
#include <stdlib.h>
#include "brw_context.h"
-#include "brw_inst.h"
-#include "brw_eu.h"
+#include "compiler/brw_inst.h"
+#include "compiler/brw_eu.h"
#include "gen_disasm.h"
diff --git a/src/intel/vulkan/anv_pipeline.c b/src/intel/vulkan/anv_pipeline.c
index 708b05a..9db27a9 100644
--- a/src/intel/vulkan/anv_pipeline.c
+++ b/src/intel/vulkan/anv_pipeline.c
@@ -30,7 +30,7 @@
#include "util/mesa-sha1.h"
#include "common/gen_l3_config.h"
#include "anv_private.h"
-#include "brw_nir.h"
+#include "compiler/brw_nir.h"
#include "anv_nir.h"
#include "spirv/nir_spirv.h"
diff --git a/src/intel/vulkan/anv_private.h b/src/intel/vulkan/anv_private.h
index 2527c2c..f148b35 100644
--- a/src/intel/vulkan/anv_private.h
+++ b/src/intel/vulkan/anv_private.h
@@ -43,7 +43,7 @@
#include "common/gen_device_info.h"
#include "blorp/blorp.h"
-#include "brw_compiler.h"
+#include "compiler/brw_compiler.h"
#include "util/macros.h"
#include "util/list.h"
#include "util/u_vector.h"
diff --git a/src/mesa/drivers/dri/i965/brw_clip.c b/src/mesa/drivers/dri/i965/brw_clip.c
index e375674..4187207 100644
--- a/src/mesa/drivers/dri/i965/brw_clip.c
+++ b/src/mesa/drivers/dri/i965/brw_clip.c
@@ -36,7 +36,6 @@
#include "brw_defines.h"
#include "brw_context.h"
-#include "brw_eu.h"
#include "brw_util.h"
#include "brw_state.h"
#include "brw_clip.h"
diff --git a/src/mesa/drivers/dri/i965/brw_clip.h b/src/mesa/drivers/dri/i965/brw_clip.h
index a8ee394..9dc1f12 100644
--- a/src/mesa/drivers/dri/i965/brw_clip.h
+++ b/src/mesa/drivers/dri/i965/brw_clip.h
@@ -34,7 +34,7 @@
#include "brw_context.h"
-#include "brw_eu.h"
+#include "compiler/brw_eu.h"
/* Initial 3 verts, plus at most 6 additional verts from intersections
* with fixed planes, plus at most 8 additional verts from intersections
diff --git a/src/mesa/drivers/dri/i965/brw_clip_line.c b/src/mesa/drivers/dri/i965/brw_clip_line.c
index f9cabd2..788dc96 100644
--- a/src/mesa/drivers/dri/i965/brw_clip_line.c
+++ b/src/mesa/drivers/dri/i965/brw_clip_line.c
@@ -37,7 +37,6 @@
#include "brw_defines.h"
#include "brw_context.h"
-#include "brw_eu.h"
#include "brw_clip.h"
diff --git a/src/mesa/drivers/dri/i965/brw_clip_point.c b/src/mesa/drivers/dri/i965/brw_clip_point.c
index 5cf2f5e..bdbf969 100644
--- a/src/mesa/drivers/dri/i965/brw_clip_point.c
+++ b/src/mesa/drivers/dri/i965/brw_clip_point.c
@@ -37,7 +37,6 @@
#include "brw_defines.h"
#include "brw_context.h"
-#include "brw_eu.h"
#include "brw_clip.h"
diff --git a/src/mesa/drivers/dri/i965/brw_clip_tri.c b/src/mesa/drivers/dri/i965/brw_clip_tri.c
index 52402e3..d98e1cc 100644
--- a/src/mesa/drivers/dri/i965/brw_clip_tri.c
+++ b/src/mesa/drivers/dri/i965/brw_clip_tri.c
@@ -37,7 +37,6 @@
#include "brw_defines.h"
#include "brw_context.h"
-#include "brw_eu.h"
#include "brw_clip.h"
static void release_tmps( struct brw_clip_compile *c )
diff --git a/src/mesa/drivers/dri/i965/brw_clip_unfilled.c b/src/mesa/drivers/dri/i965/brw_clip_unfilled.c
index 7c06857..65ccf33 100644
--- a/src/mesa/drivers/dri/i965/brw_clip_unfilled.c
+++ b/src/mesa/drivers/dri/i965/brw_clip_unfilled.c
@@ -37,7 +37,6 @@
#include "brw_defines.h"
#include "brw_context.h"
-#include "brw_eu.h"
#include "brw_clip.h"
diff --git a/src/mesa/drivers/dri/i965/brw_clip_util.c b/src/mesa/drivers/dri/i965/brw_clip_util.c
index 4f1b0fd..e0fdd3d 100644
--- a/src/mesa/drivers/dri/i965/brw_clip_util.c
+++ b/src/mesa/drivers/dri/i965/brw_clip_util.c
@@ -38,7 +38,6 @@
#include "brw_defines.h"
#include "brw_context.h"
-#include "brw_eu.h"
#include "brw_clip.h"
diff --git a/src/mesa/drivers/dri/i965/brw_compiler.c b/src/mesa/drivers/dri/i965/brw_compiler.c
index 18ca444..f414099 100644
--- a/src/mesa/drivers/dri/i965/brw_compiler.c
+++ b/src/mesa/drivers/dri/i965/brw_compiler.c
@@ -22,8 +22,8 @@
*/
#include "brw_compiler.h"
-#include "brw_context.h"
#include "brw_shader.h"
+#include "intel_debug.h"
#include "compiler/nir/nir.h"
#include "main/errors.h"
#include "util/debug.h"
diff --git a/src/mesa/drivers/dri/i965/brw_context.c b/src/mesa/drivers/dri/i965/brw_context.c
index fb97743..3688ba4 100644
--- a/src/mesa/drivers/dri/i965/brw_context.c
+++ b/src/mesa/drivers/dri/i965/brw_context.c
@@ -53,7 +53,6 @@
#include "brw_context.h"
#include "brw_defines.h"
#include "brw_blorp.h"
-#include "brw_compiler.h"
#include "brw_draw.h"
#include "brw_state.h"
diff --git a/src/mesa/drivers/dri/i965/brw_context.h b/src/mesa/drivers/dri/i965/brw_context.h
index 288ef3a..9ff88b2 100644
--- a/src/mesa/drivers/dri/i965/brw_context.h
+++ b/src/mesa/drivers/dri/i965/brw_context.h
@@ -37,7 +37,7 @@
#include "main/macros.h"
#include "main/mtypes.h"
#include "brw_structs.h"
-#include "brw_compiler.h"
+#include "compiler/brw_compiler.h"
#include "intel_aub.h"
#include "isl/isl.h"
diff --git a/src/mesa/drivers/dri/i965/brw_cs.c b/src/mesa/drivers/dri/i965/brw_cs.c
index 16b7945..eaa7381 100644
--- a/src/mesa/drivers/dri/i965/brw_cs.c
+++ b/src/mesa/drivers/dri/i965/brw_cs.c
@@ -24,13 +24,11 @@
#include "util/ralloc.h"
#include "brw_context.h"
#include "brw_cs.h"
-#include "brw_eu.h"
#include "brw_wm.h"
-#include "brw_shader.h"
#include "intel_mipmap_tree.h"
#include "brw_state.h"
#include "intel_batchbuffer.h"
-#include "brw_nir.h"
+#include "compiler/brw_nir.h"
#include "brw_program.h"
#include "compiler/glsl/ir_uniform.h"
diff --git a/src/mesa/drivers/dri/i965/brw_defines.h b/src/mesa/drivers/dri/i965/brw_defines.h
index f443cac..b08c40c 100644
--- a/src/mesa/drivers/dri/i965/brw_defines.h
+++ b/src/mesa/drivers/dri/i965/brw_defines.h
@@ -29,6 +29,8 @@
* Keith Whitwell <keithw at vmware.com>
*/
+#include "util/macros.h"
+
#define INTEL_MASK(high, low) (((1u<<((high)-(low)+1))-1)<<(low))
/* Using the GNU statement expression extension */
#define SET_FIELD(value, field) \
diff --git a/src/mesa/drivers/dri/i965/brw_disasm.c b/src/mesa/drivers/dri/i965/brw_disasm.c
index cd553b3..6afbb24 100644
--- a/src/mesa/drivers/dri/i965/brw_disasm.c
+++ b/src/mesa/drivers/dri/i965/brw_disasm.c
@@ -24,8 +24,9 @@
#include <string.h>
#include <stdarg.h>
-#include "brw_context.h"
#include "brw_defines.h"
+#include "brw_inst.h"
+#include "brw_shader.h"
#include "brw_reg.h"
#include "brw_inst.h"
#include "brw_eu.h"
diff --git a/src/mesa/drivers/dri/i965/brw_draw.c b/src/mesa/drivers/dri/i965/brw_draw.c
index 940ce70..e3aaeb8 100644
--- a/src/mesa/drivers/dri/i965/brw_draw.c
+++ b/src/mesa/drivers/dri/i965/brw_draw.c
@@ -45,7 +45,6 @@
#include "brw_defines.h"
#include "brw_context.h"
#include "brw_state.h"
-#include "brw_vs.h"
#include "intel_batchbuffer.h"
#include "intel_buffers.h"
diff --git a/src/mesa/drivers/dri/i965/brw_eu.c b/src/mesa/drivers/dri/i965/brw_eu.c
index 6a422bb..e4cbf53 100644
--- a/src/mesa/drivers/dri/i965/brw_eu.c
+++ b/src/mesa/drivers/dri/i965/brw_eu.c
@@ -30,9 +30,10 @@
*/
-#include "brw_context.h"
#include "brw_defines.h"
#include "brw_eu.h"
+#include "brw_shader.h"
+#include "intel_debug.h"
#include "util/ralloc.h"
diff --git a/src/mesa/drivers/dri/i965/brw_eu_compact.c b/src/mesa/drivers/dri/i965/brw_eu_compact.c
index 68321e7..778fb6a 100644
--- a/src/mesa/drivers/dri/i965/brw_eu_compact.c
+++ b/src/mesa/drivers/dri/i965/brw_eu_compact.c
@@ -72,9 +72,10 @@
* Gen 8 adds support for compacting 3-src instructions.
*/
-#include "brw_context.h"
#include "brw_eu.h"
+#include "brw_shader.h"
#include "intel_asm_annotation.h"
+#include "intel_debug.h"
#include "util/u_atomic.h" /* for p_atomic_cmpxchg */
static const uint32_t g45_control_index_table[32] = {
diff --git a/src/mesa/drivers/dri/i965/brw_eu_emit.c b/src/mesa/drivers/dri/i965/brw_eu_emit.c
index f4bec33..be4f46f 100644
--- a/src/mesa/drivers/dri/i965/brw_eu_emit.c
+++ b/src/mesa/drivers/dri/i965/brw_eu_emit.c
@@ -30,7 +30,6 @@
*/
-#include "brw_context.h"
#include "brw_defines.h"
#include "brw_eu.h"
diff --git a/src/mesa/drivers/dri/i965/brw_eu_util.c b/src/mesa/drivers/dri/i965/brw_eu_util.c
index f74e3fe..4de0db4 100644
--- a/src/mesa/drivers/dri/i965/brw_eu_util.c
+++ b/src/mesa/drivers/dri/i965/brw_eu_util.c
@@ -30,7 +30,6 @@
*/
-#include "brw_context.h"
#include "brw_defines.h"
#include "brw_eu.h"
diff --git a/src/mesa/drivers/dri/i965/brw_ff_gs.c b/src/mesa/drivers/dri/i965/brw_ff_gs.c
index 0316d0f..46385f4 100644
--- a/src/mesa/drivers/dri/i965/brw_ff_gs.c
+++ b/src/mesa/drivers/dri/i965/brw_ff_gs.c
@@ -37,7 +37,7 @@
#include "brw_defines.h"
#include "brw_context.h"
-#include "brw_eu.h"
+#include "compiler/brw_eu.h"
#include "brw_util.h"
#include "brw_state.h"
#include "brw_ff_gs.h"
diff --git a/src/mesa/drivers/dri/i965/brw_ff_gs.h b/src/mesa/drivers/dri/i965/brw_ff_gs.h
index e952b64..bac2730 100644
--- a/src/mesa/drivers/dri/i965/brw_ff_gs.h
+++ b/src/mesa/drivers/dri/i965/brw_ff_gs.h
@@ -35,7 +35,7 @@
#include "brw_context.h"
-#include "brw_eu.h"
+#include "compiler/brw_eu.h"
#define MAX_GS_VERTS (4)
diff --git a/src/mesa/drivers/dri/i965/brw_ff_gs_emit.c b/src/mesa/drivers/dri/i965/brw_ff_gs_emit.c
index 7a3e62a..6941268 100644
--- a/src/mesa/drivers/dri/i965/brw_ff_gs_emit.c
+++ b/src/mesa/drivers/dri/i965/brw_ff_gs_emit.c
@@ -38,7 +38,6 @@
#include "brw_defines.h"
#include "brw_context.h"
-#include "brw_eu.h"
#include "brw_ff_gs.h"
/**
diff --git a/src/mesa/drivers/dri/i965/brw_fs.cpp b/src/mesa/drivers/dri/i965/brw_fs.cpp
index e87a2fd..903b834 100644
--- a/src/mesa/drivers/dri/i965/brw_fs.cpp
+++ b/src/mesa/drivers/dri/i965/brw_fs.cpp
@@ -29,7 +29,6 @@
*/
#include "main/macros.h"
-#include "brw_context.h"
#include "brw_eu.h"
#include "brw_fs.h"
#include "brw_cs.h"
@@ -38,6 +37,7 @@
#include "brw_cfg.h"
#include "brw_program.h"
#include "brw_dead_control_flow.h"
+#include "intel_debug.h"
#include "compiler/glsl_types.h"
#include "compiler/nir/nir_builder.h"
#include "program/prog_parameter.h"
diff --git a/src/mesa/drivers/dri/i965/brw_fs_builder.h b/src/mesa/drivers/dri/i965/brw_fs_builder.h
index e8cbb9c..87394bc 100644
--- a/src/mesa/drivers/dri/i965/brw_fs_builder.h
+++ b/src/mesa/drivers/dri/i965/brw_fs_builder.h
@@ -27,7 +27,6 @@
#include "brw_ir_fs.h"
#include "brw_shader.h"
-#include "brw_context.h"
namespace brw {
/**
diff --git a/src/mesa/drivers/dri/i965/brw_fs_surface_builder.h b/src/mesa/drivers/dri/i965/brw_fs_surface_builder.h
index 17318ce..32b56d3 100644
--- a/src/mesa/drivers/dri/i965/brw_fs_surface_builder.h
+++ b/src/mesa/drivers/dri/i965/brw_fs_surface_builder.h
@@ -26,7 +26,6 @@
#define BRW_FS_SURFACE_BUILDER_H
#include "brw_fs_builder.h"
-#include "brw_context.h"
namespace brw {
namespace surface_access {
diff --git a/src/mesa/drivers/dri/i965/brw_gs.c b/src/mesa/drivers/dri/i965/brw_gs.c
index 2996203..b8434a8 100644
--- a/src/mesa/drivers/dri/i965/brw_gs.c
+++ b/src/mesa/drivers/dri/i965/brw_gs.c
@@ -29,10 +29,9 @@
#include "brw_gs.h"
#include "brw_context.h"
-#include "brw_vec4_gs_visitor.h"
#include "brw_state.h"
#include "brw_ff_gs.h"
-#include "brw_nir.h"
+#include "compiler/brw_nir.h"
#include "brw_program.h"
#include "compiler/glsl/ir_uniform.h"
diff --git a/src/mesa/drivers/dri/i965/brw_inst.h b/src/mesa/drivers/dri/i965/brw_inst.h
index d6a2105..e73093e 100644
--- a/src/mesa/drivers/dri/i965/brw_inst.h
+++ b/src/mesa/drivers/dri/i965/brw_inst.h
@@ -33,7 +33,8 @@
#include <stdint.h>
-#include "brw_context.h"
+#include "brw_defines.h"
+#include "common/gen_device_info.h"
#ifdef __cplusplus
extern "C" {
diff --git a/src/mesa/drivers/dri/i965/brw_interpolation_map.c b/src/mesa/drivers/dri/i965/brw_interpolation_map.c
index 8d53e52..7b9f58e 100644
--- a/src/mesa/drivers/dri/i965/brw_interpolation_map.c
+++ b/src/mesa/drivers/dri/i965/brw_interpolation_map.c
@@ -22,7 +22,6 @@
*/
#include "brw_compiler.h"
-#include "brw_context.h"
#include "compiler/nir/nir.h"
static char const *get_qual_name(int mode)
diff --git a/src/mesa/drivers/dri/i965/brw_ir_vec4.h b/src/mesa/drivers/dri/i965/brw_ir_vec4.h
index 57fc6be..bd026eb 100644
--- a/src/mesa/drivers/dri/i965/brw_ir_vec4.h
+++ b/src/mesa/drivers/dri/i965/brw_ir_vec4.h
@@ -26,7 +26,6 @@
#define BRW_IR_VEC4_H
#include "brw_shader.h"
-#include "brw_context.h"
namespace brw {
diff --git a/src/mesa/drivers/dri/i965/brw_link.cpp b/src/mesa/drivers/dri/i965/brw_link.cpp
index 977feb3..f639072 100644
--- a/src/mesa/drivers/dri/i965/brw_link.cpp
+++ b/src/mesa/drivers/dri/i965/brw_link.cpp
@@ -22,9 +22,7 @@
*/
#include "brw_context.h"
-#include "brw_shader.h"
-#include "brw_fs.h"
-#include "brw_nir.h"
+#include "compiler/brw_nir.h"
#include "brw_program.h"
#include "compiler/glsl/ir.h"
#include "compiler/glsl/ir_optimization.h"
diff --git a/src/mesa/drivers/dri/i965/brw_nir.c b/src/mesa/drivers/dri/i965/brw_nir.c
index 7470349..15e290a 100644
--- a/src/mesa/drivers/dri/i965/brw_nir.c
+++ b/src/mesa/drivers/dri/i965/brw_nir.c
@@ -23,6 +23,7 @@
#include "brw_nir.h"
#include "brw_shader.h"
+#include "intel_debug.h"
#include "compiler/glsl_types.h"
#include "compiler/nir/nir_builder.h"
diff --git a/src/mesa/drivers/dri/i965/brw_nir_uniforms.cpp b/src/mesa/drivers/dri/i965/brw_nir_uniforms.cpp
index 9ebd7d8..24485f0 100644
--- a/src/mesa/drivers/dri/i965/brw_nir_uniforms.cpp
+++ b/src/mesa/drivers/dri/i965/brw_nir_uniforms.cpp
@@ -21,8 +21,8 @@
* IN THE SOFTWARE.
*/
-#include "brw_shader.h"
-#include "brw_nir.h"
+#include "compiler/brw_nir.h"
+#include "compiler/brw_shader.h"
#include "compiler/glsl/ir_uniform.h"
static void
diff --git a/src/mesa/drivers/dri/i965/brw_program.c b/src/mesa/drivers/dri/i965/brw_program.c
index ceb79a5..71d3942 100644
--- a/src/mesa/drivers/dri/i965/brw_program.c
+++ b/src/mesa/drivers/dri/i965/brw_program.c
@@ -43,8 +43,7 @@
#include "brw_program.h"
#include "brw_context.h"
-#include "brw_shader.h"
-#include "brw_nir.h"
+#include "compiler/brw_nir.h"
#include "intel_batchbuffer.h"
static void
diff --git a/src/mesa/drivers/dri/i965/brw_program.h b/src/mesa/drivers/dri/i965/brw_program.h
index 46831a8..4529a71 100644
--- a/src/mesa/drivers/dri/i965/brw_program.h
+++ b/src/mesa/drivers/dri/i965/brw_program.h
@@ -24,7 +24,7 @@
#ifndef BRW_PROGRAM_H
#define BRW_PROGRAM_H
-#include "brw_compiler.h"
+#include "compiler/brw_compiler.h"
#ifdef __cplusplus
extern "C" {
diff --git a/src/mesa/drivers/dri/i965/brw_program_cache.c b/src/mesa/drivers/dri/i965/brw_program_cache.c
index a9a4c92..6bf26f3 100644
--- a/src/mesa/drivers/dri/i965/brw_program_cache.c
+++ b/src/mesa/drivers/dri/i965/brw_program_cache.c
@@ -47,11 +47,11 @@
#include "main/imports.h"
#include "intel_batchbuffer.h"
#include "brw_state.h"
-#include "brw_vs.h"
#include "brw_wm.h"
#include "brw_gs.h"
#include "brw_cs.h"
#include "brw_program.h"
+#include "compiler/brw_eu.h"
#define FILE_DEBUG_FLAG DEBUG_STATE
diff --git a/src/mesa/drivers/dri/i965/brw_sf.c b/src/mesa/drivers/dri/i965/brw_sf.c
index 468050a..ff15c97 100644
--- a/src/mesa/drivers/dri/i965/brw_sf.c
+++ b/src/mesa/drivers/dri/i965/brw_sf.c
@@ -39,7 +39,6 @@
#include "brw_defines.h"
#include "brw_context.h"
-#include "brw_eu.h"
#include "brw_util.h"
#include "brw_sf.h"
#include "brw_state.h"
diff --git a/src/mesa/drivers/dri/i965/brw_sf.h b/src/mesa/drivers/dri/i965/brw_sf.h
index c6840dd..f372656 100644
--- a/src/mesa/drivers/dri/i965/brw_sf.h
+++ b/src/mesa/drivers/dri/i965/brw_sf.h
@@ -36,7 +36,7 @@
#include "program/program.h"
#include "brw_context.h"
-#include "brw_eu.h"
+#include "compiler/brw_eu.h"
#define SF_POINTS 0
diff --git a/src/mesa/drivers/dri/i965/brw_sf_emit.c b/src/mesa/drivers/dri/i965/brw_sf_emit.c
index 5f31fa5..dc90503 100644
--- a/src/mesa/drivers/dri/i965/brw_sf_emit.c
+++ b/src/mesa/drivers/dri/i965/brw_sf_emit.c
@@ -37,7 +37,6 @@
#include "brw_defines.h"
#include "brw_context.h"
-#include "brw_eu.h"
#include "brw_util.h"
#include "brw_sf.h"
diff --git a/src/mesa/drivers/dri/i965/brw_shader.cpp b/src/mesa/drivers/dri/i965/brw_shader.cpp
index 28ed8dc..ec54b8f 100644
--- a/src/mesa/drivers/dri/i965/brw_shader.cpp
+++ b/src/mesa/drivers/dri/i965/brw_shader.cpp
@@ -21,13 +21,14 @@
* IN THE SOFTWARE.
*/
-#include "brw_context.h"
#include "brw_cfg.h"
#include "brw_eu.h"
#include "brw_fs.h"
#include "brw_nir.h"
#include "brw_vec4_tes.h"
+#include "intel_debug.h"
#include "main/uniforms.h"
+#include "util/macros.h"
enum brw_reg_type
brw_type_for_base_type(const struct glsl_type *type)
diff --git a/src/mesa/drivers/dri/i965/brw_shader.h b/src/mesa/drivers/dri/i965/brw_shader.h
index 1c3814d..b4c9cdb 100644
--- a/src/mesa/drivers/dri/i965/brw_shader.h
+++ b/src/mesa/drivers/dri/i965/brw_shader.h
@@ -25,8 +25,9 @@
#include <stdint.h>
#include "brw_reg.h"
+#include "brw_compiler.h"
#include "brw_defines.h"
-#include "brw_context.h"
+#include "brw_inst.h"
#include "compiler/nir/nir.h"
#ifdef __cplusplus
diff --git a/src/mesa/drivers/dri/i965/brw_state_dump.c b/src/mesa/drivers/dri/i965/brw_state_dump.c
index 13e76ec..bc9b9a3 100644
--- a/src/mesa/drivers/dri/i965/brw_state_dump.c
+++ b/src/mesa/drivers/dri/i965/brw_state_dump.c
@@ -32,7 +32,6 @@
#include "brw_context.h"
#include "brw_defines.h"
-#include "brw_eu.h"
#include "brw_state.h"
static const char *sampler_mip_filter[] = {
diff --git a/src/mesa/drivers/dri/i965/brw_state_upload.c b/src/mesa/drivers/dri/i965/brw_state_upload.c
index 52b74a7..b3bd0ce 100644
--- a/src/mesa/drivers/dri/i965/brw_state_upload.c
+++ b/src/mesa/drivers/dri/i965/brw_state_upload.c
@@ -33,6 +33,7 @@
#include "brw_context.h"
#include "brw_state.h"
+#include "brw_program.h"
#include "drivers/common/meta.h"
#include "intel_batchbuffer.h"
#include "intel_buffers.h"
diff --git a/src/mesa/drivers/dri/i965/brw_tcs.c b/src/mesa/drivers/dri/i965/brw_tcs.c
index 64bfc40..5acb77c 100644
--- a/src/mesa/drivers/dri/i965/brw_tcs.c
+++ b/src/mesa/drivers/dri/i965/brw_tcs.c
@@ -28,9 +28,8 @@
*/
#include "brw_context.h"
-#include "brw_nir.h"
+#include "compiler/brw_nir.h"
#include "brw_program.h"
-#include "brw_shader.h"
#include "brw_state.h"
#include "program/prog_parameter.h"
#include "nir_builder.h"
diff --git a/src/mesa/drivers/dri/i965/brw_tes.c b/src/mesa/drivers/dri/i965/brw_tes.c
index 3da5357..8309315 100644
--- a/src/mesa/drivers/dri/i965/brw_tes.c
+++ b/src/mesa/drivers/dri/i965/brw_tes.c
@@ -28,9 +28,8 @@
*/
#include "brw_context.h"
-#include "brw_nir.h"
+#include "compiler/brw_nir.h"
#include "brw_program.h"
-#include "brw_shader.h"
#include "brw_state.h"
#include "program/prog_parameter.h"
diff --git a/src/mesa/drivers/dri/i965/brw_vec4.cpp b/src/mesa/drivers/dri/i965/brw_vec4.cpp
index bd69f01..fae01ed 100644
--- a/src/mesa/drivers/dri/i965/brw_vec4.cpp
+++ b/src/mesa/drivers/dri/i965/brw_vec4.cpp
@@ -29,6 +29,7 @@
#include "brw_vec4_builder.h"
#include "brw_vec4_live_variables.h"
#include "brw_dead_control_flow.h"
+#include "intel_debug.h"
#include "program/prog_parameter.h"
#define MAX_INSTRUCTION (1 << 30)
diff --git a/src/mesa/drivers/dri/i965/brw_vec4_builder.h b/src/mesa/drivers/dri/i965/brw_vec4_builder.h
index 8352542..4c3efe8 100644
--- a/src/mesa/drivers/dri/i965/brw_vec4_builder.h
+++ b/src/mesa/drivers/dri/i965/brw_vec4_builder.h
@@ -27,7 +27,6 @@
#include "brw_ir_vec4.h"
#include "brw_ir_allocator.h"
-#include "brw_context.h"
namespace brw {
/**
diff --git a/src/mesa/drivers/dri/i965/brw_vec4_generator.cpp b/src/mesa/drivers/dri/i965/brw_vec4_generator.cpp
index b2ebdb3..83f5711 100644
--- a/src/mesa/drivers/dri/i965/brw_vec4_generator.cpp
+++ b/src/mesa/drivers/dri/i965/brw_vec4_generator.cpp
@@ -24,6 +24,7 @@
#include "brw_cfg.h"
#include "brw_eu.h"
#include "brw_program.h"
+#include "intel_debug.h"
using namespace brw;
diff --git a/src/mesa/drivers/dri/i965/brw_vec4_gs_visitor.cpp b/src/mesa/drivers/dri/i965/brw_vec4_gs_visitor.cpp
index 0220068..3a8bc77 100644
--- a/src/mesa/drivers/dri/i965/brw_vec4_gs_visitor.cpp
+++ b/src/mesa/drivers/dri/i965/brw_vec4_gs_visitor.cpp
@@ -31,6 +31,7 @@
#include "gen6_gs_visitor.h"
#include "brw_fs.h"
#include "brw_nir.h"
+#include "intel_debug.h"
namespace brw {
diff --git a/src/mesa/drivers/dri/i965/brw_vec4_tcs.cpp b/src/mesa/drivers/dri/i965/brw_vec4_tcs.cpp
index 3ea9010..d27074c 100644
--- a/src/mesa/drivers/dri/i965/brw_vec4_tcs.cpp
+++ b/src/mesa/drivers/dri/i965/brw_vec4_tcs.cpp
@@ -30,6 +30,7 @@
#include "brw_nir.h"
#include "brw_vec4_tcs.h"
#include "brw_fs.h"
+#include "intel_debug.h"
namespace brw {
diff --git a/src/mesa/drivers/dri/i965/brw_vec4_tes.cpp b/src/mesa/drivers/dri/i965/brw_vec4_tes.cpp
index ae6d99b..0c05ab0 100644
--- a/src/mesa/drivers/dri/i965/brw_vec4_tes.cpp
+++ b/src/mesa/drivers/dri/i965/brw_vec4_tes.cpp
@@ -29,6 +29,7 @@
#include "brw_vec4_tes.h"
#include "brw_cfg.h"
+#include "intel_debug.h"
namespace brw {
diff --git a/src/mesa/drivers/dri/i965/brw_vec4_vs_visitor.cpp b/src/mesa/drivers/dri/i965/brw_vec4_vs_visitor.cpp
index 026f53d..4d943d4 100644
--- a/src/mesa/drivers/dri/i965/brw_vec4_vs_visitor.cpp
+++ b/src/mesa/drivers/dri/i965/brw_vec4_vs_visitor.cpp
@@ -23,7 +23,7 @@
#include "brw_vec4_vs_visitor.h"
-
+#include "intel_debug.h"
namespace brw {
diff --git a/src/mesa/drivers/dri/i965/brw_vs.c b/src/mesa/drivers/dri/i965/brw_vs.c
index 3f11a76..d45e340 100644
--- a/src/mesa/drivers/dri/i965/brw_vs.c
+++ b/src/mesa/drivers/dri/i965/brw_vs.c
@@ -38,7 +38,7 @@
#include "brw_state.h"
#include "program/prog_print.h"
#include "program/prog_parameter.h"
-#include "brw_nir.h"
+#include "compiler/brw_nir.h"
#include "brw_program.h"
#include "util/ralloc.h"
diff --git a/src/mesa/drivers/dri/i965/brw_vs.h b/src/mesa/drivers/dri/i965/brw_vs.h
index 98b0bf1..6e052d7 100644
--- a/src/mesa/drivers/dri/i965/brw_vs.h
+++ b/src/mesa/drivers/dri/i965/brw_vs.h
@@ -33,8 +33,7 @@
#ifndef BRW_VS_H
#define BRW_VS_H
-
-#include "brw_vec4.h"
+#include "brw_context.h"
#ifdef __cplusplus
extern "C" {
diff --git a/src/mesa/drivers/dri/i965/brw_vue_map.c b/src/mesa/drivers/dri/i965/brw_vue_map.c
index 178a4e5..8912068 100644
--- a/src/mesa/drivers/dri/i965/brw_vue_map.c
+++ b/src/mesa/drivers/dri/i965/brw_vue_map.c
@@ -40,7 +40,8 @@
*/
-#include "brw_context.h"
+#include "brw_compiler.h"
+#include "intel_debug.h"
static inline void
assign_vue_slot(struct brw_vue_map *vue_map, int varying, int slot)
diff --git a/src/mesa/drivers/dri/i965/brw_wm.c b/src/mesa/drivers/dri/i965/brw_wm.c
index dd3e201..3342e71 100644
--- a/src/mesa/drivers/dri/i965/brw_wm.c
+++ b/src/mesa/drivers/dri/i965/brw_wm.c
@@ -26,7 +26,6 @@
#include "brw_context.h"
#include "brw_wm.h"
#include "brw_state.h"
-#include "brw_shader.h"
#include "main/enums.h"
#include "main/formats.h"
#include "main/fbobject.h"
@@ -36,7 +35,7 @@
#include "program/program.h"
#include "intel_mipmap_tree.h"
#include "intel_image.h"
-#include "brw_nir.h"
+#include "compiler/brw_nir.h"
#include "brw_program.h"
#include "util/ralloc.h"
diff --git a/src/mesa/drivers/dri/i965/brw_wm.h b/src/mesa/drivers/dri/i965/brw_wm.h
index d1bf868..613172a 100644
--- a/src/mesa/drivers/dri/i965/brw_wm.h
+++ b/src/mesa/drivers/dri/i965/brw_wm.h
@@ -36,7 +36,6 @@
#include <stdbool.h>
#include "brw_context.h"
-#include "brw_eu.h"
#ifdef __cplusplus
extern "C" {
diff --git a/src/mesa/drivers/dri/i965/gen7_cs_state.c b/src/mesa/drivers/dri/i965/gen7_cs_state.c
index bae4fd2..dc3cc66 100644
--- a/src/mesa/drivers/dri/i965/gen7_cs_state.c
+++ b/src/mesa/drivers/dri/i965/gen7_cs_state.c
@@ -23,10 +23,9 @@
#include "util/ralloc.h"
#include "brw_context.h"
+#include "brw_defines.h"
#include "brw_cs.h"
-#include "brw_eu.h"
#include "brw_wm.h"
-#include "brw_shader.h"
#include "intel_mipmap_tree.h"
#include "intel_batchbuffer.h"
#include "brw_state.h"
diff --git a/src/mesa/drivers/dri/i965/intel_debug.h b/src/mesa/drivers/dri/i965/intel_debug.h
index e8e329b..8c81c1d 100644
--- a/src/mesa/drivers/dri/i965/intel_debug.h
+++ b/src/mesa/drivers/dri/i965/intel_debug.h
@@ -24,6 +24,9 @@
*/
#pragma once
+#include <stdint.h>
+#include "compiler/shader_enums.h"
+
#ifdef __cplusplus
extern "C" {
#endif
diff --git a/src/mesa/drivers/dri/i965/intel_screen.c b/src/mesa/drivers/dri/i965/intel_screen.c
index d6a88a1..f98431f 100644
--- a/src/mesa/drivers/dri/i965/intel_screen.c
+++ b/src/mesa/drivers/dri/i965/intel_screen.c
@@ -35,7 +35,7 @@
#include "main/version.h"
#include "swrast/s_renderbuffer.h"
#include "util/ralloc.h"
-#include "brw_shader.h"
+#include "brw_defines.h"
#include "compiler/nir/nir.h"
#include "utils.h"
--
2.5.0.400.gff86faf
More information about the mesa-dev
mailing list