wayground logo

Free Printable Worksheets

Font size

S
M
L
XL
Worksheets

Computer System and Page Replacement Quiz

Total questions: 81

Worksheet time: 41mins

Name
Class
Date
1.

For 3 page frames, the following is the reference string: 7 0 1 2 0 3 0 4 2 3 0 3 2 1 2 0 1. How many page faults does the LRU page replacement algorithm produce (including page faults when the frames were free)?

a)

11

b)

13

c)

12

d)

10

2.

For 3 page frames, the following is the reference string: 7 0 1 2 0 3 0 4 2 3 0 3 2 1 2 0 1. How many page faults does the Optimal page replacement algorithm produce (including page faults when the frames were free)?

a)

11

b)

9

c)

10

d)

8

3.

For 3 page frames, the following is the reference string: 7 0 1 2 0 3 0 4 2 3 0 3 2 1 2 0 1. How many page faults does the FIFO page replacement algorithm produce (including page faults when the frames were free)?

a)

13

b)

14

c)

16

d)

15

4.

What is not a main structural element of a computer system?

a)

Processor

b)

I/O modules

c)

Operating system

d)

Main memory

5.

Which of the following element of a computer system stores data and programs?

a)

System bus

b)

Processor

c)

Main memory

d)

I/O modules

6.

Which of the following provides for communication among elements of a computer system?

a)

System bus

b)

Processor

c)

AC

d)

Main memory

7.

Which of the following element of a computer system moves data between the computer and its external environment?

a)

Main memory

b)

I/O modules

c)

Registers

d)

System bus

8.

The processor contains a single data register, called

a)

PC

b)

AC

c)

MAR

d)

IR

9.

This register specifies a particular input/output device

a)

I/OBR

b)

MAR

c)

I/OAR

d)

PC

10.

This register is used for the exchange of data between an I/O module and the processor

a)

AC

b)

IR

c)

I/OAR

d)

I/OBR

11.

This register contains the data to be written into memory or which receives the data read from memory

a)

Memory buffer register

b)

Memory address register

c)

Accumulator

d)

Instruction register

12.

This register specifies the location in memory for the next read or write

a)

Accumulator

b)

Memory buffer register

c)

Memory address register

d)

Instruction register

13.

Which register contains the address of the next instruction to be fetched?

a)

MAR

b)

Accumulator

c)

Instruction register

d)

Program counter

14.

Which register contains the instruction most recently fetched?

a)

AC

b)

Instruction register

c)

MBR

d)

Program counter

15.

Index register, segment register, and stack register are examples of

a)

Data registers

b)

Control registers

c)

Flag registers

d)

Status registers

16.

Which of the following registers are used by the processor to exchange data with memory?

a)

MAR and MBR

b)

AC and IR

c)

MBR and IR

d)

PC and IR

17.

Which of the following registers are used by the processor to exchange data with Input/output module?

a)

PC and AC

b)

IR and MAR

c)

I/OAR and I/OBR

d)

MAR and MBR

18.

Which of the following element of a computer system controls the operation of the computer and performs its data processing functions?

a)

System bus

b)

I/O modules

c)

Main memory

d)

Processor

19.

For 4 page frames, the following is the reference string: 1 2 3 4 2 1 5 6 2 1 2 3 7 6 3 2 1 2 3 6. How many page faults does the LRU page replacement algorithm produce (including page faults when the frames were free)?

a)

12

b)

8

c)

10

d)

11

20.

For 4 page frames, the following is the reference string: 1 2 3 4 2 1 5 6 2 1 2 3 7 6 3 2 1 2 3 6. How many page faults does the FIFO page replacement algorithm produce (including page faults when the frames were free)?

a)

15

b)

12

c)

13

d)

14

21.

For 4 page frames, the following is the reference string: 1 2 3 4 2 1 5 6 2 1 2 3 7 6 3 2 1 2 3 6. How many page faults does the Optimal page replacement algorithm produce (including page faults when the frames were free)?

a)

10

b)

8

c)

7

d)

9

22.

The fetched instruction is loaded into

a)

IR

b)

PC

c)

MAR

d)

AC

23.

At the beginning of each instruction cycle, the processor fetches an instruction from the memory. The address of the instruction is held in

a)

PC

b)

IR

c)

MAR

d)

MBR

24.

The processor is executing 'Load AC from memory' instruction. Choose the correct micro-instructions:

a)

PC → MBR M → IR

b)

MBR → IR M → AC

c)

MAR → PC M → IR

d)

PC → MAR M → MBR MBR → IR IR → MAR M → MBR MBR → AC

25.

Process is

a)

a program in execution

b)

a data structure

c)

a user process

d)

a thread

26.

A task in a blocked state

a)

is in ready state

b)

is executing

c)

is waiting for some temporarily unavailable resources

d)

has completed execution

27.

The system which allows only one process execution at a time, are called

a)

Real-time systems

b)

Uniprogramming sys

28.

The system which allows only one process execution at a time, are called

a)

Real-time systems

b)

Uniprogramming systems

c)

Distributed systems

d)

Multiprogramming systems

29.

Which of the following is not the state of a process?

a)

Ready

b)

Running

c)

Old

d)

Blocked

30.

Suppose that a process is in 'Blocked' state waiting for some I/O service. When the service is completed it goes to the:

a)

Exit state

b)

Ready state

c)

New state

d)

Running state

31.

Which of the following state transitions is not possible?

a)

Blocked to running

b)

Blocked to ready

c)

Ready to running

d)

Running to blocked

32.

If a process is executing in its critical section, then no other processes can be executing in their critical section. This condition is called

a)

Mutual exclusion

b)

Starvation

c)

Semaphore

d)

Deadlock

33.

Process is

a)

An OS thread

b)

A unit of activity characterized by the execution of a sequence of instructions, a current state, and an associated set of system instructions

c)

A data structure

d)

A program in memory

34.

Interprocess communication:

a)

allows processes to synchronize activity

b)

uses cache memory

c)

prevents multitasking

d)

uses signals only

35.

A program

a)

is a single instruction

b)

is an OS task

c)

is a sequence of instructions

d)

is a running process

36.

In operating system, each process has its own:

a)

all of the above

b)

address space

c)

open files

d)

program counter

37.

For each process OS creates and manages:

a)

Thread block

b)

File table

c)

Process control block

d)

Semaphore

38.

Listing the sequence of instructions that are executed is called?

a)

Schedule

b)

Log

c)

Trace

d)

Track

39.

A process can be terminated due to:

a)

All of the mentioned

b)

I/O failure

c)

Software error

d)

Parent termination

40.

What is the ready state of a process?

a)

When process is scheduled to run after some execution

b)

When it's created

c)

When it's blocked

d)

When it's terminated

41.

What is interprocess communication?

a)

Communication between two process

b)

File sharing

c)

Communication inside one thread

d)

Data duplication

42.

A set of processes is deadlock if:

a)

Each process is terminated

b)

Each process is blocked and will remain so forever

c)

No process is ready

d)

Processes are waiting indefinitely

43.

The address of the next instruction to be executed by the current process is provided by the:

a)

MBR

b)

Program counter

c)

Instruction register

d)

MAR

44.

A single thread of control allows the process to perform:

a)

Concurrent jobs

b)

All processes

c)

Multiple tasks

d)

Only one task at a time

45.

The objective of multi-programming is to:

a)

To run only one process

b)

To minimize memory use

c)

To simplify OS

d)

To maximize CPU utilization

46.

What is a long-term scheduler?

a)

It selects which process has to be brought into the ready queue

b)

It handles I/O devices

c)

It switches contexts

d)

It allocates memory

47.

What is a short-term scheduler?

a)

It manages files

b)

It handles cache

c)

It selects which process has to be executed next and allocates CPU

d)

It allocates registers

48.

The primary distinction between the short-term and long-term scheduler is:

a)

The memory they use

b)

The frequency of their execution

c)

The process size

d)

The speed

49.

In a multi-programming environment

a)

Only one process in memory

b)

Processes are stored on disk

c)

No process in memory

d)

More than one process resides in the memory

50.

Which of the following state transitions is not possible?

a)

Blocked to ready

b)

Running to blocked

c)

Blocked to running

d)

Ready to running

51.

Which of the following is a synchronization tool?

a)

Semaphore

b)

Cache

c)

Interrupt

d)

Thread

52.

Mutual exclusion can be provided by the:

a)

Signals

b)

Only mutex

c)

Both (mutex locks, binary semaphores)

d)

Only semaphores

53.

When high priority task is indirectly preempted by medium priority task effectively inverting the relative priority of the two tasks, the scenario is called:

a)

Context switch

b)

Priority inversion

c)

Deadlock

d)

Starvation

54.

With … only one process can execute at a time; meanwhile all other process are waiting for the processor. With … more than one process can be running simultaneously each on a different processor

a)

Multiprogramming, Monoprocessing

b)

Uniprogramming, Multiprocessing

c)

Threading, Context Switching

d)

Multitasking, Uniprogramming

55.

Interprocess communication:

a)

Requires semaphores

b)

Requires shared memory

c)

Allows processes to communicate and synchronize their actions without using the same address space

d)

Is not needed

56.

Message passing system allows process to:

a)

Communicate with one another without resorting to shared data

b)

Share memory directly

c)

Use shared variables

d)

Use semaphores only

57.

The link between two processes P and Q to send and receive messages is called:

a)

Data bus

b)

Communication link

c)

Pipe

d)

Message buffer

58.

In indirect communication between processes P and Q:

a)

They use semaphores

b)

There is a mailbox to help communication between P and Q

c)

They communicate via cache

d)

They use sockets

59.

In the non-blocking send:

a)

The process waits

b)

The receiver blocks

c)

The sending process sends the message and resumes operation

d)

The message is dropped

60.

In the blocking send, blocking receive:

a)

Both sender and receiver are blocked until message is delivered

b)

None blocked

c)

Only receiver blocked

d)

Only sender blocked

61.

In the non-blocking send, blocking receive:

a)

Receiver continues

b)

Sender continues on, receiver is blocked until the requested message arrives

c)

Both continue

d)

Sender blocked

62.

In the non-blocking send, non-blocking receive:

a)

Neither of processes are required to wait

b)

Both wait

c)

Sender waits

d)

Receiver waits

63.

Remote Procedure Calls (RPC) are used:

a)

Between threads

b)

On same system

c)

For communication between two processes on separate systems

d)

Only locally

64.

What is a trap/exception

a)

Context switch

b)

Software generated interrupt caused by an error

c)

Cache miss

d)

Hardware failure

65.

Semaphores:

a)

Synchronize critical resources to prevent deadlock

b)

Only manage memory

c)

Only schedule I/O

d)

Terminate threads

66.

Four necessary conditions for deadlock to exist are: mutual exclusion, no-preemption, circular wait and

a)

Interrupt block

b)

Hold and wait

c)

I/O wait

d)

Deadlock count

67.

Part of a program where the shared memory is accessed and which should be executed invisibly, is called:

a)

I/O area

b)

Critical section

c)

Execution segment

d)

Shared block

68.

Banker's algorithm for resource allocation deals with:

a)

Context switching

b)

Deadlock avoidance

c)

Paging

d)

Interrupts

69.

A situation where several processes access and manipulate the same data concurrently and the outcome of the execution depends on the particular order in which access takes place is called:

a)

Deadlock

b)

Thread conflict

c)

Priority inversion

d)

Race condition

70.

The segment of code in which the process may change common variables, update tables, write into files is known as:

a)

I/O section

b)

Instruction set

c)

Execution block

d)

Critical section

71.

Mutual exclusion means that:

a)

All processes execute freely

b)

If a process is executing in its critical section, then no other process must be executing in their critical sections

c)

No critical sections

d)

Processes share access

72.

A minimum of … variables is/are required to be shared between processes to solve the critical section problem?

a)

Two

b)

Four

c)

Three

d)

One

73.

An un-interruptible unit is known as:

a)

Binary

b)

Critical

c)

Atomic

d)

Semaphored

74.

Semaphore is a/an … to solve the critical section problem:

a)

Communication tool

b)

Queue system

c)

Synchronization tool

d)

Memory area

75.

The code that changes the value of the semaphore is:

a)

Wait code

b)

Critical section code

c)

Initialization

d)

Exit code

76.

The two kinds of semaphores are:

a)

Integer, Boolean

b)

Shared, Exclusive

c)

Counting, Binary

d)

True, False

77.

A binary semaphore is a semaphore with integer values:

a)

0, 2

b)

0, 1

c)

1, 2

d)

-1, 1

78.

A monitor is a type of:

a)

Thread type

b)

High level synchronization construct

c)

Memory handler

d)

Semaphore

79.

What is the reusable resource:

a)

Shared resource

b)

That can be used by one process at a time and is not depleted by that use

c)

Cache

d)

Temporary file

80.

A system is in the safe state if:

a)

Only a

b)

None of the above

c)

Both a and b

d)

Only b

81.

Which of the following is the deadlock avoidance algorithm?

a)

FIFO

b)

Round-robin

c)

Optimal replacement

d)

Banker's algorithm