[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH 15/55] bitops.h: Provide hswap32(), hswap64(), wswap64() swap
From: |
Philippe Mathieu-Daudé |
Subject: |
Re: [PATCH 15/55] bitops.h: Provide hswap32(), hswap64(), wswap64() swapping operations |
Date: |
Tue, 8 Jun 2021 08:53:14 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.10.1 |
On 6/7/21 6:57 PM, Peter Maydell wrote:
> Currently the ARM SVE helper code defines locally some utility
> functions for swapping 16-bit halfwords within 32-bit or 64-bit
> values and for swapping 32-bit words within 64-bit values,
> parallel to the byte-swapping bswap16/32/64 functions.
>
> We want these also for the ARM MVE code, and they're potentially
> generally useful for other targets, so move them to bitops.h.
> (We don't put them in bswap.h with the bswap* functions because
> they are implemented in terms of the rotate operations also
> defined in bitops.h, and including bitops.h from bswap.h seems
> better avoided.)
>
> Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
> ---
> include/qemu/bitops.h | 29 +++++++++++++++++++++++++++++
> target/arm/sve_helper.c | 20 --------------------
> 2 files changed, 29 insertions(+), 20 deletions(-)
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
- Re: [PATCH 22/55] target/arm: Implement MVE VADD, VSUB, VMUL, (continued)
- [PATCH 19/55] target/arm: Implement MVE VNEG, Peter Maydell, 2021/06/07
- [PATCH 25/55] target/arm: Implement MVE VMAX, VMIN, Peter Maydell, 2021/06/07
- [PATCH 28/55] target/arm: Implement MVE VMULL, Peter Maydell, 2021/06/07
- [PATCH 16/55] target/arm: Implement MVE VREV16, VREV32, VREV64, Peter Maydell, 2021/06/07
- [PATCH 15/55] bitops.h: Provide hswap32(), hswap64(), wswap64() swapping operations, Peter Maydell, 2021/06/07
- [PATCH 26/55] target/arm: Implement MVE VABD, Peter Maydell, 2021/06/07
- [PATCH 24/55] target/arm: Implement MVE VRMULH, Peter Maydell, 2021/06/07
- [PATCH 39/55] target/arm: Implement MVE VQDMULH and VQRDMULH (scalar), Peter Maydell, 2021/06/07
- [PATCH 31/55] include/qemu/int128.h: Add function to create Int128 from int64_t, Peter Maydell, 2021/06/07