Skip to content
GitLab
Explore
Projects
Groups
Topics
Snippets
Projects
Groups
Topics
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
educg-net-28668-2608132
调度算法创新实验-435
Commits
1d9248e5
Commit
1d9248e5
authored
5 months ago
by
ECNU571
Browse files
Options
Download
Patches
Plain Diff
Replace README.md
parent
ff6ff044
main
version2
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
README.md
+3
-1
README.md
with
3 additions
and
1 deletion
+3
-1
README.md
+
3
−
1
View file @
1d9248e5
...
...
@@ -29,7 +29,9 @@
优先级调度算法能够保证高优先级的进程能够得到快速的响应,对于实时系统尤为重要,但其容易引发优先级低的进程的饥饿现象。而我们的想法是并不是让高优先级的进程绝对的优先,而是让高优先级的进程获得更多的时间片。这样一来,高优先级的进程也能同样的占据更多的CPU资源,而低优先级的进程也能获得一些的时间片,避免了饥饿现象。
我们所设计的算法是将上述两种修改后的思想相结合。具体的,所有的就绪进程按照先来先服务的原则排成一个队列。CPU按照队列中的顺序,依次为每个进程分配CPU时间。如果这是CPU第i次为这个进程分配时间片,而这个进程的优先级为j,那么实际分配的时间片大小为 $ j
\t
imes $ 2
<sup>
i-1
</sup>
个时钟周期。当一个进程的时间片用完时,如果它还没有完成,它将被移到队列的末尾,等待下一轮的调度。
我们所设计的算法是将上述两种修改后的思想相结合。具体的,所有的就绪进程按照先来先服务的原则排成一个队列。
CPU按照队列中的顺序,依次为每个进程分配CPU时间。如果这是CPU第i次为这个进程分配时间片,而这个进程的优先级为j,
那么实际分配的时间片大小为j乘2的(i-1)次方个时钟周期。当一个进程的时间片用完时,如果它还没有完成,它将被移到队列的末尾,等待下一轮的调度。
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment
Menu
Explore
Projects
Groups
Topics
Snippets