switch_mm() is probably very cheap (reloads cr3), but it does dirty the
current cpu's tlb. When the kernel needs to flush a process' tlb, it
will have to IPI that cpu in addition to all others. This takes place,
for example, after munmap() or after a page is swapped out (though
significant batching is done there).
It's still plenty cheaper in my estimation.
--
I have a truly marvellous patch that fixes the bug which this
signature is too narrow to contain.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html