OPERATING SYSTEMS CSC 4103
Popular in Course
Popular in ComputerScienence
This 4 page Class Notes was uploaded by Mr. Molly Kessler on Tuesday October 13, 2015. The Class Notes belongs to CSC 4103 at Louisiana State University taught by B. Ullmer in Fall. Since its upload, it has received 18 views. For similar materials see /class/222853/csc-4103-louisiana-state-university in ComputerScienence at Louisiana State University.
Reviews for OPERATING SYSTEMS
Report this Material
What is Karma?
Karma is the currency of StudySoup.
You can buy or earn more Karma at anytime and redeem it for class notes, study guides, flashcards, and more!
Date Created: 10/13/15
Miro416 RigTEE g Practice Exercises 11 What are the three main purposes of an operating system A er 115W 0 To provide an environment for a computer user to execute programs on computer hardware in a convenient and efficient manner To allocate the separate resources of the computer as needed to solve the problem given The allocation process should be as fair and efficient as possible As a control program it serves two major functions 1 supervision of the execution of user programs to prevent errors and improper use of the computer and 2 management of the operation and control of IO devices What are the main differences between operating systems for mainframe computers and personal computers Answer Generally operating systems for batch systems have simpler requirements than for personal computers Batch systems do not have to be concerned with interacting with a user as much as a personal computer As a result an operating system for a PC must be concerned with response time for an interactive user Batch systems do not have such requirements A pure batch system also may have not to handle time sharing whereas an operating system must switch rapidlybetween different jobs List the four steps that are necessary to run a program on a completely dedicated machine Answer 2 Chapter 1 Introduction a Reserve machine time b Manually load program into memory c Load starting address and begin execution d Monitor and control execution of program from console 14 We have stressed the need for an operating system to make efficient use 1 1 1 U1 ON 1 of the computing hardware When is it appropriate for the operating system to forsake this principle and to waste resources Why is such a system not really wasteful Answer Singleruser systems should maximize use of the system for the user A GUI might Waste CPU cycles but it optimizes the user s interaction with the system What is the main difficulty that a programmer must overcome in writing an operating system for a realitime environment Answer The main difficulty is keeping the operating system within the fixed time constraints of a realitime system If the system does not complete a task in a certain time frame it may cause a breakdown of the entire system it is running Therefore when writing an operating system for a realitime system the writer mustbe sure that his scheduling schemes don t allow response time to exceed the time constraint Consider the various definitions of operating system Consider whether the operating system should include applications such as Web browsers and mail programs Argue both that it should and that it should not and support your answer Answer Point Applications such as web browsers and email tools are performing an increasingly important role in modern desktop computer systems To fulfill this role they should be incorporated as part of the operating system By doing so they can provide better performance and better integration with the rest of the system In addition these important applications can have the same lookrandrfeel as the operating system software Counterpoint The fundamental role of the operating system is to mane age system resources such as the CPU memory IO devices etc In ad dition it s role is to run software applications such as web browsers and email applications By incorporating such applications into the operating system we burden the operating system with additional functionality Such aburden may result in the operating system performing a lessrthanr satisfactory job at managing system resources In addition we increase the size of the operating system thereby increasing the likelihood of system crashes and security violations How does the distinction between kernel mode and user mode function as a rudimentary form of protection security system Answer The distinction between kernel mode and user mode prof vides a rudimentary form of protection in the following manner Certain instructions could be executed only when the CPU is in kernel mode Similarly hardware devices could be accessed only when the program is executing in kernel mode Control over when interrupts could be en Lquot a Practice Exercises 3 abled or disabled is also possible only when the CPU is in kernel mode Consequently the CPU has very limited capability when executing in user mode thereby enforcing protection of critical resources Which of the following instructions should be privileged a Set value of timer b Read the clock c Clear memory d Issue a trap instruction e Turn off interrupts f Modify entries in devicestatus table g Switch from user to kernel mode h Access IO device Answer The following operations need to be privileged Set value of timer clear memory turn off interrupts modify entries in devicerstatus table access IO device The rest can be performed in user mode Some early computers protected the operating system by placing it in a memory partition that could not be modified by either the user job or the operating system itself Describe two difficulties that you think could arise with such a scheme Answer The data required by the operating system passwords access controls accounting information and so on would have to be stored in or passed through unprotected memory and thus be accessible to unauthorized users Some CPUs provide for more than two modes of operation What are two possible uses of these multiple modes Answer Although most systems only distinguish between user and kernel modes some CPUs have supported multiple modes Multiple modes could be used to provide a finerrgrained security policy For example rather than distinguishing betweenjust user and kernel mode you could distinguish between different types of user mode Perhaps users belonging to the same group could execute each other s code The machine would go into a specified mode when one of these users was running code When the machine was in this mode a member of the group could run code belonging to anyone else in the group Another possibility would be to provide different distinctions within kernel code For example a specific mode could allow USB device drivers to run This would mean that USB devices could be serviced without having to switch to kernel mode thereby essentially allowing USB device drivers to run in a quasiiuserkernel mode Timers could be used to compute the current time Provide a short de scription of how this could be accomplished Answer A program could use the following approach to compute the current time using timer interrupts The program could set a timer for 4 Chapter 1 Introduction some time in the future and go to sleep When it is awakened by the interrupt it could update its local state which it is using to keep track of the number of interrupts it has received thus far It could then repeat this process of continually setting timer interrupts and updating its local state when the interrupts are actually raised Is the Internet a LAN or a WAN Answer The Internet is a WAN as the various computers are located at geographically different places and are connected by longrdistance network links
Are you sure you want to buy this material for
You're already Subscribed!
Looks like you've already subscribed to StudySoup, you won't need to purchase another subscription to get this material. To access this material simply click 'View Full Document'