4 ms·
It depends on how much of a program actually triggers the failure case, so you can't answer in the abstract. In the worst case, ~every memory access causes the
by dwattttt 1y ago
It depends on how much of a program actually triggers the failure case, so you can't answer in the abstract.
In the worst case, ~every memory access causes the kernel to need to fix it, causing every memory access to be several orders of magnitude worse (e.g. a hot cache hit vs trapping into kernel, wiping caches, at the very least hundreds more accesses).
EDIT: I see you suggested remapping the page permissions. Maybe that helps! But maybe it adds the cost of the remapping onto the worst case, e.g. the first 4kb are instructions that write into the second 4kb.