0
13kviews
Which of the following instructions should be privileged?

Which of the following instructions should be privileged?

a. Set the value of the timer.

b. Read the clock.

c. Clear memory.

d. Issue a trap instruction.

e. Turn off interrupts.

f. Modify entries in the device-status table.

g. Switch from user to kernel mode.

h. Access I/O device.

1 Answer
3
3.6kviews

Before classifying the below instructions need to take a look at what are privileged instructions and what are non-privileged instructions so that classifying the below instructions would be easy.

Privileged Instructions

These instructions run only in the kernel mode of the operating system. To perform correct operations, the operating system runs these types of instructions. If privileged instructions are tried to run in user mode then it will not be executed and show as illegal instruction.

a. Set the value of the timer

c. Clear memory

e. Turn off interrupts

f. Modify entries in the device-status table

g. Switch from user to kernel mode

h. Access I/O device

Non Privileged Instructions

These instructions run only in the user mode of the operating system. Non-privileged instructions that do not create any interrupts are also used when changing the mode from privileged to non-privileged is required.

b. Read the clock

d. Issue a trap instruction

Please log in to add an answer.