If used properly, Firebug can be a very useful tool in helping diagnose performance issues or simply provide an in-depth insight in to a web application or site.
Below is a step-by-step guide on setting up Firebug for profiling mode.
- Firstly download and install Firebug on Firefox – I personally haven’t tested the add-on in Chrome so the profiling option may also work on there
- Click the Firebug icon so that the pane opens up at the bottom of the window
- Click the Console tab then Profile
- You should now see a screen similar to the below:
According to Firebug’s wiki page, the column names are as described:
|Function||Name of the called function (“(?)” or “anonymous” for anonymous functions)|
|Calls||Number of calls to the function|
|Percent||Percentage in time in comparison to all function calls within the profiling session|
|Own Time||Time spent within the function (time spent within functions called by that function are not taken into account)|
|Time||Summary of time spent within the function of all calls|
|Avg||Average time for one call of the function|
|Min||Minimal time spent within the function|
|Max||Minimal time spent within the function|
|File||Name of the file plus line number, in which the function is located|
I hope this small guide helps and I hope to write a similar article for memory profiling next time!