Profiling VSTO Application Code

I am looking for a free code profiler (profile profiler, not memory profiler) that works for VSTO applications (in particular, Excel in my case, but I understand that if it works for one, it should work for everyone).

I tried Eqatec Profiler, but it cannot start the application from the profiler (the "Run application" button is grayed out, which I am compiling because the VSTO application is compiled in dll, the process with Excel.exe).

If anyone successfully used Eqatec or another free code profiler to profile a VSTO application, I would be interested to know how you did it.

+4
source share
2 answers

What you do should be possible with the EQATEC Profiler .

When you simply use one or more DLLs, there is no “launcher application”: you just have toolkit DLLs, but the profiler does not know how you are going to use them.

However, instrumental assemblies (together with the runtime module, EQATEC.Profiler.RuntimeFullNet.dll) are always completely "autonomous", which means that they themselves count the time as soon as the methods inside them are used. Thus, you just need your VSTO application to load the DLL, as usual, and voila, the DLL itself will begin to accumulate time information and begin to listen to the connection with the profiler, with which you can take pictures, etc.

So, we summarize:

  • Create a DLL and save the profiler
  • Ask your VSTO application to load the DLL (how do you do it)
  • Now you need to connect the profiler and the instrumental DLL (see the Run-run tab)
  • Inside the profiler you can now take pictures

Hope this helps. If not, let me know.

+2
source

Have you tried the Microsoft CLR Profiler?

I have used it with great success many times.

0
source

Source: https://habr.com/ru/post/1306195/


All Articles