Go to main content
Oracle® Developer Studio 12.5: Performance Analyzer Tutorials

Exit Print View

Updated: June 2016
 
 

Using Performance Analyzer to Collect Data

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


Tip  -  If you prefer not to follow these steps to see how to profile applications, you can record an experiment with a make target included in the Makefile for lowfruit:
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 the Performance Analyzer to Examine the lowfruit Data.
  1. While still in the lowfruit directory start, Performance Analyzer:

    % analyzer

    Performance Analyzer starts and displays the Welcome page.

    image:Welcome page of Performance Analyzer

    If this is the first time you have used Performance Analyzer, no recent experiments are shown below the Open Experiment item. If you have used it before, you see a list of the experiments you recently opened from the system where you are currently running Performance Analyzer.

  2. Click the Profile Application link under Create Experiments in the Welcome page.

    The Profile Application dialog box opens with the General tab selected. On this page options are organized into several areas: Specify Application to Profile, Specify Experiment, and Advanced Experiment Settings.

  3. In the Target Program field, type the program name lowfruit.

    image:Profile Application dialog box

    Tip  -  You could start Performance Analyzer and open this dialog box directly with the program name already entered by specifying the target name when starting Performance Analyzer with the command analyzer lowfruit. This method only works when running Performance Analyzer locally.
  4. For the Target Input/Output option located at the bottom of the Specify Application to Profile panel, 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 the Target Input/Output option was changed 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.

  5. 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.

  6. Click the Data to Collect tab.

    The Data to Collect 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, but it is ignored for a non-Java target such as lowfruit.

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

  7. Click the Run button.

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

    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
  8. Click OK in the dialog box.

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