Sun Studio 12 Update 1: C++ User's Guide

3.3.12 Profiling Options

Table 3–13 Profiling Options

Option 

Action 

–p

Prepares the object code to collect data for profiling using prof.

–xa

Generates code for profiling. 

–xpg

Compiles for profiling with the gprof profiler.

–xprofile

Collects or optimizes using runtime profiling data.