summaryrefslogtreecommitdiffstats
path: root/src/compiler/glsl/ir.cpp
diff options
context:
space:
mode:
authorKenneth Graunke <[email protected]>2017-01-07 13:58:42 -0800
committerKenneth Graunke <[email protected]>2017-01-07 15:15:08 -0800
commit957ec00243ec8ccc0a94f68106d079b54685fe5a (patch)
treec9663602e6c1449819a140755911e4f8c276a4ca /src/compiler/glsl/ir.cpp
parent42699e12711668a142b7acf11c168cf4301c1295 (diff)
Revert recent GLSL slot counting fiasco.
I apparently broke mark_whole_variable in ir_set_program_inouts. It was passing a type that wasn't var->type, so the wrapper didn't work out. It's all broken, revert it and start over. Fixes all kinds of things on other drivers. Revert "glsl: Make is_fixed_function_array actually check for varyings." This reverts commit 42699e12711668a142b7acf11c168cf4301c1295. Revert "glsl: Mark whole variable used for ClipDistance and TessLevel*." This reverts commit 5c580e64cc206ab160e1767c42e4d6c81f67da4d. Revert "glsl: Override the # of varying slots for ClipDistance and TessLevel*." This reverts commit 8b5749f65ac434961308ccb579fb8a816e4f29d5. Revert "glsl: Create and use a new ir_variable::count_attribute_slots() wrapper." This reverts commit 6aa5cb34d03765b7be8611aa516bc201bd337f73.
Diffstat (limited to 'src/compiler/glsl/ir.cpp')
-rw-r--r--src/compiler/glsl/ir.cpp25
1 files changed, 0 insertions, 25 deletions
diff --git a/src/compiler/glsl/ir.cpp b/src/compiler/glsl/ir.cpp
index 69f1f1a7e5d..8e4b382ebd3 100644
--- a/src/compiler/glsl/ir.cpp
+++ b/src/compiler/glsl/ir.cpp
@@ -1618,31 +1618,6 @@ ir_variable::get_extension_warning() const
? NULL : warn_extension_table[this->data.warn_extension_index];
}
-unsigned
-ir_variable::count_attribute_slots(bool is_vertex_stage) const
-{
- /* GLSL contains several built-in arrays that control fixed-function
- * hardware, and are somewhat special. Clip distances and tessellation
- * factors are exposed as float[] arrays, but typically are packed
- * tightly. We want to expose these as taking a single varying slot
- * and let drivers handle laying them out appropriately.
- *
- * Skip this override if the arrays were lowered to vectors.
- */
- if (type->without_array()->is_scalar() &&
- (data.mode == ir_var_shader_in || data.mode == ir_var_shader_out) &&
- (data.location == VARYING_SLOT_CLIP_DIST0 ||
- data.location == VARYING_SLOT_CULL_DIST0 ||
- data.location == VARYING_SLOT_TESS_LEVEL_OUTER ||
- data.location == VARYING_SLOT_TESS_LEVEL_INNER)) {
- return type->length / 4;
- }
-
- /* For normal variables, simply consult the type. */
- bool is_vs_input = is_vertex_stage && this->data.mode == ir_var_shader_in;
- return this->type->count_attribute_slots(is_vs_input);
-}
-
ir_function_signature::ir_function_signature(const glsl_type *return_type,
builtin_available_predicate b)
: ir_instruction(ir_type_function_signature),