summaryrefslogtreecommitdiff
path: root/src/mesa/drivers
diff options
context:
space:
mode:
authorBrian Paul <brianp@vmware.com>2009-01-06 17:24:23 -0700
committerAlan Hourihane <alanh@vmware.com>2009-01-09 11:16:35 +0000
commit12fe642f96a2a9439f9ac8751151ae6e7fa20049 (patch)
tree76f98940d800db63cad07f972aec10cb435f25b0 /src/mesa/drivers
parentaed1bb6bc38a1925f15ad4aea707579f653d82c7 (diff)
glsl: implement loop unrolling for simple 'for' loops
Loops such as this will be unrolled: for (i = 0; i < 4; ++i) { body; } where 'body' isn't too large. This also helps to fix the issue reported in bug #19190. The problem there is indexing vector types with a variable index. For example: vec4 v; v[2] = 1.0; // equivalent to v.z = 1.0 v[i] = 2.0; // variable index into vector!! Since the for-i loop can be unrolled, we can avoid the problems associated with variable indexing into a vector (at least in this case).
Diffstat (limited to 'src/mesa/drivers')
0 files changed, 0 insertions, 0 deletions