Code Analysis, Thread optimization
-
Hi All, My multithreaded app seems a little slow, and i'm not really sure where the cpu time is going. I suspect that i'm wasting time waiting for locks etc, and could probably structure the code a little better. but are there are tools that help you analyse what threads are doing? - how much cpu time each thread is using - how much time each thread spends blocking on a lock object etc. trying to diagnose the issues without better tools is going to be hard. Thanks Jon
using System.Beer;
-
Hi All, My multithreaded app seems a little slow, and i'm not really sure where the cpu time is going. I suspect that i'm wasting time waiting for locks etc, and could probably structure the code a little better. but are there are tools that help you analyse what threads are doing? - how much cpu time each thread is using - how much time each thread spends blocking on a lock object etc. trying to diagnose the issues without better tools is going to be hard. Thanks Jon
using System.Beer;
i have the same problem and currently downloading intel Vtune evaluation copy lets see if it helps
-
Hi All, My multithreaded app seems a little slow, and i'm not really sure where the cpu time is going. I suspect that i'm wasting time waiting for locks etc, and could probably structure the code a little better. but are there are tools that help you analyse what threads are doing? - how much cpu time each thread is using - how much time each thread spends blocking on a lock object etc. trying to diagnose the issues without better tools is going to be hard. Thanks Jon
using System.Beer;
I try starting it after installing but my system get crashed every time please let me know if you get a better option
-
Hi All, My multithreaded app seems a little slow, and i'm not really sure where the cpu time is going. I suspect that i'm wasting time waiting for locks etc, and could probably structure the code a little better. but are there are tools that help you analyse what threads are doing? - how much cpu time each thread is using - how much time each thread spends blocking on a lock object etc. trying to diagnose the issues without better tools is going to be hard. Thanks Jon
using System.Beer;
For figuring out the CPU time used by each thread, I'd suggest using Process Explorer[^]. It allows you to drill down into threads and watch CPU time. To find the contention rate among threads, you can use Perfmon (type perfmon.msc at the command prompt). The ".NET CLR LocksAndThreads" Performance Object has "Total # of contentions" and "Contention Rate/sec" counters, you need to just add them, making sure you select your process from the processes list on the right. Hope this helps.
Regards Senthil [MVP - Visual C#] _____________________________ My Blog | My Articles | My Flickr | WinMacro
-
i have the same problem and currently downloading intel Vtune evaluation copy lets see if it helps
Hello, is it (Vtune) really useful for C# code ? I di not see any feature in VTUNE so that i Know exactly which code segment is taking more CPU time ? I know VTUNE support C language, but I did not see any C# supports. When I tried to see the code, VTUNE exposed me the ASSEMBLY code for the given EXE file. Obviously seeing Assembly code will not make any sense for me to debug High Level C# code, aint i right ? would you Please let me know if I can make it useful for c# ?
-
Hello, is it (Vtune) really useful for C# code ? I di not see any feature in VTUNE so that i Know exactly which code segment is taking more CPU time ? I know VTUNE support C language, but I did not see any C# supports. When I tried to see the code, VTUNE exposed me the ASSEMBLY code for the given EXE file. Obviously seeing Assembly code will not make any sense for me to debug High Level C# code, aint i right ? would you Please let me know if I can make it useful for c# ?
bashiwala wrote:
Obviously seeing Assembly code will not make any sense for me to debug High Level C# code
Why?
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler. -- Alfonso the Wise, 13th Century King of Castile.
-
Hello, is it (Vtune) really useful for C# code ? I di not see any feature in VTUNE so that i Know exactly which code segment is taking more CPU time ? I know VTUNE support C language, but I did not see any C# supports. When I tried to see the code, VTUNE exposed me the ASSEMBLY code for the given EXE file. Obviously seeing Assembly code will not make any sense for me to debug High Level C# code, aint i right ? would you Please let me know if I can make it useful for c# ?
its working now its integrated in vs ide and it shows the code and lots of other information i need to study more what it shows but its working perfectly with c# however it require more ram and processor speed so it will be better to increase virtual memory before hand to know how it works please read the tutorial attached with VTune demo it is of about one hour
-
Hi All, My multithreaded app seems a little slow, and i'm not really sure where the cpu time is going. I suspect that i'm wasting time waiting for locks etc, and could probably structure the code a little better. but are there are tools that help you analyse what threads are doing? - how much cpu time each thread is using - how much time each thread spends blocking on a lock object etc. trying to diagnose the issues without better tools is going to be hard. Thanks Jon
using System.Beer;