YourKit is a great Java profiling tool. It is a commercial software but you can get a free 15-day evaluation license key for a fully functional version of the profiler.
The past week I was working on a Java project and the software was very slow. Using YourKit I could easily find the bottleneck. It turned out that 94% of the time was spent in a function that I implemented in a naive way. Choosing a better algorithm the software got much faster. A profiler is really useful…
For Java I use Eclipse. YourKit integrates in Eclipse perfectly through an Eclipse plugin.
Here is an excellent post about Python profiling.
Here is how to use spaces instead of TABs in the Eclipse IDE:
- Click Window -> Preferences.
- Expand Java -> Code Style.
- Click Formatter.
- Click the Edit button.
- Click the Indentation tab.
- Under General Settings, set Tab policy to: Spaces only.
- Click OK to apply the changes.
Tip from here.