WPF Application Start Up Time
mfreeman37
Posts: 3
When I run my WPF application in the ANTS Performance Profiler, it takes a very long time to start up. It takes roughly 4 times longer to start up in the profiler than it does in the debugger or from the console.
My main concern and reason for using the profiler at this time is to enhance startup time on my application, so this slowdown is making the use of the ANTS profiler useless in this case.
Is there some configuration that will help get my startup time to be more inline with what it should be?
Thank You
MEF
My main concern and reason for using the profiler at this time is to enhance startup time on my application, so this slowdown is making the use of the ANTS profiler useless in this case.
Is there some configuration that will help get my startup time to be more inline with what it should be?
Thank You
MEF
Comments
I have noticed the same issue myself -- I think that the base reason for WPF startup being slowed down this noticably is that there are a lot of recursive methods. If you profile a WPF app, you will see some methods have a high hit count. The get_CurrentThread method will be in the hundreds of thousands, then the call graph shows some recursion in SubclassWndProc.
Recursive methods have historically caused a performance hit for profilers.
How can I profile down into these methods?
Currently, the profiler just shows them collapsed without source.
I assume this is where the framework stuff is sitting.
Thank You for you help!
MEF
if you want to see the collapsed methods then just change the display options - see the combo boxes.
By default it shows "Top down, methods with source"
Just change this to Top Down, any method.
Be warned though - the noise of showing all these methods will be large. I would select the region of interest and switch to the All Method grid and change the display settings there too.
S