qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v4 36/48] target/loongarch: Implement xvbitclr xvbitset xvbit


From: Richard Henderson
Subject: Re: [PATCH v4 36/48] target/loongarch: Implement xvbitclr xvbitset xvbitrev
Date: Wed, 30 Aug 2023 16:30:07 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.13.0

On 8/30/23 01:48, Song Gao wrote:
This patch includes:
- XVBITCLR[I].{B/H/W/D};
- XVBITSET[I].{B/H/W/D};
- XVBITREV[I].{B/H/W/D}.

Signed-off-by: Song Gao<gaosong@loongson.cn>
---
  target/loongarch/vec.h                       |  4 ++
  target/loongarch/insns.decode                | 27 +++++++++++
  target/loongarch/disas.c                     | 25 ++++++++++
  target/loongarch/vec_helper.c                | 48 ++++++++++----------
  target/loongarch/insn_trans/trans_lasx.c.inc | 27 +++++++++++
  5 files changed, 106 insertions(+), 25 deletions(-)

diff --git a/target/loongarch/vec.h b/target/loongarch/vec.h
index 4497cd4a6d..aae70f9de9 100644
--- a/target/loongarch/vec.h
+++ b/target/loongarch/vec.h
@@ -85,4 +85,8 @@
  #define DO_CLZ_W(N)  (clz32(N))
  #define DO_CLZ_D(N)  (clz64(N))
+#define DO_BITCLR(a, bit) (a & ~(1ull << bit))
+#define DO_BITSET(a, bit) (a | 1ull << bit)
+#define DO_BITREV(a, bit) (a ^ (1ull << bit))
+


Aside from this movement,

Reviewed-by: Richard Henderson <richard.henderson@linaro.org>


r~



reply via email to

[Prev in Thread] Current Thread [Next in Thread]