Problem: Consider the following code for programmed I/O and…
Question Answered step-by-step Problem: Consider the following code for programmed I/O and… Problem:Consider the following code for programmed I/O and interrupt-driven I/O. Assume that the printer can process 500 characters per second and the overhead associated with handling each interrupt is 2 microseconds. Calculate the CPU overhead in programmed I/O and interrupt-driven I/O. CPU overhead is defined as the ratio of CPU time spent on printing over the total time. Assume a hypothetical device that incurs 20% CPU overhead in interrupt-driven I/O. Calculate the printing rate (i.e., characters per second) of this device. Show your work.1. Programmed I/Ocopy_from_user (buffer, p, count);for (i=0; i


