From: Nicolai Hähnle <nicolai.haeh...@amd.com>

This is helpful in debugging varying assignments.
---
 src/compiler/glsl/ir_print_visitor.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/compiler/glsl/ir_print_visitor.cpp 
b/src/compiler/glsl/ir_print_visitor.cpp
index ba3c1e2..86ddea6 100644
--- a/src/compiler/glsl/ir_print_visitor.cpp
+++ b/src/compiler/glsl/ir_print_visitor.cpp
@@ -167,21 +167,21 @@ void ir_print_visitor::visit(ir_variable *ir)
 
    char binding[32] = {0};
    if (ir->data.binding)
       snprintf(binding, sizeof(binding), "binding=%i ", ir->data.binding);
 
    char loc[32] = {0};
    if (ir->data.location != -1)
       snprintf(loc, sizeof(loc), "location=%i ", ir->data.location);
 
    char component[32] = {0};
-   if (ir->data.explicit_component)
+   if (ir->data.explicit_component || ir->data.location_frac != 0)
       snprintf(component, sizeof(component), "component=%i ", 
ir->data.location_frac);
 
    char stream[32] = {0};
    if (ir->data.stream & (1u << 31)) {
       if (ir->data.stream & ~(1u << 31)) {
          snprintf(stream, sizeof(stream), "stream(%u,%u,%u,%u) ",
                   ir->data.stream & 3, (ir->data.stream >> 2) & 3,
                   (ir->data.stream >> 4) & 3, (ir->data.stream >> 6) & 3);
       }
    } else if (ir->data.stream) {
-- 
2.9.3

_______________________________________________
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-dev

Reply via email to