By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
446,187 Members | 988 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 446,187 IT Pros & Developers. It's quick & easy.

C# App Profiling

P: n/a
I'm posting this here and on the VS Forum (C#) and on XP Embedded ng

I have an XPe system that runs a .NET (C#) app that works with external hw
via USB ports. The app consists of a number of C# DLLs plus wrappers around
the hw dll APIs (ie platform invoke.

On a 1 Gig system the system maxes out at 100% CPU usage.
On a 1.9 Duo system it runs at about 33% (total) CPU usage.

The code written by someone else needs some profiling etc.
I suspect there are some busy waits that are polling for events rather than
the sw being event driven. I am about to try to improve the app.

Q What tools should I use to profile the app. Any whitepapers or other
references?

--
David Jones
Software Developer
(Embeddded Systems)
Victorian Partnership of Advanced Computing
Melbourne, Victoria Australia
Oct 14 '07 #1
Share this Question
Share on Google+
7 Replies


P: n/a
David Jones vpac org<davidj <ATDOTwrote:
Q What tools should I use to profile the app. Any whitepapers or other
references?
The profiler in Visual Studio Team Edition is good. It is not in Pro
edition.

Red Gate software kindly gave me a trial copy of their ANTS Profiler. I
discovered that it does not support ILX and just crashed on all but the
most trivial of F# programs as a consequence. Hopefully they'll fix it soon
because it looked like a really nice program.

--
Dr Jon D Harrop, Flying Frog Consultancy
http://www.ffconsultancy.com/products/?u
Oct 14 '07 #2

P: n/a
bob

Hi,
Red Ant has already been suggested, you may want to try JetBrains
Profiler also.
Bob
On Sat, 13 Oct 2007 19:09:00 -0700, David Jones vpac org<davidj
<ATDOTwrote:
>I'm posting this here and on the VS Forum (C#) and on XP Embedded ng

I have an XPe system that runs a .NET (C#) app that works with external hw
via USB ports. The app consists of a number of C# DLLs plus wrappers around
the hw dll APIs (ie platform invoke.

On a 1 Gig system the system maxes out at 100% CPU usage.
On a 1.9 Duo system it runs at about 33% (total) CPU usage.

The code written by someone else needs some profiling etc.
I suspect there are some busy waits that are polling for events rather than
the sw being event driven. I am about to try to improve the app.

Q What tools should I use to profile the app. Any whitepapers or other
references?
Oct 15 '07 #3

P: n/a
On Tue, 16 Oct 2007 10:57:16 +1300, bob
<st**************@cutthis.adriley.co.nzwrote:
>
Hi,
Red Ant has already been suggested, you may want to try JetBrains
Profiler also.
Bob
On Sat, 13 Oct 2007 19:09:00 -0700, David Jones vpac org<davidj
<ATDOTwrote:
>>I'm posting this here and on the VS Forum (C#) and on XP Embedded ng

I have an XPe system that runs a .NET (C#) app that works with external hw
via USB ports. The app consists of a number of C# DLLs plus wrappers around
the hw dll APIs (ie platform invoke.

On a 1 Gig system the system maxes out at 100% CPU usage.
On a 1.9 Duo system it runs at about 33% (total) CPU usage.

The code written by someone else needs some profiling etc.
I suspect there are some busy waits that are polling for events rather than
the sw being event driven. I am about to try to improve the app.

Q What tools should I use to profile the app. Any whitepapers or other
references?
The JetBrains profiler, DotTrace,is actually pretty good ...

--
http://bytes.thinkersroom.com
Oct 16 '07 #4

P: n/a
Rad [Visual C# MVP] wrote:
The JetBrains profiler, DotTrace,is actually pretty good ...
Does it support ILX, i.e. other .NET languages?

--
Dr Jon D Harrop, Flying Frog Consultancy
http://www.ffconsultancy.com/products/?u
Oct 17 '07 #5

P: n/a
On Wed, 17 Oct 2007 08:01:36 +0100, Jon Harrop <jo*@ffconsultancy.com>
wrote:
>Rad [Visual C# MVP] wrote:
>The JetBrains profiler, DotTrace,is actually pretty good ...

Does it support ILX, i.e. other .NET languages?
Indeed. Profilers don't deal with the program source code itself, but
rather with the compiled executable or class library.

Thus it does not matter what .NET language the application was written
with.

Although having said that having the source code is always good
because you can better analyze the profiler results and establish
problematic code or methods.

I wrote a short tutorial you can take a look at:

http://thinkersroom.com/bytes/2007/1...pplications-i/

--
http://bytes.thinkersroom.com
Oct 18 '07 #6

P: n/a
Rad [Visual C# MVP] wrote:
On Wed, 17 Oct 2007 08:01:36 +0100, Jon Harrop <jo*@ffconsultancy.com>
wrote:
>>Does it support ILX, i.e. other .NET languages?

Indeed. Profilers don't deal with the program source code itself, but
rather with the compiled executable or class library.

Thus it does not matter what .NET language the application was written
with.
That is not true of the ANTS profiler by RedGate software, which breaks on
the tail calls (ILX) generated by the F# compiler. I'd like to know if the
same is true of the profiler you cited.

--
Dr Jon D Harrop, Flying Frog Consultancy
http://www.ffconsultancy.com/products/?u
Oct 18 '07 #7

P: n/a
On Thu, 18 Oct 2007 14:59:30 +0100, Jon Harrop <jo*@ffconsultancy.com>
wrote:
>Rad [Visual C# MVP] wrote:
>On Wed, 17 Oct 2007 08:01:36 +0100, Jon Harrop <jo*@ffconsultancy.com>
wrote:
>>>Does it support ILX, i.e. other .NET languages?

Indeed. Profilers don't deal with the program source code itself, but
rather with the compiled executable or class library.

Thus it does not matter what .NET language the application was written
with.

That is not true of the ANTS profiler by RedGate software, which breaks on
the tail calls (ILX) generated by the F# compiler. I'd like to know if the
same is true of the profiler you cited.
Really? Wow. I didn't know that.
Hmm.

Let me investigate DotTrace and see whether it trips up as well.

--
http://bytes.thinkersroom.com
Oct 19 '07 #8

This discussion thread is closed

Replies have been disabled for this discussion.