Re: [PATCH v4 29/31] target/ppc: Implement cfuged instruction

2021-05-13 Thread Richard Henderson
On 5/13/21 7:24 AM, Matheus K. Ferst wrote: +static bool trans_CFUGED(DisasContext *ctx, arg_X *a) +{ +    REQUIRE_64BIT(ctx); +    REQUIRE_INSNS_FLAGS2(ctx, ISA310); +#if defined(TARGET_PPC64) +    gen_helper_cfuged(cpu_gpr[a->ra], cpu_gpr[a->rt], cpu_gpr[a->rb]); +#else +    gen_invalid(ctx); +

Re: [PATCH v4 29/31] target/ppc: Implement cfuged instruction

2021-05-13 Thread Matheus K. Ferst
On 13/05/2021 08:31, Richard Henderson wrote: On 5/12/21 1:54 PM, matheus.fe...@eldorado.org.br wrote: +    while (i) { +    n = ctz64(mask); +    if (n > i) { +    n = i; +    } + +    m = (1ll << n) - 1; +    if (bit) { +    right = ror64(right | (src & m),

Re: [PATCH v4 29/31] target/ppc: Implement cfuged instruction

2021-05-13 Thread Richard Henderson
On 5/12/21 1:54 PM, matheus.fe...@eldorado.org.br wrote: +while (i) { +n = ctz64(mask); +if (n > i) { +n = i; +} + +m = (1ll << n) - 1; +if (bit) { +right = ror64(right | (src & m), n); +} else { +left = ror64

[PATCH v4 29/31] target/ppc: Implement cfuged instruction

2021-05-12 Thread matheus . ferst
From: Matheus Ferst Signed-off-by: Matheus Ferst --- target/ppc/helper.h| 1 + target/ppc/insn32.decode | 4 +++ target/ppc/int_helper.c| 39 ++ target/ppc/translate/fixedpoint-impl.c.inc | 16 +++-- 4 files