qemu/qom
Anthony Liguori 035873283b qom: aggressively optimize qom casting
This patch adds a small typename cache to ObjectClass.  This allows
caching positive casts within each ObjectClass.  Benchmarking a
PPC workload provided by Aurelien, this patch eliminates every
single g_hash_table_lookup() happening during the benchmark (which
was about 2 million per-second).

With this patch applied, I get exactly the same performance (within
the margin of error) as with --disable-qom-cast-debug.

N.B. it's safe to cache typenames only from the _assert() macros
because they are always called with string literals.

Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2013-05-13 15:27:18 -05:00
..
container.c Make all static TypeInfos const 2013-01-10 15:11:53 -06:00
cpu.c cpu: Move cpu_write_elfXX_note() functions to CPUState 2013-05-01 13:04:19 +02:00
Makefile.objs build: remove universal-obj-y 2013-01-26 13:15:35 +00:00
object.c qom: aggressively optimize qom casting 2013-05-13 15:27:18 -05:00
qom-qobject.c qom: move include files to include/qom/ 2012-12-19 08:31:32 +01:00