多執行緒程式的開發過程中,除錯一直都是程式開發人員能力的重大考驗。許多學術研究,往往只針對某種錯誤去做偵測,如dead lock或race condition這類的錯誤。但是大部分的開發人員,對多執行緒程式開發的知識較為薄弱,錯誤發生時,有時候他們根本不明白發生了什麼問題,自然也無從去找到適合的工具。因此,除錯過程中,往往曠日廢時,難以找出錯誤。一般的整合開發環境,有提供非常基本的多執行緒觀察的功能,但是這些的除錯的功能,使用者通常不知道如何去使用它,往往只有實力強且除錯能力技巧高段的工程師,才勉強知道有這樣的功能存在。 本論文利用Visual Studio SDK,開發出能夠協助程式設計師們找出concurrency errors的外掛程式。本工具利用除錯器的資料監控點、中斷點、call stack等功能,提供一組基本的工具,協助程式設計師們釐清concurrency error的蛛絲馬跡。工具會將過程記錄,程式設計師們可利用它記錄下來的內容進行分析除錯。 ;In multi-threaded program development process, debugging can be a difficult task for programmers. Many academic research often focus on some kind of concurrency errors, such as a race detector is designed to detect race condition only. In practice, programmers may not have enough multi-threading programming knowledge. When a program crashes, a programmer may not be aware of that it could be a concurrency error. So , applying a suitable tool could be hard in real cases. A debugger typically provides some very basic features to allow programmers to observe the status of the threads. In this thesis, we use the Visual Studio SDK to develop a tool called ThreadDebugger. This tool can help programmers to record the important traces and clues so that programmers can find the concurrency errors eventually. We use the wacthpoint to track memory access, and the log critical traces along the executions of threads. ThreadDebugger logs information such as stack frame, time tick and local variables. Programmer can use the log messages to dig out the causes and clues of concurrency errors.