分析介面Profiling Interfaces

本節說明 Unmanaged 介面,這類介面可讓您分析由 Common Language Runtime (CLR) 所執行的程式。This section describes the unmanaged interfaces that enable you to profile a program that is being executed by the common language runtime (CLR).

本章節內容In This Section

ICLRProfiling 介面ICLRProfiling Interface
提供AttachProfiler方法,可讓 profiler 附加至執行中的進程。Provides the AttachProfiler method, which enables a profiler to attach to a running process.

ICorProfilerAssemblyReferenceProvider 介面ICorProfilerAssemblyReferenceProvider Interface
可讓分析工具通知元件參考的 CLR,而分析工具將會在ICorProfilerCallback:: ModuleLoadFinished回呼中新增此檔案。Enables the profiler to inform the CLR of assembly references that the profiler will add in the ICorProfilerCallback::ModuleLoadFinished callback.

ICorProfilerCallback 介面ICorProfilerCallback Interface
提供讓 CLR 在分析工具已訂閱的事件發生時,通知程式碼分析工具的方法。Provides methods that are used by the CLR to notify a code profiler when the events to which the profiler has subscribed occur.

ICorProfilerCallback2 介面ICorProfilerCallback2 Interface
使用 .NET Framework 2.0 及更新版本中支援的回呼,延伸 ICorProfilerCallback 介面。Extends the ICorProfilerCallback interface with callbacks supported in the .NET Framework 2.0 and later versions.

ICorProfilerCallback3 介面ICorProfilerCallback3 Interface
提供回呼方法,供 CLR 用於將連結及中斷連結的狀態資訊傳達給分析工具。Provides callback methods that the CLR uses to communicate attach and detach state information to the profiler.

ICorProfilerCallback4 介面ICorProfilerCallback4 Interface
提供回呼方法,供 CLR 用於將資訊傳達給分析工具。Provides callback methods that the CLR uses to communicate information to the profiler.

ICorProfilerCallback5 介面ICorProfilerCallback5 Interface
提供方法,以識別記憶體回收根目錄所參考之物件的可轉移關閉。Provides a method that identifies the transitive closure of objects referenced by garbage collection roots.

ICorProfilerCallback6 介面ICorProfilerCallback6 Interface
提供 CLR 用於通知分析工具組件正在載入中的回呼方法。Provides a callback method that the CLR uses to notify a profiler that an assembly is loading.

ICorProfilerCallback7 介面ICorProfilerCallback7 Interface
提供一種回呼方法,讓通用語言執行時間用來通知分析工具,與記憶體中模組相關聯的符號資料流程已更新。Provides a callback method that the common language runtime uses to notify the profiler that the symbol stream associated with an in-memory module is updated.

ICorProfilerCallback8 介面ICorProfilerCallback8 Interface
提供公用語言執行時間用來通知分析工具,動態方法的 JIT 編譯已開始和完成的回呼方法。Provides callback methods that the common language runtime uses to notify the profiler that JIT compilation of a dynamic method has started and finished.

ICorProfilerCallback9 介面ICorProfilerCallback9 Interface
提供一種回呼方法,讓通用語言執行時間用來通知分析工具,動態方法會進行垃圾收集,然後再卸載。Provides a callback method that the common language runtime uses to notify the profiler that a dynamic method is garbage collected and subsequently unloaded.

ICorProfilerFunctionControl 介面ICorProfilerFunctionControl Interface
提供方法,讓程式碼分析工具能夠和 CLR 通訊,以控制 JIT 編譯器在重新編譯特定方法時,應如何產生程式碼。Provides methods that allow a code profiler to communicate with the CLR to control how the JIT compiler should generate code when recompiling a specific method.

ICorProfilerFunctionEnum 介面ICorProfilerFunctionEnum Interface
提供方法,以循序逐一查看 CLR 中的函式集合。Provides methods to sequentially iterate through a collection of functions in the CLR.

ICorProfilerInfo 介面ICorProfilerInfo Interface
提供程式碼分析工具用於和 CLR 通訊以控制事件監視及要求資訊的方法。Provides methods for use by code profilers to communicate with the CLR to control event monitoring and request information.

ICorProfilerInfo2 介面ICorProfilerInfo2 Interface
使用 .NET Framework 2.0 及更新版本中支援的方法,延伸 ICorProfilerInfo 介面。Extends the ICorProfilerInfo interface with methods supported in the .NET Framework 2.0 and later versions.

ICorProfilerInfo3 介面ICorProfilerInfo3 Interface
使用 .NET Framework 4 和更新版本中支援的方法來擴充 ICorProfilerInfo2 介面。Extends the ICorProfilerInfo2 interface with methods supported in the .NET Framework 4 and later versions.

ICorProfilerInfo4 介面ICorProfilerInfo4 Interface
提供程式碼分析工具用於和 CLR 通訊,以控制事件監視以及要求資訊的方法。Provides methods that code profilers use to communicate with the CLR to control event monitoring and to request information.

ICorProfilerInfo5 介面ICorProfilerInfo5 Interface
提供程式碼分析工具用於和 CLR 通訊以控制事件監視的方法。Provides methods for use by code profilers to communicate with the CLR to control event monitoring.

ICorProfilerInfo6 介面ICorProfilerInfo6 Interface
提供屬於給定 NGen 模組的所有方法的列舉值,並內嵌在指定方法的主體中。Provides an enumerator to all the methods that belong to a given NGen module and that are inlined in the body of a given method.

ICorProfilerInfo7 介面ICorProfilerInfo7 Interface
提供方法,以將新定義的中繼資料套用至模組,並提供記憶體內部符號資料流程的存取權。Provides a method to apply newly defined metadata to a module and that provides access to an in-memory symbol stream.

ICorProfilerModuleEnum 介面ICorProfilerModuleEnum Interface
提供方法,以循序逐一查看由應用程式或分析工具所載入的模組集合。Provides methods to sequentially iterate through a collection of modules loaded by the application or the profiler.

ICorProfilerObjectEnum 介面ICorProfilerObjectEnum Interface
提供方法,依序逐一查看由ngen.exe (原生映射產生器)所產生的凍結物件集合。Provides methods to sequentially iterate through a collection of frozen objects that are generated by Ngen.exe (Native Image Generator).

ICorProfilerThreadEnum 介面ICorProfilerThreadEnum Interface
提供方法,以循序逐一查看 CLR 中的執行緒集合。Provides methods to sequentially iterate through a collection of threads in the CLR.

IMethodMalloc 介面IMethodMalloc Interface
提供配置方法,為新的 Microsoft 中繼語言(MSIL)函式主體配置記憶體。Provides the Alloc method to allocate memory for a new Microsoft intermediate language (MSIL) function body.

分析概觀Profiling Overview

分析全域靜態函式Profiling Global Static Functions

分析列舉Profiling Enumerations

分析結構Profiling Structures