From the Development Environment

HomeOverviewDetails

Feature Only in Professional and Enterprise Editions   Profiling is supported only in Visual C++ Professional and Enterprise Editions. For more information, see Visual C++ Editions.

If you are specifying function timing, function coverage, or line coverage from within the Profile dialog box, you can exclude object files or libraries from profiling by using /EXC, which is available in PREP Phase I, and the Advanced settings box.

For example, following is a line that you might type into the Advanced settings box that excludes two object files, file1.obj and file2.obj, from profiling:

/EXC file1.obj /EXC file2.obj

You can also use /EXCALL to exclude all object files and libraries and then use the /INC option to specify which object files and libraries to profile. For example, following is a line from a sample batch file that first excludes all object files and libraries and then includes file1.obj and file2.obj:

/EXCALL /INC file1.obj /INC file2.obj

You can even specify lines to profile in a source module. For example, if you only want to profile lines 32-96 (in source code) for a particular object file, you could issue

/EXCALL /INC file1.cpp(32-96)

Notice that you specify the lines directly from the source code file, which in this case has an extension of CPP.