Online Mode of Operation: Example 2

Table of Contents

Simple example scenario 2 to show command usage

expCreate pcsamp

"1"

expCreate io

"2"

expCreate fpe

"3"

expAttach -x 1 -h host1 -f a.out, b.out, c.out

expAttach -x 2 -h host1 -f a.out, c.out

expAttach -h host1 -f b.out, c.out

expAttach -x 3 malloc

list -v params

1 not executing

pcsamp::samplingRate=10
displayMode=AtCompletion
displayMedia=GUI
displayRefreshRate=0
<other default values>

2 not executing

displayMode=AtCompletion
displayMedia=GUI
displayRefreshRate=0
<other default values>

3 not executing

displayMode=AtCompletion
displayMedia=GUI
displayRefreshRate=0
<other default values>

expSetParam -x 1 samplingRate=20

expSetParam -x 3 displayMode=realtime

expSetParam -x 3 displayMedia=GUI

expSetParam -x 3 displayRefreshRate=60

expGo all

explist

1 executing, data available

 -h host1 -f a.out, b.out, c.out pcsamp

2 complete, data available, realtime display

 -h host1 -f a.out, c.out io

3 executing, data available, realtime display

 -h host1 -f b.out, c.out fpe, malloc

expClose -x 3

exit



More detailed example scenario 2 to show command usage

This scenario is the same as the simple scenario 2 above but this one has more comments interspersed between the commands. It has a bit more information about what is going on under the hood.

#User launches Open|SpeedShop tool from a window. The CLI tool will come up first and then if the GUI option is not turned off the GUI will launch.

# expCreate will cause the initial default values of the specified experiment to be instantiated and the proper collector to be associated with the newly created experiment. The "1" below is the <expId> for the new pcsamp experiment.

# Since there is no executable specified on the expCreate, the experiment can not be executed but will act as a place holder for further commands.

expCreate pcsamp

"1"

# expCreate creates a second experiment, this one for io performance anlysis. The default experiment is now "2".

expCreate io

"2"

# expCreate creates a third experiment, this one for fpe. The default experiment is now "3".

expCreate fpe

"3"

# This expAttach command will associate the a.out, b.out, and c.out on host1 with experiment 1 as specified by the "-x 1" annotation.

expAttach -x 1 -h host1 -f a.out, b.out, c.out

# This expAttach command will associate the a.out and c.out on host1 with experiment 2 as specified by the "-x 2" annotation.

expAttach -x 2 -h host1 -f a.out, c.out

# This expAttach command will associate the b.out and c.out on host1 with experiment 3. This is not specifically called out via the "-x 3" annotation because experiment "3" is the default experiment.

expCreate -h host1 -f b.out, c.out

# expCreate adds a collector to the third experiment, specifically this command adds a collector for malloc performance analysis in addition to the fpe collector. The default experiment is still "3".

expCreate -x 3 malloc

# list -v params retrieves the list of parameters that may be changed by the user. The GUI and CLI tools need to display this to the user in order for the user to have the option of tuning the experiment to their specific needs. This command gets the parameters for experiment "1" which is the pc sampling experiment.

list -v params -x 1

1 not executing

pcsamp::samplingRate=10
displayMode=AtCompletion
displayMedia=GUI
displayRefreshRate=0
<other default values&glt;

# expSetParam defines arguments for the specified experiment. Here the "-x 1" indicates the experiment identifier.

expSetParam -x 1 pcsamp::samplingRate=10

# expSetParam defines arguments for the specified experiment. Here the "-x 3" indicates the experiment identifier,. These commands change the argument values for the fpe and malloc collectors comprising experiment "3".

expSetParam -x 3 displayMode=realtime

expSetParam -x 3 displayMedia=GUI

expSetParam -x 3 displayRefreshRate=60

# expGo all causes all 3 experiments to be started. Data is collected for all experiments an displayed in a GUI window for experiment 3, since the displayMode parameter has been set to realtime.

expGo all

# listExp causes the information about all 3 experiments to be listed. In this example, experiments "1" and "2" have completed execution. Data is still being collected and displayed for experiment "3".

explist

1 executing, data available

 -h host1 -f a.out, b.out, c.out pcsamp

2 complete, data available, realtime display

 -h host1 -f a.out, c.out io

3 executing, data available, realtime display

 -h host1 -f b.out, c.out fpe, malloc

# Stop experiment "3" and remove the experiment and the data. The processing that implements an experiment close operation includes

expClose -x 3

# Close Open|SpeedShop. The data that was collected for the all experiments is discarded and all GUI windows are closed. Since executables a.out and c.out are known to have terminated, all memory associated with them is reclaimed by the system. b.out is allowed to continue executing until it completes.

exit