How does the operating system act as a resource manager and extended machine?

Operating SystemHardwareSoftware & Coding

An operating system is the interface between the user and the machine which controls and coordinates the use of the hardware among the various application programs for the various users.

Operating System as Extended Machine

Let us understand how the operating system works as an Extended Machine.

  • At the Machine level the structure of a computer’s system is complicated to program, mainly for input or output. Programmers do not deal with hardware. They will always mainly focus on implementing software. Therefore, a level of abstraction is supposed to be maintained.

  • Operating systems provide a layer of abstraction for using disk such as files.

  • This level of abstraction allows a program to create, write, and read files, without dealing with the details of how the hardware actually works.

  • The level of abstraction is the key to managing the complexity.

  • Good abstractions turn an impossible task into two manageable tasks.

  • The first is to define and implement the abstractions.

  • The second is to solve the problem at hand.

  • Operating system provides abstractions to application programs in a top down view.

For example − It is easier to deal with photos, emails, songs, and Web pages than with the details of these files on disks.

The diagram given below shows the functioning of OS as an extended machine −

Operating System as Resource Manager

Let us understand how the operating system works as a Resource Manager.

  • Now-a-days all modern computers consist of processors, memories, timers, network interfaces, printers, and so many other devices.

  • The operating system provides for an orderly and controlled allocation of the processors, memories, and I/O devices among the various programs in the bottom-up view.

  • Operating system allows multiple programs to be in memory and run at the same time.

  • Resource management includes multiplexing or sharing resources in two different ways: in time and in space.

  • In time multiplexed, different programs take a chance of using CPU. First one tries to use the resource, then the next one that is ready in the queue and so on. For example: Sharing the printer one after another.

  • In space multiplexing, Instead of the customers taking a chance, each one gets part of the resource. For example − Main memory is divided into several running programs, so each one can be resident at the same time.

The diagram given below shows the functioning of OS as a resource manager −

raja
Updated on 26-Nov-2021 10:17:29

Advertisements