* Even faster page copy for Xen?
@ 2010-07-15 18:15 Dan Magenheimer
2010-07-15 21:35 ` Keir Fraser
2010-08-06 7:57 ` Jan Beulich
0 siblings, 2 replies; 6+ messages in thread
From: Dan Magenheimer @ 2010-07-15 18:15 UTC (permalink / raw)
To: Keir Fraser, Jan Beulich; +Cc: xen-devel
Hi Jan, Keir --
My x86 assembly skills are much too poor to carefully evaluate
and, if of value, implement this in Xen but given your previous
interest, such as:
http://xenbits.xensource.com/xen-unstable.hg?rev/8de4b4e9a435
the following might be worth looking at.
Intel has just posted memcpy improvements for glibc for recent
popular Intel processor families here:
http://article.gmane.org/gmane.comp.lib.glibc.alpha/15278
The preface to the above patch looks very enticing...
Semi-related, I wonder if you know, if there were a
"copy_page_from_other_node()" to be used if the
caller is fairly sure that the page is being copied
between nodes, could this be made significantly faster
than a normal copy_page()?
Thanks,
Dan
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: Even faster page copy for Xen?
2010-07-15 18:15 Dan Magenheimer
@ 2010-07-15 21:35 ` Keir Fraser
2010-07-15 23:36 ` Dan Magenheimer
2010-08-06 7:57 ` Jan Beulich
1 sibling, 1 reply; 6+ messages in thread
From: Keir Fraser @ 2010-07-15 21:35 UTC (permalink / raw)
To: Dan Magenheimer, Jan Beulich; +Cc: xen-devel@lists.xensource.com
It has to be said, possibly tmem excepted, there is very little page copying
in Xen.
-- Keir
On 15/07/2010 19:15, "Dan Magenheimer" <dan.magenheimer@oracle.com> wrote:
> Hi Jan, Keir --
>
> My x86 assembly skills are much too poor to carefully evaluate
> and, if of value, implement this in Xen but given your previous
> interest, such as:
>
> http://xenbits.xensource.com/xen-unstable.hg?rev/8de4b4e9a435
>
> the following might be worth looking at.
>
> Intel has just posted memcpy improvements for glibc for recent
> popular Intel processor families here:
>
> http://article.gmane.org/gmane.comp.lib.glibc.alpha/15278
>
> The preface to the above patch looks very enticing...
>
> Semi-related, I wonder if you know, if there were a
> "copy_page_from_other_node()" to be used if the
> caller is fairly sure that the page is being copied
> between nodes, could this be made significantly faster
> than a normal copy_page()?
>
> Thanks,
> Dan
^ permalink raw reply [flat|nested] 6+ messages in thread
* RE: Even faster page copy for Xen?
2010-07-15 21:35 ` Keir Fraser
@ 2010-07-15 23:36 ` Dan Magenheimer
2010-07-16 7:57 ` Keir Fraser
0 siblings, 1 reply; 6+ messages in thread
From: Dan Magenheimer @ 2010-07-15 23:36 UTC (permalink / raw)
To: Keir Fraser, Jan Beulich; +Cc: xen-devel
I wasn't sure about that... Jan's patch to speed up
copy_page (by 12%) went in before tmem was in-tree,
so I assumed otherwise. Clearly my interest is for
tmem, especially if 2x-4x improvement is possible,
but if there really is no significant advantage for
non-tmem code, I will put it on my list... for sometime
in the next century when I am a good x86 assembly
programmer :-)
> -----Original Message-----
> From: Keir Fraser [mailto:keir.fraser@eu.citrix.com]
> Sent: Thursday, July 15, 2010 3:35 PM
> To: Dan Magenheimer; Jan Beulich
> Cc: xen-devel@lists.xensource.com
> Subject: Re: Even faster page copy for Xen?
>
> It has to be said, possibly tmem excepted, there is very little page
> copying
> in Xen.
>
> -- Keir
>
> On 15/07/2010 19:15, "Dan Magenheimer" <dan.magenheimer@oracle.com>
> wrote:
>
> > Hi Jan, Keir --
> >
> > My x86 assembly skills are much too poor to carefully evaluate
> > and, if of value, implement this in Xen but given your previous
> > interest, such as:
> >
> > http://xenbits.xensource.com/xen-unstable.hg?rev/8de4b4e9a435
> >
> > the following might be worth looking at.
> >
> > Intel has just posted memcpy improvements for glibc for recent
> > popular Intel processor families here:
> >
> > http://article.gmane.org/gmane.comp.lib.glibc.alpha/15278
> >
> > The preface to the above patch looks very enticing...
> >
> > Semi-related, I wonder if you know, if there were a
> > "copy_page_from_other_node()" to be used if the
> > caller is fairly sure that the page is being copied
> > between nodes, could this be made significantly faster
> > than a normal copy_page()?
> >
> > Thanks,
> > Dan
>
>
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: Even faster page copy for Xen?
2010-07-15 23:36 ` Dan Magenheimer
@ 2010-07-16 7:57 ` Keir Fraser
0 siblings, 0 replies; 6+ messages in thread
From: Keir Fraser @ 2010-07-16 7:57 UTC (permalink / raw)
To: Dan Magenheimer, Jan Beulich; +Cc: xen-devel@lists.xensource.com
Jan also added a copy_page hypercall, so he may have been optimising for
that, since I guess the Novell kernels must use it.
-- Keir
On 16/07/2010 00:36, "Dan Magenheimer" <dan.magenheimer@oracle.com> wrote:
> I wasn't sure about that... Jan's patch to speed up
> copy_page (by 12%) went in before tmem was in-tree,
> so I assumed otherwise. Clearly my interest is for
> tmem, especially if 2x-4x improvement is possible,
> but if there really is no significant advantage for
> non-tmem code, I will put it on my list... for sometime
> in the next century when I am a good x86 assembly
> programmer :-)
>
>> -----Original Message-----
>> From: Keir Fraser [mailto:keir.fraser@eu.citrix.com]
>> Sent: Thursday, July 15, 2010 3:35 PM
>> To: Dan Magenheimer; Jan Beulich
>> Cc: xen-devel@lists.xensource.com
>> Subject: Re: Even faster page copy for Xen?
>>
>> It has to be said, possibly tmem excepted, there is very little page
>> copying
>> in Xen.
>>
>> -- Keir
>>
>> On 15/07/2010 19:15, "Dan Magenheimer" <dan.magenheimer@oracle.com>
>> wrote:
>>
>>> Hi Jan, Keir --
>>>
>>> My x86 assembly skills are much too poor to carefully evaluate
>>> and, if of value, implement this in Xen but given your previous
>>> interest, such as:
>>>
>>> http://xenbits.xensource.com/xen-unstable.hg?rev/8de4b4e9a435
>>>
>>> the following might be worth looking at.
>>>
>>> Intel has just posted memcpy improvements for glibc for recent
>>> popular Intel processor families here:
>>>
>>> http://article.gmane.org/gmane.comp.lib.glibc.alpha/15278
>>>
>>> The preface to the above patch looks very enticing...
>>>
>>> Semi-related, I wonder if you know, if there were a
>>> "copy_page_from_other_node()" to be used if the
>>> caller is fairly sure that the page is being copied
>>> between nodes, could this be made significantly faster
>>> than a normal copy_page()?
>>>
>>> Thanks,
>>> Dan
>>
>>
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: Even faster page copy for Xen?
@ 2010-08-05 17:48 Jan Beulich
0 siblings, 0 replies; 6+ messages in thread
From: Jan Beulich @ 2010-08-05 17:48 UTC (permalink / raw)
To: keir.fraser, dan.magenheimer; +Cc: xen-devel
>>> Keir Fraser 07/16/10 9:57 AM >>>
>Jan also added a copy_page hypercall, so he may have been optimising for
>that, since I guess the Novell kernels must use it.
Yes, that was the very goal of that change.
Jan
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: Even faster page copy for Xen?
2010-07-15 18:15 Dan Magenheimer
2010-07-15 21:35 ` Keir Fraser
@ 2010-08-06 7:57 ` Jan Beulich
1 sibling, 0 replies; 6+ messages in thread
From: Jan Beulich @ 2010-08-06 7:57 UTC (permalink / raw)
To: Keir Fraser, Dan Magenheimer; +Cc: xen-devel
>>> On 15.07.10 at 20:15, Dan Magenheimer <dan.magenheimer@oracle.com> wrote:
> Hi Jan, Keir --
>
> My x86 assembly skills are much too poor to carefully evaluate
> and, if of value, implement this in Xen but given your previous
> interest, such as:
>
> http://xenbits.xensource.com/xen-unstable.hg?rev/8de4b4e9a435
>
> the following might be worth looking at.
>
> Intel has just posted memcpy improvements for glibc for recent
> popular Intel processor families here:
>
> http://article.gmane.org/gmane.comp.lib.glibc.alpha/15278
>
> The preface to the above patch looks very enticing...
I'm not sure how much of this applies to the much more specific
case of copying pages... Additionally, I don't think trying to
use XMM registers in Xen would be a good idea.
> Semi-related, I wonder if you know, if there were a
> "copy_page_from_other_node()" to be used if the
> caller is fairly sure that the page is being copied
> between nodes, could this be made significantly faster
> than a normal copy_page()?
I would think that this should mostly be taken care of by
using non-temporal stores (non-temporal loads unfortunately
aren't available without using XMM registers). The only other
meaningful tuning one could do would be to increase the
prefetch distances and grow the distance between loads and
stores. The latter would require the use of more registers
and hence have other drawbacks.
Jan
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2010-08-06 7:57 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-08-05 17:48 Even faster page copy for Xen? Jan Beulich
-- strict thread matches above, loose matches on Subject: below --
2010-07-15 18:15 Dan Magenheimer
2010-07-15 21:35 ` Keir Fraser
2010-07-15 23:36 ` Dan Magenheimer
2010-07-16 7:57 ` Keir Fraser
2010-08-06 7:57 ` Jan Beulich
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).