diff --git a/src/compiler/glsl/ast_to_hir.cpp b/src/compiler/glsl/ast_to_hir.cpp index 659adc9e95b..468b34b2e63 100644 --- a/src/compiler/glsl/ast_to_hir.cpp +++ b/src/compiler/glsl/ast_to_hir.cpp @@ -4500,8 +4500,8 @@ get_variable_being_redeclared(ir_variable **var_ptr, YYLTYPE loc, * We don't really need to do anything here, just allow the * redeclaration. Any error on the gl_FragCoord is handled on the ast * level at apply_layout_qualifier_to_variable using the - * ast_type_qualifier and _mesa_glsl_parse_state, or later at - * linker.cpp. + * ast_type_qualifier and _mesa_glsl_parse_state, or later in the + * linker. */ /* According to section 4.3.7 of the GLSL 1.30 spec, * the following built-in varaibles can be redeclared with an diff --git a/src/compiler/glsl/gl_nir_linker.c b/src/compiler/glsl/gl_nir_linker.c index 85fafea8d89..445d0b6fc21 100644 --- a/src/compiler/glsl/gl_nir_linker.c +++ b/src/compiler/glsl/gl_nir_linker.c @@ -37,8 +37,7 @@ #include "util/perf/cpu_trace.h" /** - * This file included general link methods, using NIR, instead of IR as - * the counter-part glsl/linker.cpp + * This file included general link methods, using NIR. */ void diff --git a/src/compiler/glsl/linker.cpp b/src/compiler/glsl/linker.cpp deleted file mode 100644 index 117035d48e5..00000000000 --- a/src/compiler/glsl/linker.cpp +++ /dev/null @@ -1,94 +0,0 @@ -/* - * Copyright © 2010 Intel Corporation - * - * Permission is hereby granted, free of charge, to any person obtaining a - * copy of this software and associated documentation files (the "Software"), - * to deal in the Software without restriction, including without limitation - * the rights to use, copy, modify, merge, publish, distribute, sublicense, - * and/or sell copies of the Software, and to permit persons to whom the - * Software is furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice (including the next - * paragraph) shall be included in all copies or substantial portions of the - * Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL - * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING - * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER - * DEALINGS IN THE SOFTWARE. - */ - -/** - * \file linker.cpp - * GLSL linker implementation - * - * Given a set of shaders that are to be linked to generate a final program, - * there are three distinct stages. - * - * In the first stage shaders are partitioned into groups based on the shader - * type. All shaders of a particular type (e.g., vertex shaders) are linked - * together. - * - * - Undefined references in each shader are resolve to definitions in - * another shader. - * - Types and qualifiers of uniforms, outputs, and global variables defined - * in multiple shaders with the same name are verified to be the same. - * - Initializers for uniforms and global variables defined - * in multiple shaders with the same name are verified to be the same. - * - * The result, in the terminology of the GLSL spec, is a set of shader - * executables for each processing unit. - * - * After the first stage is complete, a series of semantic checks are performed - * on each of the shader executables. - * - * - Each shader executable must define a \c main function. - * - Each vertex shader executable must write to \c gl_Position. - * - Each fragment shader executable must write to either \c gl_FragData or - * \c gl_FragColor. - * - * In the final stage individual shader executables are linked to create a - * complete exectuable. - * - * - Types of uniforms defined in multiple shader stages with the same name - * are verified to be the same. - * - Initializers for uniforms defined in multiple shader stages with the - * same name are verified to be the same. - * - Types and qualifiers of outputs defined in one stage are verified to - * be the same as the types and qualifiers of inputs defined with the same - * name in a later stage. - * - * \author Ian Romanick - */ - -#include -#include "util/strndup.h" -#include "glsl_symbol_table.h" -#include "glsl_parser_extras.h" -#include "ir.h" -#include "nir.h" -#include "program.h" -#include "program/prog_instruction.h" -#include "program/program.h" -#include "util/mesa-sha1.h" -#include "util/set.h" -#include "string_to_uint_map.h" -#include "linker_util.h" -#include "ir_optimization.h" -#include "ir_rvalue_visitor.h" -#include "builtin_functions.h" -#include "shader_cache.h" -#include "util/u_string.h" -#include "util/u_math.h" - - -#include "main/shaderobj.h" -#include "main/enums.h" -#include "main/mtypes.h" -#include "main/context.h" - - - diff --git a/src/compiler/glsl/meson.build b/src/compiler/glsl/meson.build index 4aa0964f4d7..c356fcea9f9 100644 --- a/src/compiler/glsl/meson.build +++ b/src/compiler/glsl/meson.build @@ -168,7 +168,6 @@ files_libglsl = files( 'ir_variable_refcount.cpp', 'ir_variable_refcount.h', 'ir_visitor.h', - 'linker.cpp', 'linker_util.h', 'linker_util.cpp', 'list.h', diff --git a/src/mesa/main/glspirv.c b/src/mesa/main/glspirv.c index ff1aa1258f6..dd5c89ad674 100644 --- a/src/mesa/main/glspirv.c +++ b/src/mesa/main/glspirv.c @@ -127,9 +127,6 @@ _mesa_spirv_shader_binary(struct gl_context *ctx, } /** - * This is the equivalent to compiler/glsl/linker.cpp::link_shaders() - * but for SPIR-V programs. - * * This method just creates the gl_linked_shader structs with a reference to * the SPIR-V data collected during previous steps. *