On 10/16/2011 05:41 PM, Michael Lotz wrote:
A rather simple optimization to the interrupt handler that could be done however, would be to reorder the installed interrupt handler list so that handlers who service the most interrupts end up at the top of the list (this only applies where multiple interrupt handlers are installed of course). This would reduce the average interrupt handling latency by avoiding to call into the handler routine of drivers that only receive interrupts more rarely.
I'm not sure the heuristic is sound, as while you potentially safe a few cycles by ordering them that way, devices that benefit from low latency might not issue the most interrupts. Audio drivers come to mind here, although they probably really should use MSI when possible (certainly with HDA, which should be the most common these days, anyway).
Bye, Axel.