summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorKenneth Graunke <[email protected]>2012-10-14 16:56:42 -0700
committerKenneth Graunke <[email protected]>2012-10-16 11:35:24 -0700
commitd0021cb0fb7c28ff9f496f02b7bb3b2ab0722304 (patch)
tree06ac2bff482e1fca69e4a9d5ed54cf5b9caa70c4 /src
parenteda4a4ae81481c4b0a300ad91e607a18a8d81cb3 (diff)
mesa: Remove remnants of PROGRAM_VARYING.
The previous patch removed the producer of things in this file. Since there aren't any, we can remove it. Reviewed-by: Brian Paul <[email protected]> Reviewed-by: Eric Anholt <[email protected]>
Diffstat (limited to 'src')
-rw-r--r--src/mesa/main/mtypes.h1
-rw-r--r--src/mesa/program/prog_parameter_layout.c2
-rw-r--r--src/mesa/program/prog_print.c5
-rw-r--r--src/mesa/program/programopt.c7
-rw-r--r--src/mesa/state_tracker/st_program.c2
5 files changed, 3 insertions, 14 deletions
diff --git a/src/mesa/main/mtypes.h b/src/mesa/main/mtypes.h
index 8bff789ac80..c3378cd99ed 100644
--- a/src/mesa/main/mtypes.h
+++ b/src/mesa/main/mtypes.h
@@ -1851,7 +1851,6 @@ typedef enum
PROGRAM_TEMPORARY, /**< machine->Temporary[] */
PROGRAM_INPUT, /**< machine->Inputs[] */
PROGRAM_OUTPUT, /**< machine->Outputs[] */
- PROGRAM_VARYING, /**< machine->Inputs[]/Outputs[] */
PROGRAM_LOCAL_PARAM, /**< gl_program->LocalParams[] */
PROGRAM_ENV_PARAM, /**< gl_program->Parameters[] */
PROGRAM_STATE_VAR, /**< gl_program->Parameters[] */
diff --git a/src/mesa/program/prog_parameter_layout.c b/src/mesa/program/prog_parameter_layout.c
index e4f2db3b379..e83469059c5 100644
--- a/src/mesa/program/prog_parameter_layout.c
+++ b/src/mesa/program/prog_parameter_layout.c
@@ -173,7 +173,7 @@ _mesa_layout_parameters(struct asm_parser_state *state)
continue;
}
- if ((inst->SrcReg[i].Base.File <= PROGRAM_VARYING )
+ if ((inst->SrcReg[i].Base.File <= PROGRAM_OUTPUT)
|| (inst->SrcReg[i].Base.File >= PROGRAM_WRITE_ONLY)) {
continue;
}
diff --git a/src/mesa/program/prog_print.c b/src/mesa/program/prog_print.c
index bb506ea87c0..5fadb82f659 100644
--- a/src/mesa/program/prog_print.c
+++ b/src/mesa/program/prog_print.c
@@ -64,8 +64,6 @@ _mesa_register_file_name(gl_register_file f)
return "CONST";
case PROGRAM_UNIFORM:
return "UNIFORM";
- case PROGRAM_VARYING:
- return "VARYING";
case PROGRAM_WRITE_ONLY:
return "WRITE_ONLY";
case PROGRAM_ADDRESS:
@@ -348,9 +346,6 @@ reg_string(gl_register_file f, GLint index, gl_prog_print_mode mode,
case PROGRAM_LOCAL_PARAM:
sprintf(str, "program.local[%s%d]", addr, index);
break;
- case PROGRAM_VARYING: /* extension */
- sprintf(str, "varying[%s%d]", addr, index);
- break;
case PROGRAM_CONSTANT: /* extension */
sprintf(str, "constant[%s%d]", addr, index);
break;
diff --git a/src/mesa/program/programopt.c b/src/mesa/program/programopt.c
index 389ea218b48..2a37021988a 100644
--- a/src/mesa/program/programopt.c
+++ b/src/mesa/program/programopt.c
@@ -499,9 +499,7 @@ _mesa_count_texture_instructions(struct gl_program *prog)
/**
* Scan/rewrite program to remove reads of custom (output) registers.
- * The passed type has to be either PROGRAM_OUTPUT or PROGRAM_VARYING
- * (for vertex shaders).
- * In GLSL shaders, varying vars can be read and written.
+ * The passed type has to be PROGRAM_OUTPUT.
* On some hardware, trying to read an output register causes trouble.
* So, rewrite the program to use a temporary register in this case.
*/
@@ -517,8 +515,7 @@ _mesa_remove_output_reads(struct gl_program *prog, gl_register_file type)
_mesa_find_used_registers(prog, PROGRAM_TEMPORARY,
usedTemps, MAX_PROGRAM_TEMPS);
- assert(type == PROGRAM_VARYING || type == PROGRAM_OUTPUT);
- assert(prog->Target == GL_VERTEX_PROGRAM_ARB || type != PROGRAM_VARYING);
+ assert(type == PROGRAM_OUTPUT);
for (i = 0; i < VERT_RESULT_MAX; i++)
outputMap[i] = -1;
diff --git a/src/mesa/state_tracker/st_program.c b/src/mesa/state_tracker/st_program.c
index ac066a766c9..a9111b523a4 100644
--- a/src/mesa/state_tracker/st_program.c
+++ b/src/mesa/state_tracker/st_program.c
@@ -309,7 +309,6 @@ st_translate_vertex_program(struct st_context *st,
if (!stvp->glsl_to_tgsi)
{
_mesa_remove_output_reads(&stvp->Base.Base, PROGRAM_OUTPUT);
- _mesa_remove_output_reads(&stvp->Base.Base, PROGRAM_VARYING);
}
ureg = ureg_create( TGSI_PROCESSOR_VERTEX );
@@ -828,7 +827,6 @@ st_translate_geometry_program(struct st_context *st,
return NULL;
_mesa_remove_output_reads(&stgp->Base.Base, PROGRAM_OUTPUT);
- _mesa_remove_output_reads(&stgp->Base.Base, PROGRAM_VARYING);
ureg = ureg_create( TGSI_PROCESSOR_GEOMETRY );
if (ureg == NULL) {