[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH 17/28] tcg: Add flags argument to tcg_gen_bswap16_*, tcg_gen_
From: |
Philippe Mathieu-Daudé |
Subject: |
Re: [PATCH 17/28] tcg: Add flags argument to tcg_gen_bswap16_*, tcg_gen_bswap32_i64 |
Date: |
Tue, 22 Jun 2021 12:20:56 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.11.0 |
On 6/14/21 5:58 PM, Richard Henderson wrote:
> On 6/14/21 2:41 AM, Philippe Mathieu-Daudé wrote:
>> On 6/14/21 10:37 AM, Richard Henderson wrote:
>>> Implement the new semantics in the fallback expansion.
>>> Change all callers to supply the flags that keep the
>>> semantics unchanged locally.
>>>
>>> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
>>> ---
>>> include/tcg/tcg-op.h | 8 +--
>>> target/arm/translate-a64.c | 12 ++--
>>> target/arm/translate.c | 2 +-
>>> target/i386/tcg/translate.c | 2 +-
>>> target/mips/tcg/mxu_translate.c | 2 +-
>>> target/s390x/translate.c | 4 +-
>>> target/sh4/translate.c | 2 +-
>>
>> Various REV 16/32, would it be useful to have it as a TCG opcode?
>
> Which operation are you proposing as tcg opcode? The per-halfword swap
> akin to mips wsbh? Yes, that operation also appears in arm (rev16) and
> ppc (brh). So it's a reasonable thing to do.
and REV32 for PPC BRW?
Another I noticed is popcnt.
[PATCH 18/28] tcg: Make use of bswap flags in tcg_gen_qemu_ld_*, Richard Henderson, 2021/06/14
[PATCH 09/28] tcg/ppc: Split out tcg_out_bswap64, Richard Henderson, 2021/06/14
[PATCH 11/28] tcg/ppc: Use power10 byte-reverse instructions, Richard Henderson, 2021/06/14
[PATCH 16/28] tcg: Handle new bswap flags during optimize, Richard Henderson, 2021/06/14