Hi,<div><br></div><div>Attached patch - or alternatively, this github commit: <a href="http://github.com/aras-p/glsl-optimizer/commit/cb5b9ad7b439eddaedc54147f41727a661d11b21">http://github.com/aras-p/glsl-optimizer/commit/cb5b9ad7b439eddaedc54147f41727a661d11b21</a> - fixes GLSL2 performance problems after many shaders are processed.</div>
<div><br></div><div>When constructing builtin functions, they are put into global memory pool (once), and their prototypes cloned into current shader. However, the cloned prototype variables were still using the global memory pool, which then makes talloc_parent&#39;s O(N) complexity really visible after a while.</div>
<div><br clear="all"><br>-- <br>Aras Pranckevičius<br>work: <a href="http://unity3d.com">http://unity3d.com</a><br>home: <a href="http://aras-p.info">http://aras-p.info</a><br>
</div><div><br></div>