-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Profiling memory and CPU usage
Andres Riancho edited this page Apr 7, 2014
·
15 revisions
# Install meliae
sudo apt-get install cython
wget https://launchpad.net/meliae/trunk/0.4/+download/meliae-0.4.0.tar.gz
tar -zxpvf meliae-0.4.0.tar.gz
cd meliae-0.4.0.tar.gz
sudo python setup.py install
# Install yappi + RunSnakeRun
sudo pip install yappi --upgrade
sudo pip install RunSnakeRun --upgrade
Manual analysis:
W3AF_PROFILING=1 ./w3af_console -s scripts/test.w3af
Automated analysis using the collector tool.
Manual analysis:
runsnake /tmp/yappi-w3af.cpu
runsnakemem /tmp/meliae-w3af.memory
Automated analysis using the w3af-performance-analysis tool.
The profiling instrumentation is embedded into w3af
itself. It was the best way to allow me to collect this information in cases where users wanted to help me debug memory usage issues.
The source code is pretty simple to understand.