All of lore.kernel.org
 help / color / mirror / Atom feed
From: Song Gao <gaosong@loongson.cn>
To: qemu-devel@nongnu.org
Cc: richard.henderson@linaro.org, laurent@vivier.eu
Subject: [PATCH v12 00/26] Add LoongArch linux-user emulation support
Date: Wed,  1 Dec 2021 16:15:59 +0800	[thread overview]
Message-ID: <1638346585-3436-1-git-send-email-gaosong@loongson.cn> (raw)

Based-on: https://patchew.org/QEMU/1637893388-10282-1-git-send-email-gaosong@loongson.cn/

Hi all,

This series only support linux-user emulation.
More about LoongArch at: https://github.com/loongson/

The latest kernel:
  * https://github.com/loongson/linux/tree/loongarch-next

Patches need review:
  * 0016-target-loongarch-Add-disassembler.patch
  * 0018-linux-user-Add-LoongArch-specific-structures.patch
  * 0019-linux-user-Add-LoongArch-signal-support.patch

Changes for v12:
  * Clean up code.

Changes for v11:
  * Clean up insns.decode.

Changes for v10:
  * Delete format_insn(), use output_XXX.

Changes for v9:
  * Use GPL-2.0+ SPDX license identifier.
  * Move set_loongarch_cpucfg() in loongarch_3a5000_initfn().
  * target/loongarch/insn_trans/trans_xxx.c rename to
    target/loongarch/insn_trans/trans_xxx.c.inc.
  * Split host_signal_pc and host_signal_write out of user-exec.c.

Changes for v8:
  * Use the FIELD functions to define cpucfg[i].
  * Re-use the decodetree to disassembler description.
  * Split v7 patch(0017-LoongArch-Linux-User-Emulation.patch).

Changes for v7:
  * scripts/gensyscalls.sh support loongarch64
    if we use gensyscalls.sh, we need disable __BITS_PER_LONG at arch/loongarch/include/uapi/asm/bitsperlong.h

V11:
https://patchew.org/QEMU/1637302410-24632-1-git-send-email-gaosong@loongson.cn/

Please review!

Thanks.


Song Gao (26):
  target/loongarch: Add README
  target/loongarch: Add core definition
  target/loongarch: Add main translation routines
  target/loongarch: Add fixed point arithmetic instruction translation
  target/loongarch: Add fixed point shift instruction translation
  target/loongarch: Add fixed point bit instruction translation
  target/loongarch: Add fixed point load/store instruction translation
  target/loongarch: Add fixed point atomic instruction translation
  target/loongarch: Add fixed point extra instruction translation
  target/loongarch: Add floating point arithmetic instruction
    translation
  target/loongarch: Add floating point comparison instruction
    translation
  target/loongarch: Add floating point conversion instruction
    translation
  target/loongarch: Add floating point move instruction translation
  target/loongarch: Add floating point load/store instruction
    translation
  target/loongarch: Add branch instruction translation
  target/loongarch: Add disassembler
  linux-user: Add LoongArch generic header files
  linux-user: Add LoongArch specific structures
  linux-user: Add LoongArch signal support
  linux-user: Add LoongArch elf support
  linux-user: Add LoongArch syscall support
  linux-user: Add LoongArch cpu_loop support
  default-configs: Add loongarch linux-user support
  target/loongarch: Add target build suport
  target/loongarch: 'make check-tcg' support
  scripts: add loongarch64 binfmt config

 MAINTAINERS                                     |   5 +
 configs/targets/loongarch64-linux-user.mak      |   3 +
 configure                                       |   5 +
 include/disas/dis-asm.h                         |   2 +
 include/elf.h                                   |   2 +
 linux-user/elfload.c                            |  58 ++
 linux-user/loongarch64/cpu_loop.c               |  94 +++
 linux-user/loongarch64/signal.c                 | 198 ++++++
 linux-user/loongarch64/sockbits.h               |  11 +
 linux-user/loongarch64/syscall_nr.h             | 313 +++++++++
 linux-user/loongarch64/target_cpu.h             |  34 +
 linux-user/loongarch64/target_elf.h             |  12 +
 linux-user/loongarch64/target_errno_defs.h      |  12 +
 linux-user/loongarch64/target_fcntl.h           |  11 +
 linux-user/loongarch64/target_signal.h          |  13 +
 linux-user/loongarch64/target_structs.h         |  47 ++
 linux-user/loongarch64/target_syscall.h         |  44 ++
 linux-user/loongarch64/termbits.h               |  11 +
 linux-user/syscall_defs.h                       |  10 +-
 meson.build                                     |   3 +-
 scripts/gensyscalls.sh                          |   1 +
 scripts/qemu-binfmt-conf.sh                     |   6 +-
 target/loongarch/README                         |  76 +++
 target/loongarch/cpu-param.h                    |  18 +
 target/loongarch/cpu.c                          | 314 +++++++++
 target/loongarch/cpu.h                          | 252 +++++++
 target/loongarch/disas.c                        | 612 +++++++++++++++++
 target/loongarch/fpu_helper.c                   | 862 ++++++++++++++++++++++++
 target/loongarch/helper.h                       |  94 +++
 target/loongarch/insn_trans/trans_arith.c.inc   | 304 +++++++++
 target/loongarch/insn_trans/trans_atomic.c.inc  | 136 ++++
 target/loongarch/insn_trans/trans_bit.c.inc     | 211 ++++++
 target/loongarch/insn_trans/trans_branch.c.inc  |  83 +++
 target/loongarch/insn_trans/trans_extra.c.inc   |  86 +++
 target/loongarch/insn_trans/trans_farith.c.inc  | 105 +++
 target/loongarch/insn_trans/trans_fcmp.c.inc    |  56 ++
 target/loongarch/insn_trans/trans_fcnv.c.inc    |  33 +
 target/loongarch/insn_trans/trans_fmemory.c.inc | 153 +++++
 target/loongarch/insn_trans/trans_fmov.c.inc    | 157 +++++
 target/loongarch/insn_trans/trans_memory.c.inc  | 229 +++++++
 target/loongarch/insn_trans/trans_shift.c.inc   | 106 +++
 target/loongarch/insns.decode                   | 442 ++++++++++++
 target/loongarch/internals.h                    |  28 +
 target/loongarch/meson.build                    |  19 +
 target/loongarch/op_helper.c                    |  86 +++
 target/loongarch/translate.c                    | 268 ++++++++
 target/loongarch/translate.h                    |  45 ++
 target/meson.build                              |   1 +
 tests/tcg/configure.sh                          |   1 +
 49 files changed, 5666 insertions(+), 6 deletions(-)
 create mode 100644 configs/targets/loongarch64-linux-user.mak
 create mode 100644 linux-user/loongarch64/cpu_loop.c
 create mode 100644 linux-user/loongarch64/signal.c
 create mode 100644 linux-user/loongarch64/sockbits.h
 create mode 100644 linux-user/loongarch64/syscall_nr.h
 create mode 100644 linux-user/loongarch64/target_cpu.h
 create mode 100644 linux-user/loongarch64/target_elf.h
 create mode 100644 linux-user/loongarch64/target_errno_defs.h
 create mode 100644 linux-user/loongarch64/target_fcntl.h
 create mode 100644 linux-user/loongarch64/target_signal.h
 create mode 100644 linux-user/loongarch64/target_structs.h
 create mode 100644 linux-user/loongarch64/target_syscall.h
 create mode 100644 linux-user/loongarch64/termbits.h
 create mode 100644 target/loongarch/README
 create mode 100644 target/loongarch/cpu-param.h
 create mode 100644 target/loongarch/cpu.c
 create mode 100644 target/loongarch/cpu.h
 create mode 100644 target/loongarch/disas.c
 create mode 100644 target/loongarch/fpu_helper.c
 create mode 100644 target/loongarch/helper.h
 create mode 100644 target/loongarch/insn_trans/trans_arith.c.inc
 create mode 100644 target/loongarch/insn_trans/trans_atomic.c.inc
 create mode 100644 target/loongarch/insn_trans/trans_bit.c.inc
 create mode 100644 target/loongarch/insn_trans/trans_branch.c.inc
 create mode 100644 target/loongarch/insn_trans/trans_extra.c.inc
 create mode 100644 target/loongarch/insn_trans/trans_farith.c.inc
 create mode 100644 target/loongarch/insn_trans/trans_fcmp.c.inc
 create mode 100644 target/loongarch/insn_trans/trans_fcnv.c.inc
 create mode 100644 target/loongarch/insn_trans/trans_fmemory.c.inc
 create mode 100644 target/loongarch/insn_trans/trans_fmov.c.inc
 create mode 100644 target/loongarch/insn_trans/trans_memory.c.inc
 create mode 100644 target/loongarch/insn_trans/trans_shift.c.inc
 create mode 100644 target/loongarch/insns.decode
 create mode 100644 target/loongarch/internals.h
 create mode 100644 target/loongarch/meson.build
 create mode 100644 target/loongarch/op_helper.c
 create mode 100644 target/loongarch/translate.c
 create mode 100644 target/loongarch/translate.h

-- 
1.8.3.1



             reply	other threads:[~2021-12-01  8:18 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-12-01  8:15 Song Gao [this message]
2021-12-01  8:16 ` [PATCH v12 01/26] target/loongarch: Add README Song Gao
2021-12-01  8:16 ` [PATCH v12 02/26] target/loongarch: Add core definition Song Gao
2021-12-01  8:16 ` [PATCH v12 03/26] target/loongarch: Add main translation routines Song Gao
2021-12-01  8:16 ` [PATCH v12 04/26] target/loongarch: Add fixed point arithmetic instruction translation Song Gao
2021-12-01  8:16 ` [PATCH v12 05/26] target/loongarch: Add fixed point shift " Song Gao
2021-12-01  8:16 ` [PATCH v12 06/26] target/loongarch: Add fixed point bit " Song Gao
2021-12-01  8:16 ` [PATCH v12 07/26] target/loongarch: Add fixed point load/store " Song Gao
2021-12-01  8:16 ` [PATCH v12 08/26] target/loongarch: Add fixed point atomic " Song Gao
2021-12-01 21:22   ` Richard Henderson
2021-12-01  8:16 ` [PATCH v12 09/26] target/loongarch: Add fixed point extra " Song Gao
2021-12-01  8:16 ` [PATCH v12 10/26] target/loongarch: Add floating point arithmetic " Song Gao
2021-12-01  8:16 ` [PATCH v12 11/26] target/loongarch: Add floating point comparison " Song Gao
2021-12-01  8:16 ` [PATCH v12 12/26] target/loongarch: Add floating point conversion " Song Gao
2021-12-01  8:16 ` [PATCH v12 13/26] target/loongarch: Add floating point move " Song Gao
2021-12-01  8:16 ` [PATCH v12 14/26] target/loongarch: Add floating point load/store " Song Gao
2021-12-01  8:16 ` [PATCH v12 15/26] target/loongarch: Add branch " Song Gao
2021-12-01  8:16 ` [PATCH v12 16/26] target/loongarch: Add disassembler Song Gao
2021-12-01 21:28   ` Richard Henderson
2021-12-01  8:16 ` [PATCH v12 17/26] linux-user: Add LoongArch generic header files Song Gao
2021-12-01  8:16 ` [PATCH v12 18/26] linux-user: Add LoongArch specific structures Song Gao
2021-12-01  8:16 ` [PATCH v12 19/26] linux-user: Add LoongArch signal support Song Gao
2021-12-01  8:16 ` [PATCH v12 20/26] linux-user: Add LoongArch elf support Song Gao
2021-12-01  8:16 ` [PATCH v12 21/26] linux-user: Add LoongArch syscall support Song Gao
2021-12-01  8:16 ` [PATCH v12 22/26] linux-user: Add LoongArch cpu_loop support Song Gao
2021-12-01  8:16 ` [PATCH v12 23/26] default-configs: Add loongarch linux-user support Song Gao
2021-12-01  8:16 ` [PATCH v12 24/26] target/loongarch: Add target build suport Song Gao
2021-12-01  8:16 ` [PATCH v12 25/26] target/loongarch: 'make check-tcg' support Song Gao
2021-12-01  8:16 ` [PATCH v12 26/26] scripts: add loongarch64 binfmt config Song Gao

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1638346585-3436-1-git-send-email-gaosong@loongson.cn \
    --to=gaosong@loongson.cn \
    --cc=laurent@vivier.eu \
    --cc=qemu-devel@nongnu.org \
    --cc=richard.henderson@linaro.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.