Operating Systems and Computer Architecture: Key Concepts
Chapter 1 – Operating Systems
1. How would you use a computer without an operating system? What are its two main functions?
Without the operating system, a user interacting with the computer would need to know profoundly different details on hardware equipment, which would slow their work and introduce a great potential for error. The two main features are ease of access to system resources and resource sharing in an organized and protected manner.
2. Explain the concept of a virtual machine. What’s the big advantage in using this concept?
The computer can be viewed as a machine of layers, where initially there are two layers: hardware (Level 0) and operating system (level 1). Thus, the user can see the machine as being only the operating system, i.e., as if the hardware does not exist. This view is called a modular and abstract machine or virtual machine. The advantage of this concept is to make interaction between the user and the computer more simple, reliable, and efficient.
3. Define the concept of a host of levels or layers.
The computer can be viewed as a machine or machine-level layers, possessing as many levels as are necessary to bring the user to their various applications. When the user is working on one of these levels, they need not know the existence of the other layers. Thus the interaction between the user and the computer is simple, reliable, and efficient.
4. What types of existing operational systems are there?
Monoprogrammable tasking systems or systems or multiprogrammable multitasking and multiprocessor systems or processors.
5. Why do we say that there is an underutilization of resources in monoprogrammable systems?
Because in monoprogrammable systems it is only possible to run a program at a time. As a program does not use all the features of the system fully during its execution, there is idleness and consequently underutilization of some resources.
6. What’s the big difference between monoprogrammable and multiprogrammable systems?
Monoprogrammable systems are characterized by allowing the processor, memory, and peripherals to remain exclusively devoted to running a single program. In multiprogrammable or multitasking systems, the computational resources are shared among different users and applications. While in monoprogrammable systems there is only one program using the resources available, in multiprogrammable systems various applications share these resources.
7. What are the advantages of multiprogrammable systems?
The advantages of using multiprogrammable systems are reducing the response time of applications processed in the environment and costs from the sharing of system resources between several different applications.
8. Can a single-user system be a multiprogrammable system? Give an example.
Yes, only one user interacts with the system, but they can have several applications running concurrently. The Windows NT system is an example.
9. What types of multiprogrammable systems are there?
Batch systems, time-sharing systems, and real-time systems.
10. What is the distinguishing feature of batch processing? What applications can be processed in such an environment?
Batch processing has the characteristic of not requiring user interaction with the application. All inputs and outputs of the application are also implemented by some kind of secondary memory, typically disk files. Some examples of applications originally processed in batch programs involve numerical calculations, compilations, ordinances, backups, and all those where it is not necessary to interact with the user.
11. How do time-sharing systems work? What are the advantages of using them?
Time-sharing systems allow several programs to run from the division of processor time into small intervals, hereby named time-slice. The advantage of their use is that each user has a desktop itself, giving the impression that the whole system is dedicated exclusively to it.
12. What’s the big difference between time-sharing systems and real-time systems? What applications are suitable for real-time systems?
The response time factor. In real-time systems, response times should be within strict limits. Process control applications such as monitoring of oil refineries, air traffic control, and nuclear power plants are executed in real-time systems.
13. What are systems with multiple processors and what are the advantages of using them?
Systems with multiple processors are characterized by having two or more CPUs connected and working together. The advantage of this type of system is to allow multiple programs to run simultaneously or the same program is divided into parts to run simultaneously in more than one processor.
14. What’s the big difference between tightly coupled and loosely coupled systems?
Tightly coupled systems are multiple processors sharing a single physical memory and devices for input/output, being managed by a single operating system. Loosely coupled systems are characterized by having two or more computer systems connected via communication lines. Each system operates independently, having its own operating system and managing its own resources such as CPU, memory devices, and input/output.
15. What is an SMP system? What is the difference from a NUMA system?
In SMP (Symmetric Multiprocessing) systems, the access time to main memory by several processors is uniform. In NUMA (Non-Uniform Memory Access) systems, there are several sets of interconnected processors and main memory where the access time to main memory varies depending on their physical location.
16. What is a loosely coupled system? What is the difference between network operating systems and distributed operating systems?
Loosely coupled systems are characterized by having two or more computer systems connected via lines of communication. Each system operates independently, having its own operating system and managing its own resources such as CPU, memory devices, and input/output. A network operating system allows a host to share its resources, such as a printer or a directory with other network hosts, whereas in distributed systems, the operating system hides the details of individual hosts and starts to treat them as an entity, like a tightly coupled system.
Chapter 2 – Hardware and Software Concepts
1. What are the functional units of a computer system?
Processor or central processing unit, main memory devices, and input/output.
2. What are the components of a processor and what are its functions?
A processor consists of a control unit, an arithmetic and logic unit, and registers. The control unit (CU) is responsible for managing the activities of all the computer components, such as writing data to disks or for instructions in memory. The arithmetic and logic unit (ALU), as the name implies, is responsible for performing logical operations (and comparisons tests) and arithmetic (additions and subtractions).
3. How is the main memory of a computer organized?
The memory is composed of access units called cells, each cell consisting of a particular number of bits. Currently, the vast majority of computers use the byte (8 bits) as cell size.
4. Describe the cycles of read and write from main memory.
In the read cycle, the CPU stores in MAR the address of the cell to be read and generates a control signal for the main memory, indicating that a read operation should be performed. The content(s) of cell(s) identified by the address contained in the MAR is transferred to the MBR.
In the write cycle, the CPU stores in the MAR the cell address that will be recorded and stored in the MBR the information to be recorded. The CPU generates a control signal to main memory, indicating that a write operation must be performed and the information contained in the MBR is transferred to the memory cell addressed by the MAR.
5. What is the maximum number of cells addressed in architectures with MAR of 16, 32, and 64-bit?
- MAR = 16-bit number max = 216 cells
- MAR = 32-bit number max = 232 cells
- MAR = 64-bit number max = 264 cells
6. What are volatile memory and non-volatile memory?
Volatile memory must always be energized to keep its information, which does not happen with non-volatile memory.
7. Conceptualize cache and present the main advantages in its use.
Cache memory is a volatile, high-speed memory, but with small storage capacity. The access time to a given contained therein is much smaller than if it were in main memory. The purpose of using cache is to minimize the disparity between the speed at which the processor executes instructions and the speed at which data is accessed in main memory.
8. What are the differences between main memory and secondary memory?
The main memory is a storage device, usually volatile, where instructions and data used by the processor during program execution are stored. The secondary memory is a non-volatile device with greater storage capacity, but with slower access to its stored data.
9. Differentiate the basic functions of the devices I/O.
The input and output devices can be divided into two categories: those that are used as secondary memory and those that serve for the user-machine interface. Devices used as secondary memory (disks and tapes) are characterized by having enough storage capacity than the main memory. Its cost is relatively low, but the access time to secondary memory is well above the main memory. Other devices are intended for user-machine communication, such as keyboards, monitors, video, printers, and plotters.
10. Characterize the processor-memory buses, I/O, and backplane.
The processor-memory buses are of short length and high speed that is optimized for the transfer of information between processors and memories. The I/O buses have a greater extent, are slower, and allow the connection of different devices. The backplane bus has the task of integrating the two earlier buses.
11. How does the technique of pipelining improve the performance of computer systems?
Allowing the processor to execute multiple instructions in parallel at different stages.
12. Compare the processor architectures RISC and CISC.
See Table 2.3 in the book.
13. Conceptualize the technique of benchmarking and how it is achieved.
The technique known as benchmark allows the analysis of comparative performance between computer systems. In this method, a set of programs runs on each evaluated system and the runtime is compared. The choice of programs must be careful to reflect the different types of application.
14. Why does the object code generated by the translator not run?
This occurs because of a program to call external subroutines, and in this case, the translator has no way to associate the main program to subroutine calls. This function is performed by the linker.
15. Why is the execution of interpreted programs slower than compiled programs?
Since there is no generation of executable code, the instructions of a program should be translated every time this runs.
16. What are the functions of the linker?
Its primary functions are to resolve all symbolic references between the modules of a program and reserve memory for execution.
17. What is the main function of the loader?
Load a program in main memory to run.
18. What are the facilities offered by the debugger?
The Debugger provides the user with features such as monitoring the implementation of a program instruction by instruction; allowing the change and view the contents of variables; implementing breakpoints within the program (breakpoint), so that during execution, the program stops at these points and to specify that, whenever the contents of a variable is modified, the program sends a message (watchpoint).
19. Other commands available in the control languages of operating systems.
Free search.
20. Explain the process of activating (booting) the operating system.
Initially, the entire operating system code resides in secondary memory such as disks and tapes. Whenever a computer is turned on, the operating system has to be loaded from secondary memory to main memory. This procedure is performed by a program located on a specific block of the disk (boot block).