All of lore.kernel.org
 help / color / mirror / Atom feed
From: Oleksandr Andrushchenko <andr2000@gmail.com>
To: Julien Grall <julien.grall@arm.com>,
	xen-devel <xen-devel@lists.xenproject.org>,
	Christopher Clark <christopher.w.clark@gmail.com>,
	Stefano Stabellini <stefano@aporeto.com>,
	Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>,
	joao.m.martins@oracle.com
Subject: Re: PV drivers and zero copying
Date: Mon, 31 Jul 2017 12:52:54 +0300	[thread overview]
Message-ID: <979c536d-4e01-e76c-bcb0-f03bfeb2e271@gmail.com> (raw)
In-Reply-To: <84fb227e-62f5-f0fa-c39c-5dfa30c5d765@arm.com>

On 07/31/2017 12:47 PM, Julien Grall wrote:
>
>
> On 31/07/17 10:46, Oleksandr Andrushchenko wrote:
>> Hi, Julien!
>>
>>
>> On 07/31/2017 12:24 PM, Julien Grall wrote:
>>> (+ Joao)
>>>
>>> On 31/07/17 09:34, Oleksandr Andrushchenko wrote:
>>>> Hi, all!
>>>
>>> Hi Oleksandr,
>>>
>>>> The aim of this mail is to highlight and discuss possible 
>>>> approaches to
>>>> implementing zero copying for PV drivers. Rationale behind this is 
>>>> that
>>>> there
>>>> are use-cases when drivers operate with big shared buffers, e.g.
>>>> display, when
>>>> memory copying from front’s buffer into back’s one may 
>>>> significantly hit
>>>> performance of the system (for example, for para-virtual display 
>>>> running
>>>> at full
>>>> HD resolution at 60Hz it is approximately 475MB/sec).
>>>>
>>>> Assumptions (which actually fit ARM platforms, but can be extended to
>>>> other
>>>> platforms as well): Dom0 is a 1:1 mapped privileged domain, runs 
>>>> backend
>>>> driver/software DomU is an unprivileged domain without 1:1 memory
>>>> mapping, runs
>>>> frontend driver
>>>
>>> I would rather avoid to stick with this assumption on ARM. This was
>>> only meant to be a workaround for platform without IOMMU (see [1]) and
>>> we will get into trouble when using IOMMU.
>> You are correct, thank you
>>>
>>> For instance, there are no requirement to have the IOMMU supporting as
>>> many as address bits than the processor. So 1:1 mapping here will not
>>> be an option.
>>>
>>>>
>>>> Buffer origin: while implementing zero copying the buffer 
>>>> allocation can
>>>> happen
>>>> either on DomU’s end or Dom0’s one depending on the use-case and HW
>>>> capabilities/availability: When DomU allocates: It cannot guarantee
>>>> physical
>>>> memory continuity of the buffers allocated Dom0’s HW *can* handle
>>>> non-contiguous
>>>> memory buffers allocated by DomU for memory operations (DMA, for
>>>> example), e.g.
>>>> either with IOMMU help or by any other means (HW block’s own MMU).  
>>>> When
>>>> Dom0
>>>> allocates as it is mapped 1:1 it can allocate physically contiguous
>>>> memory
>>>> Dom0’s HW *cannot* handle non-contiguous memory buffers allocated by
>>>> DomU for
>>>> memory operations by any means.
>>>
>>> I am not sure to follow this. How zero copy is related to 1:1 mapping?
>>> Is it because you have hardware that does not support scatter/gather
>>> IO or IOMMU?
>> yes, you got it right
>
> Do you have any example of hardware? What are the performance you 
> require with them?
>
Currently our target is Renesas R-Car Gen3
At the moment I don't have clean requirements, but
ideally, PV driver introduces 0% performance drop
Some time soon I will have numbers on running display/GPU
with and without zero-copy - will keep updated
> Cheers,
>


_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel

  reply	other threads:[~2017-07-31  9:52 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-07-31  8:34 PV drivers and zero copying Oleksandr Andrushchenko
2017-07-31  9:03 ` Paul Durrant
2017-07-31  9:23   ` Oleksandr Andrushchenko
2017-07-31  9:31   ` Andrew Cooper
2017-07-31  9:44     ` Oleksandr Andrushchenko
2017-07-31  9:24 ` Julien Grall
2017-07-31  9:46   ` Oleksandr Andrushchenko
2017-07-31  9:47     ` Julien Grall
2017-07-31  9:52       ` Oleksandr Andrushchenko [this message]
2017-07-31 10:04         ` Julien Grall
2017-07-31 10:37           ` Oleksandr Andrushchenko
2017-07-31 11:08             ` Joao Martins
2017-07-31 11:03 ` Joao Martins
2017-07-31 11:41   ` Oleksandr Andrushchenko
2017-07-31 11:58     ` Joao Martins
2017-07-31 12:10       ` Oleksandr Andrushchenko
2017-07-31 20:28 ` Stefano Stabellini
2017-08-01  7:18   ` Oleksandr Andrushchenko
2017-08-01 19:07     ` Stefano Stabellini
2017-08-02 10:17       ` Julien Grall

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=979c536d-4e01-e76c-bcb0-f03bfeb2e271@gmail.com \
    --to=andr2000@gmail.com \
    --cc=christopher.w.clark@gmail.com \
    --cc=joao.m.martins@oracle.com \
    --cc=julien.grall@arm.com \
    --cc=konrad.wilk@oracle.com \
    --cc=stefano@aporeto.com \
    --cc=xen-devel@lists.xenproject.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.