Messages in this thread | | | Date | Sat, 21 Nov 2009 20:46:53 -0500 | From | Mathieu Desnoyers <> | Subject | Re: [RFC PATCH 2/6] jump label v3 - x86: Introduce generic jump patching without stop_machine |
| |
* Masami Hiramatsu (mhiramat@redhat.com) wrote: > Mathieu Desnoyers wrote: > > We should really do performance benchmarks comparing stop_machine() and > > the int3-based approach rather than to try to come up with tricky > > schemes. It's not a real problem until we prove there is indeed a > > performance regression. I suspect that the combined effect of cache-line > > bouncing, worker thread overhead and the IPI of stop_machine is probably > > comparable to the two IPIs we propose for int3. > > I assume that total latency of XMC is almost same on normal-size SMP. > However, > - stop_machine() can't support NMI/SMI. > - stop_machine() stops all other processors while XMC.
I would also add that stop_machine() increases the system interrupt latency of an amount O(num_online_cpus()), which I'd like to avoid given the 90- to 128-core machines heading our way pretty quickly.
> > Anyway, int3-based approach still needs to be ensured its safeness > by processor architects. So, until that, stop_machine() approach > also useful for some cases.
True. This makes me think: If performance happens to be a problem, we could do batched jump instruction modification. Using an hash table to contain the pointers would allow us to only perform a single pair of IPI for a whole bunch of instruction modifications.
Mathieu
> > Thank you,
-- Mathieu Desnoyers OpenPGP key fingerprint: 8CD5 52C3 8E3C 4140 715F BA06 3F25 A8FE 3BAE 9A68
| |