0 votes 0 votes when the interrupt occurs ,then a: process switching may be there b: context saving must be there c: both a and b d.None of these Operating System operating-system interrupts process-scheduling + – rahul sharma 5 asked Dec 7, 2017 rahul sharma 5 1.7k views answer comment Share Follow See all 4 Comments See all 4 4 Comments reply Ashwin Kulkarni commented Dec 8, 2017 reply Follow Share Answer should be C?? Because wehn interrupt occurs first CPU will save ongoing process's context, and then switch to interrupt process, 0 votes 0 votes Red_devil commented Dec 8, 2017 reply Follow Share @ Ashwin Kulkarni is it possible to have an interrupt request for thread switching?? 0 votes 0 votes hs_yadav commented Dec 8, 2017 reply Follow Share Red_devil thread of different process required context switching but for same process threads need not request for interrupt... bcoz threads for a single process run concurrently (parallel)....??? 0 votes 0 votes Red_devil commented Dec 8, 2017 reply Follow Share @hs_yadav "A context switch (also sometimes referred to as a process switch or a task switch) is the switching of the CPU (central processing unit) from one process or thread to another." ...so both thread and process have context switch time. 0 votes 0 votes Please log in or register to add a comment.
0 votes 0 votes It must be C right? Because, the CPU will save the context of current executing process by saving the register values (b) and then jump to the execution of the Interrupt Service Routine for that interrupt (a). gauravkc answered Dec 7, 2017 gauravkc comment Share Follow See all 4 Comments See all 4 4 Comments reply rahul sharma 5 commented Dec 7, 2017 reply Follow Share Process switching my be there as it can stop current process and goto the interrupt process.But if that is a low priority interrupt,then will it always jump? First statement has "MAY" but second has "MUST". 0 votes 0 votes gauravkc commented Dec 7, 2017 reply Follow Share For maskable interrupts, it won't. For non-maskable it'll. That's why it's "may". The statement is true though. 0 votes 0 votes rahul sharma 5 commented Dec 8, 2017 reply Follow Share But context saving is always? 0 votes 0 votes gauravkc commented Dec 8, 2017 reply Follow Share I got this context saving doubt and I researched a lot. A possible explanation I found is when there is maskable interrupt, the CPU gives acknowledgment and requests for the address of the service routine. Even to do this task, it has to save the context. However, priority for such interrupt is not that high that it'll stop current process execution. I found no article that explicitly says this but I can conclude this from what I read. 0 votes 0 votes Please log in or register to add a comment.