Profiling Global Static Functions

This section describes the unmanaged API functions that the profiling API uses.

In This Section

.NET Framework version 1 Profiling Functions

FunctionEnter Function
Notifies the profiler that control is being passed to a function. Deprecated in .NET Framework 2.0.

FunctionLeave Function
Notifies the profiler that a function is about to return to the caller. Deprecated in .NET Framework 2.0.

FunctionTailcall Function
Notifies the profiler that the currently executing function is about to perform a tail call to another function. Deprecated in .NET Framework 2.0.

.NET Framework version 2 Profiling Functions

FunctionIDMapper Function
Notifies the profiler that the given identifier of a function may be remapped to an alternative ID to be used in the FunctionEnter2, FunctionLeave2, and FunctionTailcall2 callbacks for that function. Also enables the profiler to indicate whether it wants to receive callbacks for that function

FunctionEnter2 Function
Notifies the profiler that control is being passed to a function and provides information about the stack frame and function arguments. Deprecated in the .NET Framework 4.

FunctionLeave2 Function
Notifies the profiler that a function is about to return to the caller and provides information about the stack frame and function return value. Deprecated in the .NET Framework 4.

FunctionTailcall2 Function
Notifies the profiler that the currently executing function is about to perform a tail call to another function and provides information about the stack frame. Deprecated in the .NET Framework 4.

StackSnapshotCallback Function
Provides the profiler with information about each managed frame and each run of unmanaged frames on the stack during a stack walk, which is initiated by the ICorProfilerInfo2::DoStackSnapshot method.

.NET Framework version 4 Profiling Functions

FunctionIDMapper2 Function
Notifies the profiler that the given identifier of a function may be remapped to an alternative ID to be used in the FunctionEnter3, FunctionLeave3, and FunctionTailcall3, orFunctionEnter3WithInfo, FunctionLeave3WithInfo, and FunctionTailcall3WithInfo callbacks for that function. Also enables the profiler to indicate whether it wants to receive callbacks for that function.

FunctionIDMapper2 extends the FunctionIDMapper function with a clientData parameter, which profilers may use to disambiguate among runtimes.

FunctionEnter3 Function
Notifies the profiler that control is being passed to a function.

FunctionEnter3WithInfo Function
Notifies the profiler that control is being passed to a function, and provides a handle that can be passed to ICorProfilerInfo3::GetFunctionEnter3Info to retrieve the stack frame and function arguments.

FunctionLeave3 Function
Notifies the profiler that control is being returned from a function.

FunctionLeave3WithInfo Function
Notifies the profiler that control is being returned from a function, and provides a handle that can be passed to ICorProfilerInfo3::GetFunctionLeave3Info to retrieve the stack frame and the return value.

FunctionTailcall3 Function
Notifies the profiler that the currently executing function is about to perform a tail call to another function.

FunctionTailcall3WithInfo Function
Notifies the profiler that the currently executing function is about to perform a tail call to another function, and provides a handle that can be passed to ICorProfilerInfo3::GetFunctionTailcall3Info to retrieve the stack frame.

Profiling Overview

Profiling Interfaces

Profiling Enumerations

Profiling Structures