]> git.proxmox.com Git - mirror_qemu.git/commit - cpu-exec.c
tcg: Prepare TB invalidation for lockless TB lookup
authorPaolo Bonzini <pbonzini@redhat.com>
Tue, 19 Jul 2016 06:36:18 +0000 (08:36 +0200)
committerPaolo Bonzini <pbonzini@redhat.com>
Tue, 13 Sep 2016 17:08:43 +0000 (19:08 +0200)
commit6d21e4208f382dd8ca1f7995a6dd9ea7ca281163
tree81569f437586f0525ac788a09826af4e0c8020bb
parent118b07308a8cedc16ef63d7ab243a95f1701db40
tcg: Prepare TB invalidation for lockless TB lookup

When invalidating a translation block, set an invalid flag into the
TranslationBlock structure first.  It is also necessary to check whether
the target TB is still valid after acquiring 'tb_lock' but before calling
tb_add_jump() since TB lookup is to be performed out of 'tb_lock' in
future. Note that we don't have to check 'last_tb'; an already invalidated
TB will not be executed anyway and it is thus safe to patch it.

Suggested-by: Sergey Fedorov <serge.fdrv@gmail.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
cpu-exec.c
include/exec/exec-all.h
translate-all.c