
User mode Vs kernel mode
User mode – Kernel mode User defined functions are executed in user mode and system defined functions are executed in kernel mode. User mode instructions are non atomic(preemption), Non privileged Kernel mode instructions are atomic(without preemption),privileged Process Kernel mode User mode System calls are considered as Supervisory Call and it initiates Software Interrupt to OS. OS starts Interrupt Service Routine User mode functions donot change mode of execution it branches out by saving current address SVC BSA Software Interrupt ISR main() 1. Upon an interrupt OS handles it only after execution of current instruction finished 2. OS always resumes interrupted process after processing interrupt int a,b //Non privileged Instructions Userfunction()// User defined functions are converted to BSA ISR Interrupt Service Routine fork) // System calls are converted to SVC PSW Dispatch table 1 Function name mapped to memory address of code User mode Kernel mode SVC: Supervisory Call ISR: Interrupt Serice Routine PSW: Process Status Word BSA: Branch 8 Save Adress
User mode Vs kernel mode
Publisher
picturelanguageSource
http://pictu...rnel-mode/Category
TechnologyGet a Quote