http://bugs.freedesktop.org/show_bug.cgi?id=27216
Summary: Assignment with a function call in an if statement causes an assertion failure Product: Mesa Version: git Platform: Other OS/Version: All Status: NEW Severity: normal Priority: medium Component: Mesa core AssignedTo: mesa3d-dev@lists.sourceforge.net ReportedBy: n...@linux.intel.com This GLSL fragment shader causes an assertion failure from Mesa: void main () { float thing; if ((thing = sqrt (5.0)) > 1.0) gl_FragColor = vec4 (1.0, 0.0, 0.0, 1.0); } The assertion is "assert(index >= 0);" in storage_to_src_reg in slang_emit.c Taking away the assignment or the function call avoids the problem. As does moving the expression to outside the if condition. -- Configure bugmail: http://bugs.freedesktop.org/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug. ------------------------------------------------------------------------------ Download Intel® Parallel Studio Eval Try the new software tools for yourself. Speed compiling, find bugs proactively, and fine-tune applications for parallel performance. See why Intel Parallel Studio got high marks during beta. http://p.sf.net/sfu/intel-sw-dev _______________________________________________ Mesa3d-dev mailing list Mesa3d-dev@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/mesa3d-dev