Bug 31101 - [glsl2] abort() in ir_validate::visit_enter(ir_assignment *ir)
[glsl2] abort() in ir_validate::visit_enter(ir_assignment *ir)
Product: Mesa
Classification: Unclassified
Component: Mesa core
x86 (IA32) All
: medium normal
Assigned To: Kenneth Graunke
Depends on:
  Show dependency treegraph
Reported: 2010-10-25 12:01 UTC by Fredrik Höglund
Modified: 2010-10-25 12:58 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Note You need to log in before you can comment on or make changes to this bug.
Description Fredrik Höglund 2010-10-25 12:01:05 UTC
The GLSL compiler aborts when validating the IR for this shader:

void main()
    vec2 var;
    gl_FragColor = vec4(var, vec2(1.0));

Debug output:

Assignment count of LHS write mask channels enabled not
matching RHS vector size (2 LHS, 1 RHS).
(assign (constant bool (1)) (zw) (var_ref vec_ctor@0x9ed8ad0)  (constant float (1.000000)) )
Comment 1 Kenneth Graunke 2010-10-25 12:58:02 UTC
Thanks for the report!  This should be fixed in master by the following commit:

commit ba2382f50d7815947e17fe993b39feb573638d12
Author: Kenneth Graunke <kenneth@whitecape.org>
Date:   Mon Oct 25 12:44:55 2010 -0700

    glsl: Fix constant component count in vector constructor emitting.
    Fixes freedesktop.org bug #31101 as well as piglit test cases
    assignment-type-mismatch.vert and constructor-28.vert.