ubuntu - 一个高优先级的任务向一个低优先级的任务发送消息时会发生什么情况?
PHP中文网
PHP中文网 2017-04-24 09:12:40
0
1
729

这个低优先级的任务会不会接收这个消息呢?
系统会不会发生死锁?

PHP中文网
PHP中文网

认证0级讲师

reply all(1)
左手右手慢动作

Whether low-priority tasks will receive messages and execute them depends on the specific scheduling algorithm and how the program is written, such as whether the priority is real-time or based on time slices, whether message sending is blocking or non-blocking, etc.
As for whether a deadlock occurs, it should be definitely not a deadlock. Because the condition for a deadlock to occur must be that both tasks are waiting for each other, and if the high-priority task is blocked after sending a message, the low-priority task will definitely be scheduled for execution, and there will be no waiting for each other.

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template