Profilling Silverlight with differents XAPs (Prism + MEF)

Memory profiling for .NET developers

Moderators: Bart Read, Luke Jefferson, StephenC, AndrewH, melvyn.harbour, james.billings, Laura Morley, dene.boulton

Profilling Silverlight with differents XAPs (Prism + MEF)

Postby iulo » Wed Feb 29, 2012 9:42 pm

Hi,

I'm having problems with memory leaks in my Silverlight application and I'm interested on ANTS Memory Profiler. The only problem is: my application uses PRISM + MEF, and I have many modules, each one is as different xap.

Will I be able to profile my application using ANTS?

I have a mainmodule.xap wich I can profile trough ANTS, but this first module loads the other .xaps (where my real problems are ocurring). I mean, I have a module1.xap, module2.xap, module3.xap and I need to profile those.

How can I do it using ANTS? Or it is not possible at all?

Thanks.
iulo
 
Posts: 2
Joined: Wed Feb 29, 2012 9:32 pm

Postby Brian Donahue » Thu Mar 01, 2012 4:05 pm

ANTS Memory Profiler is process-oriented - so if all of the DLLS contained in all the XAPs are hosted in the same process, you will be profiling them all together. If not, you would need to launch additional instances of Memory Profiler.
Brian Donahue
 
Posts: 6668
Joined: Mon Aug 23, 2004 10:48 am

Postby iulo » Thu Mar 01, 2012 4:07 pm

So, if all the xaps are loaded and executed in the same slllauncher.exe or iexplore.exe process, I should be able to profile all the xaps?
iulo
 
Posts: 2
Joined: Wed Feb 29, 2012 9:32 pm

Postby Brian Donahue » Thu Mar 01, 2012 7:01 pm

Yes, you will profile all the XAPs!
Brian Donahue
 
Posts: 6668
Joined: Mon Aug 23, 2004 10:48 am

Re:

Postby anny_mumu » Wed Mar 28, 2012 8:12 am

Brian Donahue wrote:Yes, you will profile all the XAPs!



I meet the same problem like that.

Ants Log like "28 Mar 2012 15:03:20.666 [16] WARN RedGate.Profiler.Engine.Startup.Counters.WindowsPerfCounter - Error while trying to read performance counter data
System.InvalidOperationException: 指定的类别中不存在实例“sllauncher”。
在 System.Diagnostics.CounterDefinitionSample.GetInstanceValue(String instanceName)
在 System.Diagnostics.PerformanceCounter.NextSample()
在 ???.???.NextSample()"

How can i do ?
anny_mumu
 
Posts: 4
Joined: Wed Mar 28, 2012 8:08 am

Postby Brian Donahue » Wed Mar 28, 2012 9:16 am

Actually, this is an erro rather than a question about usage. Something is wrong with the performance counters, I reckon, so you may want to rebuild them. Here are the instructions.

http://www.red-gate.com/supportcenter/c ... 0810000316

If this does not work, please email our support address - we will need to open a support call.
Brian Donahue
 
Posts: 6668
Joined: Mon Aug 23, 2004 10:48 am

Postby anny_mumu » Wed Mar 28, 2012 10:46 am

I just trial 7.3
I gess the reason that maybe my system is win7 64bit?
anny_mumu
 
Posts: 4
Joined: Wed Mar 28, 2012 8:08 am

Postby Brian Donahue » Wed Mar 28, 2012 2:07 pm

No, that's fine. Profiler works with 64-bit. The Windows configuration is broken. The performance counters probably need to be rebuilt. I don't know why, but Windows likes to scramble itself up from time to time.
Brian Donahue
 
Posts: 6668
Joined: Mon Aug 23, 2004 10:48 am

Postby anny_mumu » Thu Mar 29, 2012 3:44 am

I try your tips but error still happened like that
http://ww3.sinaimg.cn/bmiddle/71e54385gw1drgh0sgcikg.gif
anny_mumu
 
Posts: 4
Joined: Wed Mar 28, 2012 8:08 am

Postby Brian Donahue » Thu Mar 29, 2012 9:17 am

I have logged a support incident for you and you will get an email from us. This is probably not specific to MEF, XAP or any other three-letter acronym, it looks like a general type of failure.
Brian Donahue
 
Posts: 6668
Joined: Mon Aug 23, 2004 10:48 am

Postby anny_mumu » Thu Mar 29, 2012 10:25 am

thanks , i had reply the mail. to except an anwser.
anny_mumu
 
Posts: 4
Joined: Wed Mar 28, 2012 8:08 am


Return to ANTS Memory Profiler 7

Who is online

Users browsing this forum: No registered users and 0 guests