dotTrace 2020.3 Help

Integrate Third-Party Tools with dotTrace

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. SamplingPerformanceProfiler = "{3-rd party clsid}"

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

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

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

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

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

  7. TracingInjectPerformanceProfiler = "{3-rd party clsid}"

  8. TracingInjectPerformanceProfiler_Path32 = "{3-rd party path to 32-bit shared library}"

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

  10. TimelineProfiler = "{3-rd party clsid}"

  11. TimelineProfiler_Path32 = "{3-rd party path to 32-bit shared library}"

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

  13. SamplingPerformanceProfiler_Attach = "{3-rd party clsid}"

  14. SamplingPerformanceProfiler_Attach_Path32 = "{3-rd party path to 32-bit shared library}"

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

  16. TimelineProfiler_Attach = "{3-rd party clsid}"

  17. TimelineProfiler_Attach_Path32 = "{3-rd party path to 32-bit shared library}"

  18. TimelineProfiler_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

Where:

  • <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