qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [RFC PATCH v6 0/6] translate: [tcg] Generic translation framework
@ 2017-06-12 14:53 Lluís Vilanova
  2017-06-12 14:53 ` [Qemu-devel] [PATCH v6 1/6] Pass generic CPUState to gen_intermediate_code() Lluís Vilanova
                   ` (5 more replies)
  0 siblings, 6 replies; 34+ messages in thread
From: Lluís Vilanova @ 2017-06-12 14:53 UTC (permalink / raw)
  To: qemu-devel
  Cc: Alex Bennée, Richard Henderson, Peter Crosthwaite,
	Paolo Bonzini

This series proposes a generic (target-agnostic) instruction translation
framework.

It basically provides a generic main loop for instruction disassembly, which
calls target-specific functions when necessary. This generalization makes
inserting new code in the main loop easier, and helps in keeping all targets in
synch as to the contents of it.

This series also paves the way towards adding events to trace guest code
execution (BBLs and instructions).

I've ported i386/x86-64 and arm/aarch64 as an example to see how it fits in the
current organization, but will port the rest when this series gets merged.

Signed-off-by: Lluís Vilanova <vilanova@ac.upc.edu>
---

Changes in v6
=============

* Rebase on upstream master (64175afc69).
* Reorder fields in DisasContextBase to minimize padding [Richard Henderson].


Changes in v5
=============

* Remove stray uses of "restrict" keyword.


Changes in v4
=============

* Document new macro QTAILQ_FOREACH_CONTINUE [Peter Maydell].
* Fix coding style errors reported by checkpatch.
* Remove use of "restrict" in added functions; it makes older gcc versions barf
  about compilation errors.


Changes in v3
=============

* Rebase on 0737f32daf.


Changes in v2
=============

* Port ARM and AARCH64 targets.
* Fold single-stepping checks into "max_insns" [Richard Henderson].
* Move instruction start marks to target code [Richard Henderson].
* Add target hook for TB start.
* Check for TCG temporary leaks.
* Move instruction disassembly into a target hook.
* Make breakpoint_hit() return an enum to accomodate target's needs (ARM).


Lluís Vilanova (6):
      Pass generic CPUState to gen_intermediate_code()
      queue: Add macro for incremental traversal
      target: [tcg] Add generic translation framework
      target: [tcg] Redefine DISAS_* onto the generic translation framework (DJ_*)
      target: [tcg,i386] Port to generic translation framework
      target: [tcg,arm] Port to generic translation framework


 include/exec/exec-all.h               |   13 -
 include/exec/gen-icount.h             |    2 
 include/exec/translate-all_template.h |   73 +++
 include/qemu/queue.h                  |   12 +
 include/qom/cpu.h                     |   22 +
 target/alpha/translate.c              |   11 -
 target/arm/translate-a64.c            |  346 ++++++++--------
 target/arm/translate.c                |  720 +++++++++++++++++----------------
 target/arm/translate.h                |   45 +-
 target/cris/translate.c               |   20 -
 target/i386/translate.c               |  305 ++++++--------
 target/lm32/translate.c               |   22 +
 target/m68k/translate.c               |   18 -
 target/microblaze/translate.c         |   22 +
 target/mips/translate.c               |   15 -
 target/moxie/translate.c              |   14 -
 target/openrisc/translate.c           |   19 -
 target/ppc/translate.c                |   15 -
 target/s390x/translate.c              |   16 -
 target/sh4/translate.c                |   15 -
 target/sparc/translate.c              |   11 -
 target/tilegx/translate.c             |    7 
 target/tricore/translate.c            |    9 
 target/unicore32/translate.c          |   20 -
 target/xtensa/translate.c             |   13 -
 translate-all.c                       |    2 
 translate-all_template.h              |  204 +++++++++
 27 files changed, 1141 insertions(+), 850 deletions(-)
 create mode 100644 include/exec/translate-all_template.h
 create mode 100644 translate-all_template.h


To: qemu-devel@nongnu.org
Cc: Paolo Bonzini <pbonzini@redhat.com>
Cc: Peter Crosthwaite <crosthwaite.peter@gmail.com>
Cc: Richard Henderson <rth@twiddle.net>
Cc: Alex Bennée <alex.bennee@linaro.org>

^ permalink raw reply	[flat|nested] 34+ messages in thread

end of thread, other threads:[~2017-06-27  9:13 UTC | newest]

Thread overview: 34+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-06-12 14:53 [Qemu-devel] [RFC PATCH v6 0/6] translate: [tcg] Generic translation framework Lluís Vilanova
2017-06-12 14:53 ` [Qemu-devel] [PATCH v6 1/6] Pass generic CPUState to gen_intermediate_code() Lluís Vilanova
2017-06-13  1:40   ` David Gibson
2017-06-14 21:35   ` Eduardo Habkost
2017-06-14 22:30   ` Laurent Vivier
2017-06-16 14:07   ` Alex Bennée
2017-06-12 14:54 ` [Qemu-devel] [PATCH v6 2/6] queue: Add macro for incremental traversal Lluís Vilanova
2017-06-19 23:20   ` Richard Henderson
2017-06-26 12:33     ` Lluís Vilanova
2017-06-27  1:10       ` Richard Henderson
2017-06-27  9:13         ` Lluís Vilanova
2017-06-12 14:54 ` [Qemu-devel] [PATCH v6 3/6] target: [tcg] Add generic translation framework Lluís Vilanova
2017-06-15 22:05   ` [Qemu-devel] [PATCH] translator mega-patch Emilio G. Cota
2017-06-18 14:37     ` Lluís Vilanova
2017-06-18 18:26       ` Peter Maydell
2017-06-19  4:08       ` Emilio G. Cota
2017-06-19  7:15         ` Peter Maydell
2017-06-15 22:19   ` [Qemu-devel] [PATCH v6 3/6] target: [tcg] Add generic translation framework Emilio G. Cota
2017-06-15 23:25     ` Emilio G. Cota
2017-06-17  1:09       ` Emilio G. Cota
2017-06-18 14:24         ` Lluís Vilanova
2017-06-18 14:22       ` Lluís Vilanova
2017-06-18 15:47         ` Lluís Vilanova
2017-06-18 21:54           ` Lluís Vilanova
2017-06-19  4:10             ` Emilio G. Cota
2017-06-19  8:37               ` Lluís Vilanova
2017-06-18 14:20     ` Lluís Vilanova
2017-06-12 14:54 ` [Qemu-devel] [PATCH v6 4/6] target: [tcg] Redefine DISAS_* onto the generic translation framework (DJ_*) Lluís Vilanova
2017-06-12 14:54 ` [Qemu-devel] [PATCH v6 6/6] target: [tcg, arm] Port to generic translation framework Lluís Vilanova
2017-06-16  0:18   ` Emilio G. Cota
2017-06-18 14:41     ` Lluís Vilanova
2017-06-19  4:22       ` Emilio G. Cota
2017-06-15 18:02 ` [Qemu-devel] [RFC PATCH v6 0/6] translate: [tcg] Generic " Emilio G. Cota
2017-06-18 14:41   ` Lluís Vilanova

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).