Thread state?

Windows内核调试

Thread state?


wrong 2012-05-16, 17:12 下午

使用!thread命令时有很多输出,有一个是thread state,

比如:WAIT: (WrUserRequest) UserMode Non-Alertable,WAIT: (Executive) KernelMode Non-Alertable

help中对这个一带而过,问下到底怎么理解?

Re: Thread state?


格蠹老雷 2012-05-17, 13:20 下午

所有以WAIT开始的都代表这个线程不在执行,由于调用了等待函数而处于挂起状态,冒号后面是等待的原因,其实也就是调用调用等待函数的具体情况,从哪里调用的(用户态/内核态),以及调用时使用的参数。

参考KeWaitXXX函数的文档:

http://msdn.microsoft.com/en-us/library/windows/hardware/ff553350(v=vs.85).aspx

以及:

http://msdn.microsoft.com/en-us/library/windows/hardware/ff565592(v=vs.85).aspx

 

 

Re: Thread state?


wrong 2012-05-18, 10:11 上午
多谢张老师,没写过驱动程序还真看不懂。

Powered by Community Server Powered by CnForums.Net