2,208 views
1 votes
1 votes
A privileged instruction may be executed only while the hardware is in kernel mode. Which of the following is LEAST likely to be a privileged instruction?
(A) An instruction that changes the value of the program counter
(B) An instruction that sends output to a printer
(C) An instruction that halts the CPU
(D) An instruction that resets the computer’s time­of­day clock

1 Answer

0 votes
0 votes

A privileged instruction can only be (not may be) invoked when the hardware is running in privileged (a.k.a. kernel) mode. And System entered in kernel mode only by making system calls( system call are not made under kernal mode but in user mode). Now let us consider each option one by one.

  • A) For changing the program counter, neither hardware access nor any system call is generated.
  • B) For sending output to a printer, access to printer hardware is required.
  • C) In this case also, access to memory hardware is required.
  • D) For creating a process, CPU needs to invoke a system call called as "fork", which is possible in kernel mode.

Thus, option A is least likely to be a privileged instruction.

edited by

Related questions

1 votes
1 votes
0 answers
1
cse23 asked Oct 13, 2016
258 views
A max heap with 100 elements is stored in an array. What is the maximum possible index number for 9th min element?A) 254B) 100C) 9D) 511
0 votes
0 votes
0 answers
3
0 votes
0 votes
0 answers
4
kallu singh asked Sep 18, 2018
282 views
24. Consider the following instructions.I 1 : R 1 = 100I 2 : R 1 = R 2 + R 4I 3 : R 2 = R 4 + 25I 4 : R 4 = R 1 + R 313I 5 : R 1 = R 1 + 30Calculate sum of (WAR, RAW and ...