我最初调整到的最困难的事情之一就是我第一次使用C语言编写C语言的强烈经验.我习惯于确切地知道下一行代码将会是什么,并且我的大多数调试技术都围绕着这种期望.
在C中使用pthread进行调试有哪些好方法?您可以在没有任何附加工具,使用的工具或其他任何可以帮助您调试的方法的情况下建议个人方法.
PS我在linux中使用gcc进行C编程,但不要让它限制你的答案
I'm trying to understand some of the basics of using POSIX pthreads. The kind of thing I need to do (eventually) is parallelize some computations, using a thread pool model. At present I want to ensure I have a very basic sense for how the POSIX pthread model works. So I'm trying to create the simplest thread pool that's general enough to do the kinds of things I want to do. There will be some shared memory, an input queue, …