主题 : linux2.6.38中默认的线程时间片是多长? 复制链接 | 浏览器收藏 | 打印
级别: 新手上路
UID: 93197
精华: 0
发帖: 20
金钱: 100 两
威望: 20 点
综合积分: 40 分
注册时间: 2013-06-17
最后登录: 2016-03-21
楼主  发表于: 2013-10-10 08:38

 linux2.6.38中默认的线程时间片是多长?

板子是Tiny6410,用的友善提供的2.6.38内核,默认优先级的默认线程运行的时间片是多长呢?
*無鈳取玳
级别: 论坛版主
UID: 27
精华: 12
发帖: 5398
金钱: 40120 两
威望: 17929 点
综合积分: 11036 分
注册时间: 2008-01-16
最后登录: 2014-11-22
1楼  发表于: 2013-10-10 12:29
从我的理解来说,内核只是定义了线程运行的最小时间片长,也就是系统时钟中断的周期(1 jiffies, 通常是10ms)。线程实际的时间片长度由很多因素决定,比如IO阻塞,系统run queue里面的线程数量以及系统scheduler的策略等等。
"If you have an apple and I have an apple and we exchange apples, then you and I will
still each have one apple. But if you have an idea and I have an idea and we exchange
these ideas, then each of us will have two ideas."