CLR profiler Performance Analysis Tool

Source: Internet
Author: User

CLR profiler has two versions for clr1.1 and clr2.0 respectively. You can try clr4, but you do not know if it is completely compatible. They are 2003, respectively, and 2005 were released by Microsoft CLR performance group. Several hundred K small tools are providedSource codeThe core part is written in C ++ and the UI is written in C. CLR profiler uses a injection test, which records every memory allocation and method call, thus causing serious impact.ProgramThe execution speed will be 10 ~ slower ~ 100 times, and cannot be directly attached to the current running process.
Clrprofiler is a tool that focuses on tracking and analyzing the running status of GC heap.
You can know when using it:
1. Which method assigned objects of the type?
2. What objects survive?
3. What are there in heap?
4. What is it to keep the object alive?
5. How often is the method called in call statistics?
6. Test the application, Asp.net (this is not all I have succeeded), and service
7. Capture dump
8. Provide command line and API (not tried)

There are also fatal limitations:
1. slowing down the running speed. The result does not indicate the speed of the program.
2. cannot attach to process
3. He recorded a lot of content. If it was recorded for a long time, the analysis process would take a long time.
This tool is used to run your own test.CodeIn other places, only windbg is supported.

Run the program with the following functions.

This is the UI of the Tool. Start application selects the program to be run, and you can choose whether to track memory allocation and method calls. When the application is closed (automatically or manually), profiler automatically starts to sort the results. Shown as follows:

The summary in this statistics is displayed here.

CLR profiler has a dump capture function. Of course, it is timely. when running the program, Click Show head now to capture dump and quickly analyze the result.

As follows:

 

 

 

 

There are many buttons for viewing details in the statistical field:

Heap statistic stack Object Information Statistics

Allocated:

 

Relocated: the objects that have been moved again. After GC, the memory will sort the objects that have been moved:

Finally head object information in the final Stack:

There are also object finalized and critical object finalized, which indicate the object terminated by the Terminator. The object that is followed by the terminated object that has been marked with a special mark will not be intercepted if the graph difference is not big.

 

 

Next is the garbage collection statistics.

This indicates the total number of recycles.

Timeline: This is a detailed figure (it seems that this strong video card rendering is available on the company's machine)

The figure clearly shows the recovery time and memory usage

 

GC handle

The details are as follows:

 

Others

The summery interface does not display all functions:

You can find these in the View:

Right-click all bar charts and choose show who allocated is a nice one from the menu below to track who assigned the objects.

Assmebly Graph

Class Graph

The call tree function records the number of calls to each method. It is better to analyze the call tree in Vs, which can also count the time consumption :)

 

He and his brother talked about the CLR profiler and explained how to use it. Finally, it takes time to write an article. This time, I really understand the ease of using live writer. If I edit it on the webpage, it will die.

This is an introduction to CLR profiler.ArticleThe specific application scenarios can also be thought of after reading. Due to the limited length, a lot of content has not been written. The detailed description will be provided in the uninstall CLR profiler. More than 100 pages are really detailed. With it, there is no need to query any information. I suggest you look at it if you don't understand it :)

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.