tolerant-php-parser icon indicating copy to clipboard operation
tolerant-php-parser copied to clipboard

Memory profiling tools?

Open mousetraps opened this issue 8 years ago • 3 comments
trafficstars

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:.

mousetraps avatar Jan 17 '17 22:01 mousetraps

You can profile PHP applications with XDebug and a profile viewer like QCacheGrind

felixfbecker avatar Feb 03 '17 18:02 felixfbecker

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.

nikic avatar Feb 03 '17 19:02 nikic

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.

TysonAndre avatar Feb 12 '18 01:02 TysonAndre