Oracle® Solaris Studio 12.4: Performance Analyzer Tutorials

Exit Print View

Updated: December 2014
 
 

Using Performance Analyzer to Collect Data from jlowfruit

This section describes how to use the Profile Application feature of Performance Analyzer to collect data in an experiment on a Java application.


Tip  -  If you prefer not to follow these steps to see how to profile applications from Performance Analyzer, you can record an experiment with a make target included in the Makefile for jlowfruit:
% make collect
The collect target launches a collect command and records an experiment just like the one that you create using Performance Analyzer in this section. You could then skip to Using Performance Analyzer to Examine the jlowfruit Data.
  1. While still in the jlowfruit directory start Performance Analyzer with the target java and its arguments:

    % analyzer java -Xmx100m -XX:ParallelGCThreads=10 jlowfruit

    The Profile Application dialog box opens with the General tab selected and several options already filled out using information you provided with the analyzer command.

    Target Program is set to java and Arguments is set to

    -Xmx100m -XX:ParallelGCThreads=10 jlowfruit
    image:General tab of the Profile Application dialog box with preset Target Program               and Arguments
  2. For the Target Input/Output option, select Use Built-in Output Window.

    Target Input/Output option specifies the window to which the target program stdout and stderr will be redirected. The default value is Use External Terminal, but in this tutorial you should change the Target Input/Output option to Use Built-in Output Window to keep all the activity in the Performance Analyzer window. With this option the stdout and stderr is shown in the Output tab in the Profile Application dialog box.

    If you are running remotely, the Target Input/Output option is absent because only the built-in output window is supported.

  3. For the Experiment Name option, the default experiment name is test.1.er but you can change it to a different name as long as the name ends in .er, and is not already in use.

  4. Click the Data to Collect tab.

    The Data to Collect tab enables you to select the type of data to collect, and shows the defaults already selected.

    image:Data to Collect window Profile Application dialog box

    Java profiling is enabled by default as you can see in the screen shot.

    You can optionally click the Preview Command button and see the collect command that will be run when you start profiling.

  5. Click the Run button.

    The Profile Application dialog box displays the Output tab and shows the program output in the Process Output panel as the program runs.

    After the program completes, a dialog box asks if you want to open the experiment just recorded.

    image:Output window of Profile Application dialog box
  6. Click Open Experiment in the dialog box.

    The experiment opens. The next section shows how to examine the data.