Open mousetraps opened 7 years ago
You can profile PHP applications with XDebug and a profile viewer like QCacheGrind
As far as I know XDebug does not support memory profiling. However, there is https://github.com/arnaud-lb/php-memory-profiler, which added PHP 7 support a couple of days ago.
xDebug 2.6.0 is out, and it supports memory profiling. I haven't looked at the memory profiles before, so I'm not familiar with how well it works
https://xdebug.org/docs/profiler
Since Xdebug 2.6, the profiler also collects information about how much memory is being used, and which functions and methods increased memory usage.
Right now, it's fairly obvious where the majority of our memory usage stems from (ahem PHP objects...), and we have some ideas on how to cut down on that when it comes reducing the cost of the token representation, but as we progress, it would be helpful to have something other than raw arithmetic :wink:.