https://github.com/clickermonkey/theprof
A simple Java Profiler that outputs the performance of your application into CSV files.
https://github.com/clickermonkey/theprof
Last synced: 7 months ago
JSON representation
A simple Java Profiler that outputs the performance of your application into CSV files.
- Host: GitHub
- URL: https://github.com/clickermonkey/theprof
- Owner: ClickerMonkey
- License: osl-3.0
- Created: 2013-07-29T12:37:08.000Z (over 12 years ago)
- Default Branch: master
- Last Pushed: 2013-08-03T05:15:10.000Z (over 12 years ago)
- Last Synced: 2025-01-27T10:23:12.141Z (about 1 year ago)
- Language: Java
- Homepage:
- Size: 699 KB
- Stars: 1
- Watchers: 3
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
README
TheProf
=======

A simple Java Profiler that outputs the performance of your application into CSV files.
### Download
* [Latest Version](http://gh.magnos.org/?r=https://github.com/ClickerMonkey/TheProf/raw/master/build/theprof.jar)
### How does it work?
In a configuration file, you specify the classes/packages/methods to include/exclude from profiling. When a class is first loaded
and the class is marked as profilable, byte code will be injected in the methods of the class.
### What does it measure per method?
1. Number of invocations
2. The total execution time of the method (via average, variance, min, max, and importance)
3. The method execution time - this is the total time in the method MINUS the time of any method calls made that are also being profiled. This helps figure out whether a method is slow or whether it's fine, and the method's it calls are the problem. (via average, variance, min, max, and importance)
### How is variance calculated?
It's not true variance, it's the average of the difference between the min, max, and average.
### How is importance calculated and why is it important?
Importance is "# of invocations" * "average time", this helps you determine which methods should be improved.
### What is delay?
Because the JVM will wait until a method is executed X number of times before it tries to improve it's execution speed (with JIT), you can set an invocation delay to avoid tracking statistics for the first X method invocations.
### What's the format of the configuration file?
```xml
```
### How do I use this?
You add the following VM arguments:
> -javaagent:theprof.jar=theprof.xml
Where theprof.jar is the location of a TheProf build, and theprof.xml is the location of the XML configuration file.
### Where do the profiling statistics go?
In the CWD directory of the application, a stats directory will be created which contains a CSV file for each profiled class and a CSV file that has all statistics.
### TODO
* Add a live statistics viewing option