-
August 11th, 2009, 04:08 AM
#1
Debugging Multithreaded Application
Hello! I got a multithreaded application and need to debug it. My problem is that setting breakpoints is working, but from stopping the application to be able to watch variables, call stack and so on, it takes Visual Studio 2005 about 1-2 Minutes to display these values - I have no idea what it's doing in this time.
Is there a way to make this faster, because so debugging takes a lot of time.
-
August 11th, 2009, 04:26 AM
#2
Re: Debugging Multithreaded Application
Just go to Build menu option and run "Clean Solution" submenu option - that would speed up your debugging process.
Even I was facing the same problem and after I did Clean Solution - I could notice a quite a difference of improvement in the debugging speed !
-
August 11th, 2009, 05:59 AM
#3
Re: Debugging Multithreaded Application
it deponds on kind of synchronization you have used. for example performance of ReaderWriterLockSlim is better than ReaderWriterLock becuase of the bug in ReaderWriterLock. so tweeking your multi threading model can boos yourt performance.
for example you can use Mutex and semaphore in the same place but in problems that semaphore is not necessary then Mutex is better choice.
sometimes making types volatile can also have effect on performance when none-atomic operations gonna be done.
it was good point you say use how many thread you use in your application?
Please rate my post if it was helpful for you.  Java, C#, C++, PHP, ASP.NET
SQL Server, MySQL
DirectX
MATH Touraj Ebrahimi
[toraj_e] [at] [yahoo] [dot] [com]
-
August 11th, 2009, 07:28 AM
#4
Re: Debugging Multithreaded Application
Thanks for your replys. Cleaning the project helped a bit aynand reduced waiting time to half.
I'm using about 200 threads with semaphores, because we need to handle more than one resource.
-
August 11th, 2009, 10:11 AM
#5
Re: Debugging Multithreaded Application
Debugging multi-threaded applications is hard. You can't really apply the same debugging techniques you're use to. I could give you a couple tips but these guys say it better, read this article they wrote about multi-threaded applications. I found it awhile ago when I started working with multiple threads and the advice has been invaluable.
http://www.ddj.com/cpp/199200938?pgno=1
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
On-Demand Webinars (sponsored)
|