I've been having some significant server-side performance issues with an ExpressionEngine / CartThrob site (pages taking 5 seconds or more to generate under no load). Today I installed XDebug and WebGrind to take a look at what was causing the performance hit.
To my surprise, the biggest offender by far (taking over 3 seconds to run only 40 times), was the function CI_Encrypt->encode, and specifically CI_Encrypt->_xor_encode (taking about 97% of that time).
Nothing else in the profiler even comes close to taking this much time, so it looks like this function is basically the sole cause of my woes. Is there any way to speed it up?