CS FundamentalsModerateGATE CS · Amazon/Microsoft SDE MCQ

Which statement about a system call compared with an ordinary function call is correct?

  1. A. Both run in user mode, but a system call switches to a separate stack
  2. B. A system call needs no saving of registers, since the kernel has its own set
  3. C. A system call is just a jump into the C library, with no mode change
  4. D. A system call traps into kernel mode, so it costs far more

Correct answer: D. A system call traps into kernel mode, so it costs far more

The trap (e.g. syscall/int) switches to kernel mode, saves user state, dispatches through the system-call table and returns with a mode switch back. Library wrappers like read() exist, but they still execute the trapping instruction.

More Operating Systems questions

Exams that ask this topic