November 15, 2006 in Software Development by Mark Levison

Or my pain with the Eclipse Profiling package.

My task for today – find a performance problem with our Eclipse application. Rather than use the sampling profiler built-in in to the VM (-hprof option) I wanted to use a more accurate tracing profiler. So my painful journey began.

  1. Find the Eclipse Test and Performance Tools Platform website (http://www.eclipse.org/tptp/)
  2. TPTP website hides the installation instructions – however Google found them here (http://www.eclipse.org/tptp/home/downloads/installguide/InstallGuide42.html)
  3. Using the update site (http://eclipse.org/tptp/updates/site.xml) recommend in the installation instructions, try to find the features. It’s slow, insanely slow.
  4. From 4.2.1 select the Tracing and Profiling package – get warned of errors because I don’t have all required plugins
  5. Use the Select required – get errors because it can’t find the required EMF dependency (among others)

  1. Now try the manual steps
    (http://www.eclipse.org/tptp/home/downloads/installguide/InstallGuide42.html#install_manual)
    of getting the All TPTP file
    (http://www.eclipse.org/downloads/download.php?file=/tptp/4.2.0/TPTP-4.2.0-200606190100A/tptp.runtime-TPTP-4.2.0.zip)
    from an Eclipse download site. Hint don’t choose the main site its slow
    try anything else (I used Indiana).
  2. Unzip the download files in your eclipse directory.
  3. Restart Eclipse
  4. Now I get the option to Analyze my code (a static analysis tool –
    like PMD. BTW why the duplication of effort?), but no “Profile As…”
    item in my toolbar/context menus
    (http://www.eclipse.org/articles/Article-TPTP-Profiling-Tool/tptpProfilingArticle.html)
    – what gives? Now I suspect that the right components were always on my disk I just didn’t know how to activate them.
  5. Now I’ve got a copy of TPTP 4.2.x installed maybe I can retry the update site and find a missing feature. But no joy just more wasted time.
  6. Off to try an commercial profiler for a few days. At least I will get a trial version that does the job.
  7. Tried YourKit profile v5.5 (http://www.yourkit.com/overview/index.jsp) – it installs quickly and easily.
  8. But when I try to profile a SWT application it dies. A quick
    glance at the release notes suggests that I need the YourKit Beta 6
    (http://www.yourkit.com/eap/index.jsp#change_list) to profile SWT
    applications.
  9. Next problem getting proper trace information requires Java 1.5 (we develop against ancient and creaky 1.4.x).
  10. Finally after 3 hours I’m actually profiling an app.
  11. YourKit is having some problems too (http://forums.yourkit.com/viewtopic.php?t=767) I can only get the CPU sampling not tracing to work. In the end I’ve only succeeded in getting a graphical version of hprof (with better stack traces).

Does anyone else think this completely insane? Does anyone from the TPTP project care?

Update: What I would like from the TPTP people at Eclipse:

  1. An Update mechanism that knows how to get emf.core and the other missing plug-ins or
  2. Change the installation instructions to include a description of the dependancies. and
  3. Include instructions on how to activate the profiler et al. once its installed.

If you enjoyed this post, subscribe now to get free updates.