操作系统期末复习

mac2024-04-22  5

题中知识点速记

SMP Symmetric Multiprocessors compare with unprocessor architechure Performanceavailabilityincremental growthscaling+ In a multithreaded environment, the following are associated with processes: A virtual address space and protected access to processors, other processes, files, and I/O resources.Processes that are indirectly aware of each other have a relationship of (Competition)requiring that process request all of its required resources at one time and blocking the processes until all requests can be granted simultaneously can destroy the condition (Hold and Wait) to prevent deadlock.

扩展:几种避免deadlock的方法。

destroy “No preemption”: 一个进程不能在获取全部资源后就进入等待,如果hold资源的进程发生suspend,便会把资源隐式释放给其他进程,结束suspend要重新申请资源。destroy “Hold and Wait”: 当全部的资源都被granted后才能access and hold。(属于静态获取方法)destroy “Circular wait”: 资源分配编号,紧缺资源用大的编号,在获取资源时先用小编号。(资源有序分配) The technique that the OS shifts the processes from time to time so that they are contiguous and so that all of the free memory is together in one block os called (Compaction).The key difference between simple paging and virtual paging is (whether all the pages of a process must be in main memory for processto run, unless overlays are used.)The (Select function) determines which process processes, among ready processes, is selected next for execution.进程被suspend的原因:挂起是操作系统将进程占用的内存写入辅存,从而释放空间。原因: 交换。操作系统需要足够的空间,所以需要suspend一个进程。怀疑进程出现问题而挂起。交互式用户请求。例如调试等目的。定时。周期执行时等待期间有可能被挂起。父进程请求。父进程付出请求对进行挂起等操作,用来调度等。I/O 操作的种类 可编程I/O,特点处理器忙等待检查I/O完成情况。终端驱动I/O,特点利用终端机制处理I/O完成情况。DMA(直接存取访问),处理器向DMA控制器发出请求,DMA处理完一整个数据块才使用中断提示处理器。机器指令实现互斥的缺陷: 存在忙等待,处理器效率低下。可能存在饥饿,当一个进程离开临界区并且有多个进程正在等待,选择哪一个等待进程时任意的。因此某些进程可能无限等待。可能存在deadlock,例如优先级反转。

课上复习

进程时调度的基本单位线程运行在进程的地址空间

进程3态、5态、7态

用户级线程的缺点:一个线程被阻塞其他线程全部被阻塞

竞争条件、临界段的概念信号量,生产者消费者模型五道计算考四道 banker算法,找deadlock安全条件的 relocation overlay的概念
最新回复(0)