On 27/6/25 02:04, Aleksandar Rakic wrote:
From: Aleksandar Rakic <aleksandar.ra...@htecgroup.com>

Add emulation of MIPS' CRC32 (Cyclic Redundancy Check) instructions.
Reuse zlib crc32() and Linux crc32c().

Enable CRC for mips64r6.

Signed-off-by: Yongbok Kim <yongbok....@mips.com>
Signed-off-by: Aleksandar Markovic <amarko...@wavecomp.com>
Signed-off-by: Aleksandar Rakic <aleksandar.ra...@htecgroup.com>
Reviewed-by: Aleksandar Rikalo <arik...@gmail.com>
---
  target/mips/cpu-defs.c.inc                    |  10 +-
  target/mips/helper.h                          |   2 +
  target/mips/meson.build                       |   1 +
  target/mips/tcg/op_helper.c                   |  27 ++++
  target/mips/tcg/rel6.decode                   |   5 +
  target/mips/tcg/rel6_translate.c              |  13 ++
  target/mips/tcg/translate.c                   |  25 +++
  target/mips/tcg/translate.h                   |   2 +

  tests/tcg/mips/include/wrappers_mips64r6.h    |  35 +++++
  tests/tcg/mips/user/isa/mips64r6/crc/Makefile |  42 ++++++
  .../isa/mips64r6/crc/test_mips64r6_crc32b.c   | 142 ++++++++++++++++++
  .../isa/mips64r6/crc/test_mips64r6_crc32cb.c  | 142 ++++++++++++++++++
  .../isa/mips64r6/crc/test_mips64r6_crc32cd.c  | 142 ++++++++++++++++++
  .../isa/mips64r6/crc/test_mips64r6_crc32ch.c  | 142 ++++++++++++++++++
  .../isa/mips64r6/crc/test_mips64r6_crc32cw.c  | 142 ++++++++++++++++++
  .../isa/mips64r6/crc/test_mips64r6_crc32d.c   | 142 ++++++++++++++++++
  .../isa/mips64r6/crc/test_mips64r6_crc32h.c   | 142 ++++++++++++++++++
  .../isa/mips64r6/crc/test_mips64r6_crc32w.c   | 142 ++++++++++++++++++
  18 files changed, 1294 insertions(+), 4 deletions(-)

Thanks, patch queued (as 2 patches, tests added on top) fixing style
issues reported by checkpatch.pl.

Reply via email to