dotMemory 2020.3 Help

Integrate Third-Party Tools with dotMemory

The JetBrains .NET tools (dotTrace, dotCover, and dotMemory) are based on a common profiler core. The core provides low-level profiling functionality like attaching to profiled processes, communication with the .NET runtime, collecting profiling data, and so on.

The profiler core provides a mechanism that lets third-party tools to integrate with JetBrains .NET tools. An example of such integration is Typemock Isolator running along with JetBrains dotTrace: Users not only test their code but also investigate performance problems.

Transparent integration concepts

The idea behind transparent integration is running a third-party core before the profiler core. In this case, the third-party core becomes responsible for loading and configuring the profiler core. JetBrains .NET tools, in their turn, guarantee that regsvr32 deploys and registers the profiler core before profiling.

How to activate integration

Add the following values to one of the registries HKCU\SOFTWARE\JetBrains\Profiler\TransparentIntegration or HKLM\SOFTWARE\JetBrains\Profiler\TransparentIntegration (32-bit and/or 64-bit):

  1. MemoryProfiler = "{3-rd party clsid}"

  2. MemoryProfiler_Path32 = "{3-rd party path to 32-bit shared library}"

  3. MemoryProfiler_Path64 = "{3-rd party path to 64-bit shared library}"

  4. MemoryProfiler_Attach = "{3-rd party clsid}"

  5. MemoryProfiler_Attach_Path32 = "{3-rd party path to 32-bit shared library}"

  6. MemoryProfiler_Attach_Path64 = "{3-rd party path to 64-bit shared library}"

How does the third-party core get data required to load the profiler core?

The goal is to find the profiler core GUID. To find the GUID, the third-party core must take the values of the JETBRAINS_PROFILER_CORE_GUID, JETBRAINS_PROFILER_CORE_PATH32, JETBRAINS_PROFILER_CORE_PATH64 variables from the following sources (the order does matter):

  1. HKCU\SOFTWARE\JetBrains\Profiler\Upid_<X>_<Y>

  2. HKLM\SOFTWARE\JetBrains\Profiler\Upid_<X>_<Y>

  3. Environment variables

  4. HKLM\SOFTWARE\JetBrains\Profiler\Global


  • <X>: an unsigned decimal process id

  • <Y>: a hexadecimal process start time in 100-nanosecond intervals since 01-Jan-1601 (UTC)

Last modified: 24 September 2020