qemu-riscv
[Top][All Lists]
Advanced

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

Re: [RFC v2 42/76] target/riscv: rvv-0.9: whole register move instructio


From: Richard Henderson
Subject: Re: [RFC v2 42/76] target/riscv: rvv-0.9: whole register move instructions
Date: Thu, 30 Jul 2020 13:14:20 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0

On 7/22/20 2:16 AM, frank.chang@sifive.com wrote:
> +        ((a->rd & ((LEN) - 1)) == 0) &&                   \

QEMU_IS_ALIGNED(a->rd, LEN)

> +            tcg_gen_gvec_mov(8, vreg_ofs(s, a->rd + i),   \
> +                             vreg_ofs(s, a->rs2 + i),     \
> +                             s->vlen / 8, s->vlen / 8);   \

The first argument should be MO_8 (= 0) not 8.
You should have seen assertion failures with this.

There should be no reason to loop on this -- one move should be enough:

    tcg_gen_gvec_mov(MO_8, vreg_ofs(s, a->rd),
                     vreg_ofs(s, a->rs2),
                     s->vlen / 8 * LEN, s->vlen / 8 * LEN);

If *that* asserts, because the length is too long or something, then I'll make
changes to tcg/tcg-op-gvec.c to make it work.


r~



reply via email to

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