On 30/11/2015 04:24, Fam Zheng wrote:
> > +    for (i = 0; i < out_num; i++) {
> > +        elem->out_addr[i] = addr[i];
> > +        elem->out_sg[i] = iov[i];
> > +    }
>
> Isn't memcpy more efficient here? Otherwise looks good.

Probably not, out_num/in_num is usually very small, in fact one of them
is often 0 or 1.

For example the memcpy in address_space_rw is awfully inefficient.  This
is roughly the same.

Paolo

Reply via email to