[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH 00/22] tcg: tb_lock removal
From: |
Emilio G. Cota |
Subject: |
[Qemu-devel] [PATCH 00/22] tcg: tb_lock removal |
Date: |
Mon, 7 Aug 2017 19:52:16 -0400 |
This series applies on top of the "multiple TCG contexts" series, v4:
https://lists.gnu.org/archive/html/qemu-devel/2017-07/msg06769.html
Highlights:
- First, fix a few typos I encountered while working on this (patches 1-3).
I could send them separately to qemu-trivial if you prefer.
- QHT: use a proper cmp function, instead of just checking pointer values
to determine equality of matches.
- Use a binary search tree for each TCG region.
- Make l1_map lockless by using cmpxchg
- Introduce page locks (for !user-mode), so that tb_lock is not
needed when operating on a page
- Introduce page_collection, to lock a range of pages
- Introduce tb->jmp_lock to protect TB jump lists.
- Remove tb_lock. User-mode uses just mmap_lock and tb->jmp_lock's;
!user-mode uses the same jump locks as well as page locks.
Performance numbers are in patch 22. We get nice speedups, but I still
see a lot of idling when booting many cores. I suspect it comes from
cross-CPU events (e.g. TLB invalidations), but I need to profile it
better (perf is not good for this; mutrace doesn't quite work). But
anyway that's for another patchset.
You can fetch these changes from:
https://github.com/cota/qemu/tree/multi-tcg-v4-parallel
Please review!
Thanks,
Emilio
diffstat:
accel/tcg/cpu-exec.c | 58 +-
accel/tcg/cputlb.c | 8 -
accel/tcg/translate-all.c | 958 +++++++++++++++--------
accel/tcg/translate-all.h | 6 +-
disas/arm.c | 2 +-
docs/devel/multi-thread-tcg.txt | 21 +-
exec.c | 25 +-
include/exec/cpu-common.h | 1 -
include/exec/exec-all.h | 86 +-
include/exec/tb-context.h | 4 -
include/qemu/qht.h | 36 +-
linux-user/main.c | 3 -
linux-user/syscall.c | 2 +-
tcg/tcg.c | 205 +++++
tcg/tcg.h | 13 +-
tests/qht-bench.c | 18 +-
tests/test-qht.c | 20 +-
util/qht.c | 30 +-
18 files changed, 1022 insertions(+), 474 deletions(-)
- [Qemu-devel] [PATCH 00/22] tcg: tb_lock removal,
Emilio G. Cota <=
- [Qemu-devel] [PATCH 02/22] linux-user: fix 'finshed' typo in comment, Emilio G. Cota, 2017/08/07
- [Qemu-devel] [PATCH 03/22] translate-all: fix 'consisits' typo in comment, Emilio G. Cota, 2017/08/07
- [Qemu-devel] [PATCH 09/22] translate-all: introduce iterator macros for tagged TB lists, Emilio G. Cota, 2017/08/07
- [Qemu-devel] [PATCH 01/22] disas/arm: fix 'instuction' typo in comment, Emilio G. Cota, 2017/08/07
- [Qemu-devel] [PATCH 04/22] qht: fix kernel-doc markup in qht.h, Emilio G. Cota, 2017/08/07
- [Qemu-devel] [PATCH 11/22] translate-all: exit from tb_phys_invalidate if qht_remove fails, Emilio G. Cota, 2017/08/07
- [Qemu-devel] [PATCH 08/22] tcg: move tb_ctx.tb_phys_invalidate_count to tcg_ctx, Emilio G. Cota, 2017/08/07
- [Qemu-devel] [PATCH 13/22] translate-all: remove hole in PageDesc, Emilio G. Cota, 2017/08/07
- [Qemu-devel] [PATCH 12/22] translate-all: make l1_map lockless, Emilio G. Cota, 2017/08/07
- [Qemu-devel] [PATCH 05/22] qht: require a default comparison function, Emilio G. Cota, 2017/08/07