qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v4 00/48] Add LoongArch LASX instructions
@ 2023-08-30  8:48 Song Gao
  2023-08-30  8:48 ` [PATCH v4 01/48] target/loongarch: Add LASX data support Song Gao
                   ` (47 more replies)
  0 siblings, 48 replies; 86+ messages in thread
From: Song Gao @ 2023-08-30  8:48 UTC (permalink / raw)
  To: qemu-devel; +Cc: richard.henderson

Hi,

This series adds LoongArch LASX instructions.

About test:
We use RISU test the LoongArch LASX instructions.

QEMU:
    https://github.com/loongson/qemu/tree/tcg-old-abi-support-lasx
RISU:
    https://github.com/loongson/risu/tree/loongarch-suport-lasx

Please review, Thanks.

Changes for v4:
- Rebase;
- Add avail_LASX to check.

Changes for v3:
- Add a new patch 9, rename lsx_helper.c to vec_helper.c,
  and use gen_helper_gvec_* series functions;
- Use i < oprsz / (BIT / 8) in loop;
- Some helper functions use loop;
- patch 46: use tcg_gen_qemu_ld/st_i64 for xvld/xvst{x};
- R-b.

Changes for v2:
- Expand the definition of VReg to be 256 bits.
- Use more LSX functions.
- R-b.

Song Gao (48):
  target/loongarch: Add LASX data support
  target/loongarch: meson.build support build LASX
  target/loongarch: Add CHECK_ASXE maccro for check LASX enable
  target/loongarch: Add avail_LASX to check LASX instructions
  target/loongarch: Implement xvadd/xvsub
  target/loongarch: Implement xvreplgr2vr
  target/loongarch: Implement xvaddi/xvsubi
  target/loongarch: Implement xvneg
  target/loongarch: Implement xvsadd/xvssub
  target/loongarch: rename lsx_helper.c to vec_helper.c
  target/loongarch: Implement xvhaddw/xvhsubw
  target/loongarch: Implement xvaddw/xvsubw
  target/loongarch: Implement xavg/xvagr
  target/loongarch: Implement xvabsd
  target/loongarch: Implement xvadda
  target/loongarch: Implement xvmax/xvmin
  target/loongarch: Implement xvmul/xvmuh/xvmulw{ev/od}
  target/loongarch: Implement xvmadd/xvmsub/xvmaddw{ev/od}
  target/loongarch; Implement xvdiv/xvmod
  target/loongarch: Implement xvsat
  target/loongarch: Implement xvexth
  target/loongarch: Implement vext2xv
  target/loongarch: Implement xvsigncov
  target/loongarch: Implement xvmskltz/xvmskgez/xvmsknz
  target/loognarch: Implement xvldi
  target/loongarch: Implement LASX logic instructions
  target/loongarch: Implement xvsll xvsrl xvsra xvrotr
  target/loongarch: Implement xvsllwil xvextl
  target/loongarch: Implement xvsrlr xvsrar
  target/loongarch: Implement xvsrln xvsran
  target/loongarch: Implement xvsrlrn xvsrarn
  target/loongarch: Implement xvssrln xvssran
  target/loongarch: Implement xvssrlrn xvssrarn
  target/loongarch: Implement xvclo xvclz
  target/loongarch: Implement xvpcnt
  target/loongarch: Implement xvbitclr xvbitset xvbitrev
  target/loongarch: Implement xvfrstp
  target/loongarch: Implement LASX fpu arith instructions
  target/loongarch: Implement LASX fpu fcvt instructions
  target/loongarch: Implement xvseq xvsle xvslt
  target/loongarch: Implement xvfcmp
  target/loongarch: Implement xvbitsel xvset
  target/loongarch: Implement xvinsgr2vr xvpickve2gr
  target/loongarch: Implement xvreplve xvinsve0 xvpickve xvb{sll/srl}v
  target/loongarch: Implement xvpack xvpick xvilv{l/h}
  target/loongarch: Implement xvshuf xvperm{i} xvshuf4i xvextrins
  target/loongarch: Implement xvld xvst
  target/loongarch: CPUCFG support LASX

 target/loongarch/cpu.h                       |   26 +-
 target/loongarch/helper.h                    |  689 ++--
 target/loongarch/internals.h                 |   22 -
 target/loongarch/translate.h                 |    1 +
 target/loongarch/vec.h                       |   98 +
 target/loongarch/insns.decode                |  782 ++++
 linux-user/loongarch64/signal.c              |    1 +
 target/loongarch/cpu.c                       |    4 +
 target/loongarch/disas.c                     |  925 +++++
 target/loongarch/gdbstub.c                   |    1 +
 target/loongarch/lsx_helper.c                | 3004 ---------------
 target/loongarch/machine.c                   |   36 +-
 target/loongarch/translate.c                 |    5 +
 target/loongarch/vec_helper.c                | 3431 ++++++++++++++++++
 target/loongarch/insn_trans/trans_lasx.c.inc | 1054 ++++++
 target/loongarch/insn_trans/trans_lsx.c.inc  | 2060 ++++++-----
 target/loongarch/meson.build                 |    2 +-
 17 files changed, 7766 insertions(+), 4375 deletions(-)
 create mode 100644 target/loongarch/vec.h
 delete mode 100644 target/loongarch/lsx_helper.c
 create mode 100644 target/loongarch/vec_helper.c
 create mode 100644 target/loongarch/insn_trans/trans_lasx.c.inc

-- 
2.39.1



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

end of thread, other threads:[~2023-08-31 15:07 UTC | newest]

Thread overview: 86+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-08-30  8:48 [PATCH v4 00/48] Add LoongArch LASX instructions Song Gao
2023-08-30  8:48 ` [PATCH v4 01/48] target/loongarch: Add LASX data support Song Gao
2023-08-30  8:48 ` [PATCH v4 02/48] target/loongarch: meson.build support build LASX Song Gao
2023-08-30  8:48 ` [PATCH v4 03/48] target/loongarch: Add CHECK_ASXE maccro for check LASX enable Song Gao
2023-08-30  8:48 ` [PATCH v4 04/48] target/loongarch: Add avail_LASX to check LASX instructions Song Gao
2023-08-30 14:20   ` Richard Henderson
2023-08-30  8:48 ` [PATCH v4 05/48] target/loongarch: Implement xvadd/xvsub Song Gao
2023-08-30 15:38   ` Richard Henderson
2023-08-30  8:48 ` [PATCH v4 06/48] target/loongarch: Implement xvreplgr2vr Song Gao
2023-08-30 16:09   ` Richard Henderson
2023-08-31  7:17     ` gaosong
2023-08-30  8:48 ` [PATCH v4 07/48] target/loongarch: Implement xvaddi/xvsubi Song Gao
2023-08-30  8:48 ` [PATCH v4 08/48] target/loongarch: Implement xvneg Song Gao
2023-08-30  8:48 ` [PATCH v4 09/48] target/loongarch: Implement xvsadd/xvssub Song Gao
2023-08-30  8:48 ` [PATCH v4 10/48] target/loongarch: rename lsx_helper.c to vec_helper.c Song Gao
2023-08-30 18:06   ` Richard Henderson
2023-08-31  7:17     ` gaosong
2023-08-30  8:48 ` [PATCH v4 11/48] target/loongarch: Implement xvhaddw/xvhsubw Song Gao
2023-08-30 18:12   ` Richard Henderson
2023-08-31  7:17     ` gaosong
2023-08-31 15:06       ` Richard Henderson
2023-08-30  8:48 ` [PATCH v4 12/48] target/loongarch: Implement xvaddw/xvsubw Song Gao
2023-08-30  8:48 ` [PATCH v4 13/48] target/loongarch: Implement xavg/xvagr Song Gao
2023-08-30 18:14   ` Richard Henderson
2023-08-30  8:48 ` [PATCH v4 14/48] target/loongarch: Implement xvabsd Song Gao
2023-08-30  8:48 ` [PATCH v4 15/48] target/loongarch: Implement xvadda Song Gao
2023-08-30 20:45   ` Richard Henderson
2023-08-30  8:48 ` [PATCH v4 16/48] target/loongarch: Implement xvmax/xvmin Song Gao
2023-08-30 20:50   ` Richard Henderson
2023-08-30  8:48 ` [PATCH v4 17/48] target/loongarch: Implement xvmul/xvmuh/xvmulw{ev/od} Song Gao
2023-08-30 18:23   ` Richard Henderson
2023-08-30  8:48 ` [PATCH v4 18/48] target/loongarch: Implement xvmadd/xvmsub/xvmaddw{ev/od} Song Gao
2023-08-30 21:05   ` Richard Henderson
2023-08-30  8:48 ` [PATCH v4 19/48] target/loongarch; Implement xvdiv/xvmod Song Gao
2023-08-30 22:14   ` Richard Henderson
2023-08-30  8:48 ` [PATCH v4 20/48] target/loongarch: Implement xvsat Song Gao
2023-08-30 22:19   ` Richard Henderson
2023-08-30  8:48 ` [PATCH v4 21/48] target/loongarch: Implement xvexth Song Gao
2023-08-30 22:34   ` Richard Henderson
2023-08-30  8:48 ` [PATCH v4 22/48] target/loongarch: Implement vext2xv Song Gao
2023-08-30 22:36   ` Richard Henderson
2023-08-30  8:48 ` [PATCH v4 23/48] target/loongarch: Implement xvsigncov Song Gao
2023-08-30  8:48 ` [PATCH v4 24/48] target/loongarch: Implement xvmskltz/xvmskgez/xvmsknz Song Gao
2023-08-30 22:44   ` Richard Henderson
2023-08-30  8:48 ` [PATCH v4 25/48] target/loognarch: Implement xvldi Song Gao
2023-08-30  8:48 ` [PATCH v4 26/48] target/loongarch: Implement LASX logic instructions Song Gao
2023-08-30 22:46   ` Richard Henderson
2023-08-30  8:48 ` [PATCH v4 27/48] target/loongarch: Implement xvsll xvsrl xvsra xvrotr Song Gao
2023-08-30  8:48 ` [PATCH v4 28/48] target/loongarch: Implement xvsllwil xvextl Song Gao
2023-08-30 22:52   ` Richard Henderson
2023-08-30  8:48 ` [PATCH v4 29/48] target/loongarch: Implement xvsrlr xvsrar Song Gao
2023-08-30 22:54   ` Richard Henderson
2023-08-30  8:48 ` [PATCH v4 30/48] target/loongarch: Implement xvsrln xvsran Song Gao
2023-08-30 22:57   ` Richard Henderson
2023-08-30  8:48 ` [PATCH v4 31/48] target/loongarch: Implement xvsrlrn xvsrarn Song Gao
2023-08-30 23:00   ` Richard Henderson
2023-08-30  8:48 ` [PATCH v4 32/48] target/loongarch: Implement xvssrln xvssran Song Gao
2023-08-30 23:22   ` Richard Henderson
2023-08-30  8:48 ` [PATCH v4 33/48] target/loongarch: Implement xvssrlrn xvssrarn Song Gao
2023-08-30 23:26   ` Richard Henderson
2023-08-30  8:48 ` [PATCH v4 34/48] target/loongarch: Implement xvclo xvclz Song Gao
2023-08-30 23:27   ` Richard Henderson
2023-08-30  8:48 ` [PATCH v4 35/48] target/loongarch: Implement xvpcnt Song Gao
2023-08-30 23:28   ` Richard Henderson
2023-08-30  8:48 ` [PATCH v4 36/48] target/loongarch: Implement xvbitclr xvbitset xvbitrev Song Gao
2023-08-30 23:30   ` Richard Henderson
2023-08-30  8:48 ` [PATCH v4 37/48] target/loongarch: Implement xvfrstp Song Gao
2023-08-30 23:34   ` Richard Henderson
2023-08-30  8:48 ` [PATCH v4 38/48] target/loongarch: Implement LASX fpu arith instructions Song Gao
2023-08-30 23:37   ` Richard Henderson
2023-08-30  8:48 ` [PATCH v4 39/48] target/loongarch: Implement LASX fpu fcvt instructions Song Gao
2023-08-30 23:40   ` Richard Henderson
2023-08-30  8:48 ` [PATCH v4 40/48] target/loongarch: Implement xvseq xvsle xvslt Song Gao
2023-08-30 23:41   ` Richard Henderson
2023-08-30  8:48 ` [PATCH v4 41/48] target/loongarch: Implement xvfcmp Song Gao
2023-08-31  0:30   ` Richard Henderson
2023-08-30  8:48 ` [PATCH v4 42/48] target/loongarch: Implement xvbitsel xvset Song Gao
2023-08-31  0:32   ` Richard Henderson
2023-08-30  8:48 ` [PATCH v4 43/48] target/loongarch: Implement xvinsgr2vr xvpickve2gr Song Gao
2023-08-30  8:48 ` [PATCH v4 44/48] target/loongarch: Implement xvreplve xvinsve0 xvpickve xvb{sll/srl}v Song Gao
2023-08-30  8:48 ` [PATCH v4 45/48] target/loongarch: Implement xvpack xvpick xvilv{l/h} Song Gao
2023-08-31  0:35   ` Richard Henderson
2023-08-30  8:49 ` [PATCH v4 46/48] target/loongarch: Implement xvshuf xvperm{i} xvshuf4i xvextrins Song Gao
2023-08-30  8:49 ` [PATCH v4 47/48] target/loongarch: Implement xvld xvst Song Gao
2023-08-30  8:49 ` [PATCH v4 48/48] target/loongarch: CPUCFG support LASX Song Gao
2023-08-31  0:38   ` Richard Henderson

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).