资 源 简 介
这里没有任何的API调用 只是模拟,我给进程设定了自己的语法,输入一般的字符cpu调用时只是正常输出,如果遇到 $ 表示该进程要调用系统资源后面必须跟一个数字表示占有的时间,如果资源闲置则占有资源否则阻塞,等资源释放在占有资源。进程的调用算法我采用的是时间片轮转算法并有所改进,当某个进程从阻塞队列释放后,他将把以前因为等待资源而被浪费的时间补回来。 希望大家多提意见-here no API calls simulations, I set to process its own grammar, the characters importation cpu called only when normal output, said if the $ encountered in the process of system resources to call back with a figure must occupy the time said that if the idle occupies resources Otherwise obstruction, and other resources in the release of resources. Calling the process of the algorithm I use is time-rotate and improved algorithm, a process blocked from Queue After his release, he will wait before because resources were wasted by the time back up. We hope to speak up