nir: move glsl_types.{cpp,h} to compiler

Allows us to remove the SCons workaround :-)

Signed-off-by: Emil Velikov <emil.velikov@collabora.com>
Acked-by: Matt Turner <mattst88@gmail.com>
Acked-by: Jose Fonseca <jfonseca@vmware.com>
This commit is contained in:
Emil Velikov
2016-01-18 11:35:29 +02:00
committed by Emil Velikov
parent 1a882fd2ee
commit 24f984f64a
70 changed files with 68 additions and 76 deletions

View File

@@ -1,4 +1,6 @@
LIBCOMPILER_FILES = \
builtin_type_macros.h \
glsl_types.cpp \
glsl_types.h \
shader_enums.c \
shader_enums.h

View File

@@ -23,7 +23,7 @@
#include <stdio.h>
#include "main/macros.h"
#include "glsl_parser_extras.h"
#include "glsl/glsl_parser_extras.h"
#include "glsl_types.h"
#include "util/hash_table.h"

View File

@@ -18,8 +18,6 @@ NIR_GENERATED_FILES = \
nir/nir_opt_algebraic.c
NIR_FILES = \
nir/glsl_types.cpp \
nir/glsl_types.h \
nir/nir.c \
nir/nir.h \
nir/nir_array.h \

View File

@@ -16,7 +16,6 @@ env.Prepend(CPPPATH = [
'#src/gallium/include',
'#src/gallium/auxiliary',
'#src/glsl',
'#src/glsl/nir',
'#src/glsl/glcpp',
])
@@ -61,12 +60,6 @@ source_lists = env.ParseSourceList('Makefile.sources')
for l in ('LIBGLCPP_FILES', 'LIBGLSL_FILES'):
glsl_sources += source_lists[l]
# add nir/glsl_types.cpp manually, because SCons still doesn't know about NIR.
# XXX: Remove this once we build NIR and NIR_FILES.
glsl_sources += [
'nir/glsl_types.cpp',
]
if env['msvc']:
env.Prepend(CPPPATH = ['#/src/getopt'])
env.PrependUnique(LIBS = [getopt])

View File

@@ -22,7 +22,7 @@
*/
#include "ast.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
#include "ir.h"
void

View File

@@ -23,7 +23,7 @@
#include "glsl_symbol_table.h"
#include "ast.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
#include "ir.h"
#include "main/core.h" /* for MIN2 */
#include "main/shaderobj.h"

View File

@@ -52,7 +52,7 @@
#include "glsl_symbol_table.h"
#include "glsl_parser_extras.h"
#include "ast.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
#include "program/hash_table.h"
#include "main/shaderobj.h"
#include "ir.h"

View File

@@ -34,7 +34,7 @@
* version and set of enabled extensions.
*/
#include "glsl_types.h"
#include "compiler/glsl_types.h"
#include "glsl_parser_extras.h"
#include "util/macros.h"

View File

@@ -31,7 +31,7 @@
#include "ast.h"
#include "glsl_parser_extras.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
#include "main/context.h"
#ifdef _MSC_VER

View File

@@ -24,7 +24,7 @@
#include "ir.h"
#include "glsl_parser_extras.h"
#include "ast.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
ir_rvalue *
_mesa_ast_field_selection_to_hir(const ast_expression *expr,

View File

@@ -23,7 +23,7 @@
#include <string.h>
#include "main/core.h" /* for MAX2 */
#include "ir.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
ir_rvalue::ir_rvalue(enum ir_node_type t)
: ir_instruction(t)

View File

@@ -30,7 +30,7 @@
#include <stdlib.h>
#include "util/ralloc.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
#include "list.h"
#include "ir_visitor.h"
#include "ir_hierarchical_visitor.h"

View File

@@ -24,7 +24,7 @@
#include <string.h>
#include "main/compiler.h"
#include "ir.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
#include "program/hash_table.h"
ir_rvalue *

View File

@@ -38,7 +38,7 @@
#include "util/rounding.h" /* for _mesa_roundeven */
#include "util/half_float.h"
#include "ir.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
#include "program/hash_table.h"
static float

View File

@@ -21,7 +21,7 @@
* DEALINGS IN THE SOFTWARE.
*/
#include "glsl_types.h"
#include "compiler/glsl_types.h"
#include "ir.h"
#include "glsl_parser_extras.h"
#include "main/errors.h"

View File

@@ -22,7 +22,7 @@
*/
#include "ir_print_visitor.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
#include "glsl_parser_extras.h"
#include "main/macros.h"
#include "util/hash_table.h"

View File

@@ -23,7 +23,7 @@
#include "ir_reader.h"
#include "glsl_parser_extras.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
#include "s_expression.h"
static const bool debug = false;

View File

@@ -32,7 +32,7 @@
#include "ir.h"
#include "ir_visitor.h"
#include "ir_rvalue_visitor.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
ir_visitor_status
ir_rvalue_base_visitor::rvalue_visit(ir_expression *ir)

View File

@@ -40,7 +40,7 @@
#include "main/core.h" /* for struct gl_program */
#include "ir.h"
#include "ir_visitor.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
namespace {

View File

@@ -37,7 +37,7 @@
#include "ir_hierarchical_visitor.h"
#include "util/hash_table.h"
#include "util/set.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
namespace {

View File

@@ -32,7 +32,7 @@
#include "ir.h"
#include "ir_visitor.h"
#include "ir_variable_refcount.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
#include "util/hash_table.h"
ir_variable_refcount_visitor::ir_variable_refcount_visitor()

View File

@@ -31,7 +31,7 @@
#include "ir.h"
#include "ir_visitor.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
struct assignment_entry {
exec_node link;

View File

@@ -21,7 +21,7 @@
* DEALINGS IN THE SOFTWARE.
*/
#include "glsl_types.h"
#include "compiler/glsl_types.h"
#include "loop_analysis.h"
#include "ir_hierarchical_visitor.h"

View File

@@ -23,7 +23,7 @@
#include <limits.h>
#include "main/compiler.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
#include "loop_analysis.h"
#include "ir_hierarchical_visitor.h"

View File

@@ -21,7 +21,7 @@
* DEALINGS IN THE SOFTWARE.
*/
#include "glsl_types.h"
#include "compiler/glsl_types.h"
#include "loop_analysis.h"
#include "ir_hierarchical_visitor.h"

View File

@@ -40,7 +40,7 @@
#include "ir.h"
#include "ir_visitor.h"
#include "ir_rvalue_visitor.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
namespace {
class lower_const_array_visitor : public ir_rvalue_visitor {

View File

@@ -105,7 +105,7 @@
* Unconditional discards are treated as having a condition of "true".
*/
#include "glsl_types.h"
#include "compiler/glsl_types.h"
#include "ir.h"
namespace {

View File

@@ -44,7 +44,7 @@
* interpretation.
*/
#include "glsl_types.h"
#include "compiler/glsl_types.h"
#include "ir.h"
#include "program/hash_table.h"

View File

@@ -45,7 +45,7 @@
* to attempt to flatten any if-statements appearing at depth > N.
*/
#include "glsl_types.h"
#include "compiler/glsl_types.h"
#include "ir.h"
#include "program/hash_table.h"

View File

@@ -117,7 +117,7 @@
#include "c99_math.h"
#include "program/prog_instruction.h" /* for swizzle */
#include "glsl_types.h"
#include "compiler/glsl_types.h"
#include "ir.h"
#include "ir_builder.h"
#include "ir_optimization.h"

View File

@@ -56,7 +56,7 @@
* prevents further optimization, and thus is not currently performed.
*/
#include "glsl_types.h"
#include "compiler/glsl_types.h"
#include <string.h>
#include "ir.h"

View File

@@ -33,7 +33,7 @@
#include "ir.h"
#include "ir_expression_flattening.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
namespace {

View File

@@ -31,7 +31,7 @@
* \author Chris Forbes <chrisf@ijw.co.nz>
*/
#include "glsl_types.h"
#include "compiler/glsl_types.h"
#include "ir.h"
#include "ir_builder.h"
#include "ir_optimization.h"

View File

@@ -27,7 +27,7 @@
* lowers subroutines to an if ladder.
*/
#include "glsl_types.h"
#include "compiler/glsl_types.h"
#include "glsl_parser_extras.h"
#include "ir.h"
#include "ir_builder.h"

View File

@@ -49,7 +49,7 @@
#include "ir.h"
#include "ir_rvalue_visitor.h"
#include "ir_optimization.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
#include "main/macros.h"
/**

View File

@@ -39,7 +39,7 @@
#include "ir.h"
#include "ir_visitor.h"
#include "ir_optimization.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
namespace {

View File

@@ -32,7 +32,7 @@
#include "ir.h"
#include "ir_visitor.h"
#include "ir_optimization.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
#include "main/macros.h"
/**

View File

@@ -29,9 +29,9 @@
#include <stdio.h>
/* C wrapper around glsl_types.h */
/* C wrapper around compiler/glsl_types.h */
#include "glsl_types.h"
#include "compiler/glsl_types.h"
#ifdef __cplusplus
extern "C" {

View File

@@ -33,7 +33,7 @@
#include "ir_rvalue_visitor.h"
#include "ir_optimization.h"
#include "ir_builder.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
using namespace ir_builder;

View File

@@ -36,7 +36,7 @@
#include "ir.h"
#include "ir_visitor.h"
#include "ir_rvalue_visitor.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
static bool debug = false;

View File

@@ -33,7 +33,7 @@
* (discard <condition>)
*/
#include "glsl_types.h"
#include "compiler/glsl_types.h"
#include "ir.h"
namespace {

View File

@@ -30,7 +30,7 @@
#include "ir_visitor.h"
#include "ir_rvalue_visitor.h"
#include "ir_optimization.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
namespace {

View File

@@ -39,7 +39,7 @@
#include "ir_rvalue_visitor.h"
#include "ir_basic_block.h"
#include "ir_optimization.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
#include "util/hash_table.h"
namespace {

View File

@@ -35,7 +35,7 @@
#include "ir.h"
#include "ir_visitor.h"
#include "ir_optimization.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
#include "util/hash_table.h"
namespace {

View File

@@ -36,7 +36,7 @@
#include "ir_visitor.h"
#include "ir_basic_block.h"
#include "ir_optimization.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
namespace {

View File

@@ -45,7 +45,7 @@
#include "ir_rvalue_visitor.h"
#include "ir_basic_block.h"
#include "ir_optimization.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
static bool debug = false;

View File

@@ -51,7 +51,7 @@
#include "ir_rvalue_visitor.h"
#include "ir_optimization.h"
#include "ir_print_visitor.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
#include "link_varyings.h"
namespace {

View File

@@ -30,7 +30,7 @@
#include "ir.h"
#include "ir_visitor.h"
#include "ir_variable_refcount.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
#include "util/hash_table.h"
static bool debug = false;

View File

@@ -36,7 +36,7 @@
#include "ir.h"
#include "ir_basic_block.h"
#include "ir_optimization.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
static bool debug = false;

View File

@@ -30,7 +30,7 @@
#include "ir.h"
#include "ir_visitor.h"
#include "ir_expression_flattening.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
namespace {

View File

@@ -31,7 +31,7 @@
#include "ir_visitor.h"
#include "ir_function_inlining.h"
#include "ir_expression_flattening.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
#include "program/hash_table.h"
static void

View File

@@ -36,7 +36,7 @@
#include "ir_optimization.h"
#include "ir_builder.h"
#include "program/prog_instruction.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
#include "main/macros.h"
using namespace ir_builder;

View File

@@ -32,7 +32,7 @@
#include "ir.h"
#include "ir_visitor.h"
#include "ir_rvalue_visitor.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
namespace {

View File

@@ -35,7 +35,7 @@
#include "ir.h"
#include "ir_visitor.h"
#include "ir_rvalue_visitor.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
namespace {

View File

@@ -30,7 +30,7 @@
#include "ir.h"
#include "ir_visitor.h"
#include "ir_optimization.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
namespace {

View File

@@ -52,7 +52,7 @@
#include "ir_variable_refcount.h"
#include "ir_basic_block.h"
#include "ir_optimization.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
namespace {

View File

@@ -55,7 +55,7 @@
#include "ir.h"
#include "ir_visitor.h"
#include "ir_optimization.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
#include "program/prog_instruction.h"
namespace {

View File

@@ -16,7 +16,6 @@ env.Append(CPPPATH = [
'#/src',
'#/src/mapi',
'#/src/glsl',
'#/src/glsl/nir',
'#/src/mesa',
'#/src/gallium/include',
'#/src/gallium/auxiliary',

View File

@@ -30,7 +30,7 @@
* \author Eric Anholt <eric@anholt.net>
*/
#include "glsl/nir/glsl_types.h"
#include "compiler/glsl_types.h"
#include "glsl/ir.h"
#include "program/prog_instruction.h" /* For WRITEMASK_* */

View File

@@ -38,7 +38,7 @@
#include "brw_cfg.h"
#include "brw_program.h"
#include "brw_dead_control_flow.h"
#include "glsl/nir/glsl_types.h"
#include "compiler/glsl_types.h"
using namespace brw;

View File

@@ -43,7 +43,7 @@
#include "glsl/ir.h"
#include "glsl/ir_expression_flattening.h"
#include "glsl/nir/glsl_types.h"
#include "compiler/glsl_types.h"
class ir_channel_expressions_visitor : public ir_hierarchical_visitor {
public:

View File

@@ -40,7 +40,7 @@
#include "main/imports.h"
#include "glsl/ir.h"
#include "glsl/ir_rvalue_visitor.h"
#include "glsl/nir/glsl_types.h"
#include "compiler/glsl_types.h"
#include "util/hash_table.h"
static bool debug = false;

View File

@@ -28,7 +28,7 @@
* in the GLSL IR or in the native code.
*/
#include "brw_fs.h"
#include "glsl/nir/glsl_types.h"
#include "compiler/glsl_types.h"
using namespace brw;

View File

@@ -31,7 +31,7 @@
* \author Chris Forbes <chrisf@ijw.co.nz>
*/
#include "glsl/nir/glsl_types.h"
#include "compiler/glsl_types.h"
#include "glsl/ir.h"
#include "glsl/ir_builder.h"

View File

@@ -40,7 +40,7 @@
#include "glsl/ir_optimization.h"
#include "glsl/glsl_parser_extras.h"
#include "glsl/glsl_symbol_table.h"
#include "glsl/nir/glsl_types.h"
#include "compiler/glsl_types.h"
#include "program/ir_to_mesa.h"
#include "program/program.h"
#include "program/programopt.h"

View File

@@ -44,7 +44,7 @@
#include "main/uniforms.h"
#include "main/enums.h"
#include "ir_uniform.h"
#include "glsl_types.h"
#include "compiler/glsl_types.h"
#include "program/program.h"
/**

View File

@@ -27,7 +27,7 @@
#define UNIFORMS_H
#include "main/glheader.h"
#include "glsl/nir/glsl_types.h"
#include "compiler/glsl_types.h"
#include "glsl/ir_uniform.h"
#include "program/prog_parameter.h"

View File

@@ -42,7 +42,7 @@
#include "glsl/ir_optimization.h"
#include "glsl/ir_uniform.h"
#include "glsl/glsl_parser_extras.h"
#include "glsl/nir/glsl_types.h"
#include "compiler/glsl_types.h"
#include "glsl/linker.h"
#include "glsl/program.h"
#include "program/hash_table.h"

View File

@@ -24,7 +24,7 @@
*/
#include "main/mtypes.h"
#include "glsl/nir/glsl_types.h"
#include "compiler/glsl_types.h"
#include "glsl/ir.h"
#include "glsl/ir_uniform.h"
#include "glsl/ir_visitor.h"