Which of the following statement(s) is/are correct for context switching in…

2024

Which of the following statement(s) is/are correct for context switching in Operating System? I. When a context switch occurs, the kernel saves the context of the old process in its PCB (Process Control Block). II. Context-Switch time is pure overhead, because the system does no useful work while switching.

Answer: D. Both I and IIDuring a context switch, the kernel saves the old process context in its PCB. The switch consumes CPU time without doing user-process work, so context-switch…

  1. A.

    Neither I nor II

  2. B.

    Only I

  3. C.

    Only II

  4. D.

    Both I and II

Attempted by 813 students.

Show answer & explanation

Correct answer: D

During a context switch, the kernel saves the old process context in its PCB. The switch consumes CPU time without doing user-process work, so context-switch time is overhead.

A video solution is available for this question — log in and enroll to watch it.

Explore the full course: Rssb Basic Computer Instructor

Loading lesson…