Am 10.05.2013 16:46, schrieb Aurelien Jarno: > We have changed a pointer access in a hot path (and more are likely to > come as far as I know) to a complex function. The correct way to fix > that is to remove the complex function.
FWIW I had started to investigate whether I can tweak TCG to use CPUFooState for its offset calculations as-is but to call helpers with FooCPU to get code in a uniform shape, not constantly coding casts as first thing in helper functions. We'd need a pointer similar to CPUState::env_ptr in the back part of CPU_COMMON, make FooCPU available as ArchCPU define and tweak the helper templates to support cpu type argument in addition to env. So far just an idea. Andreas -- SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer; HRB 16746 AG Nürnberg