ImageEngine/gaffer — pull request #1013 by davidsminor (2014-10-02 23:03:51+00:00)
Title: Avoiding multiple cache insertions in ValuePlug::Computation::compute()

Previously, it was quite common for a given computation result to get inserted into the cache multiple times, resulting in more calls to memoryUsage() than necessary and a very significant performance penalty. I'm now skipping the insertion if the value is already in the cache, resulting in an 85% improvement in startup time for one of my test renders.

As it says in the \todo, maybe we should probably get to the bottom of why g_valueCache.cached( hash ) deadlocks my render test before we pull this