There are some settings you can change to increase the performance of the profiler. Disabling real-time collection (by deselecting "Collect realtime data" in the Settings dialog) will probably affect the performance the most. Other things you can try is to disable root referee identification (only affects the performance under .NET 1.x), and heap utilization tracking. Enabling delayed instance cleanup will also in many cases improve the performance of the profiler.
Below is a short list of things the profiler performs that will slow down the application:
- Each time a class instance is allocated, the profiler must save information about the allocation. This information includes the class, the call stack of the allocation, the thread etc. The runtime, on the other hand, can allocate an instance extremely quickly; an allocation is more or less only an addition.
- Whenever a GC is performed, the profiler needs to update the locations of surviving instances (in case they have been moved) and it must cleanup information about instances that have been GCed. If real-time tracking is enabled, the profiler will also walk all references, in order to find out which instances are reachable. The runtime can optimize the walking of references significantly when a lower generation GC if performed, and it does not have to perform any "cleanup" of GCed instances.
- The profiler also has to keep track of the call stack at all times. This adds a slight overhead to all method calls, but should not create to much overhead unless the methods are very short.
SciTech Software AB
Users browsing this forum: Google [Bot] and 13 guests