摘要
优先级反向是实时系统中由于任务间需要共享资源以及同步而引起的高优先级任务被低优先级任务阻塞的现象。优先级反向使得高优先级任务的执行时间无法预测,增加了实时系统的不确定性。早期的扩展协议较好地解决了优先级反转问题,但同时也存在着自身的不足。针对这些缺陷,在深入研究相关协议的基础上,该文提出了一种改进的优先级继承协议。该协议中信号量按预定义的非循环固定顺序获取,以防止死锁发生,设置超时保护机制,避免任务在获取信号量时长时间的阻塞,给出了关于该协议的分析,并在实时Linux上实现了基于该协议的算法。
Priority reverse is a kind of phenomenon that the higher priority task is blocked by the lower priority task since they are using the same sources in real time system. Priority reverse makes it is impossible to predict the execution time of the high priority task, and increases the indeterminacy of real time system. Although early priorities solved priority reverse, there are some limitations. To address these limitations, this paper gives rise to an improved priority inheritance protccol. In the improved protocol, the semaphores are acquired according to a fixed predetermined non-revolving sequence to avoid dead lock. Protocol establishes overtime protection mechanism to avoid prolonged block when tasks are acquiring semaphores. It analyzes the property of the protocol, on the bases of which an implementation under Linux is described. Experiment results show this protocol can perform efficiently.
出处
《计算机工程》
CAS
CSCD
北大核心
2007年第8期41-44,共4页
Computer Engineering
基金
国家"863"计划基金资助项目(2002AA1Z2306
2004AA1Z2351)
电子信息产业发展基金资助项目(XDJZ--0412-03)
粤港关键领域重点突破资助项目(20054981)
关键词
实时计算
优先级反转
优先级继承协议
优先级上限协议
Real-time computing
Priority reverse
Priority inheritance protocol
Priority ceiling protocol