Re: [RFC PATCH v4 00/13] riscv: Add vector ISA support

From: Guo Ren
Date: Mon Jun 01 2020 - 23:08:30 EST


On Tue, Jun 2, 2020 at 10:21 AM Greentime Hu <greentime.hu@xxxxxxxxxx> wrote:
>
> Guo Ren <guoren@xxxxxxxxxx> æ 2020å5æ31æ éæ äå11:52åéï
> >
> > Hi Greentime & Vincent,
> >
> > Thx for the dynamic vlen implementation. I've two suggestions:
> > - Please give out glibc patches mail URL, we need to review them together.
> > - We need to consider that not all processes need vectors. Most
> > system processes do not have vector features, and we should not force
> > save/restore vector for every process.
> >
>
> Hi Guo,
>
> Thanks for reviewing the patch. We are still cooking the glibc patch,
> we will add the glibc link address once we post it.
> For the save/restore mechanism in signal, it is basically the same
> with FPU porting, we can optimize it when setup_sigcontext() for both
> FPU and VECTOR in the future.
>
> /* Save the floating-point state. */
> if (has_fpu)
> err |= save_fp_state(regs, &sc->sc_fpregs);
> /* Save the vector state. */
> if (has_vector)
> err |= save_v_state(regs, sc);
>
> There should be a better way to detect whether this task use
> fpu/vector or not. Might be elf attributes or something else.
Ok, we could improve it in future patches.

--
Best Regards
Guo Ren

ML: https://lore.kernel.org/linux-csky/