心得分享

Card image cap

簡同學 報告/作業 分享經驗 11/13 11/6 OS作業

11/13 11/6 OS作業
名稱 11/6 OS作業
描述 11/6 OS作業
日期 11/13
課程名稱 作業系統
指導教師 劉艾華

1. Which situation is suitable to use message passing instead of shared-memory model for communication between processes? What are the pros and cons of using these two models?
Message passing is useful when smaller numbers of data need to be exchanged, because no conflicts need to be avoided. It is also easier to implement than is shared memory for intercomputer communication.
The pros and cons of message passing are listed below.
Memory is scalable with the number of processors. Increase the number of processors and the size of memory increases proportionately.
Each processor can rapidly access its own memory without interference and without the overhead incurred with trying to maintain global cache coherency.
Cost effectiveness: can use commodity, off-the-shelf processors and networking.
The pros and cons of shared memory are listed below.
Shared memory allows maximum speed and convenience of communication, as it can be done at memory speeds when within a computer. However, problem exist in the areas of protection and synchronization.
2. What is “system calls?” Please specify the functions and the purposes of a system call in a computer system.
Providing the interface to communicate with the operating system kernal is called system call. Without system call, communication between operating system and hardware is not possible. Accessing the files and process communication is possible through system calls. Library functions provide system call functionalities.
3. Please specify different ways for using the hardware configuration during the system generation (SYSGEN). What are the major differences between these different ways?
Used to modify a copy of the source code of the OS and have it re-compiled. Data declarations, initializations, and constants, along with conditional compilation, produce an output-object version of the operating system that is tailored to the system decribed.
Used to create tables and the selection modules from a precompiled library. The needed modules are linked together to form the generated OS. The selection allows the library to contain the device drivers for all supported I/O devices, but only those needed are linked into the operating system.
Construct a system that is completely table driven. All the code is always part of the system, and selection occurs at execution time. System generation involves simply creating the appropriate tables to describe the system.
The size and generality of the generated hardware configuration changes.

更新日期:2015/11/13 下午 02:39:18