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

RE: Proposal for Porting Xen to Armv8-R64 - DraftA


  • To: Julien Grall <julien@xxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>
  • From: Wei Chen <Wei.Chen@xxxxxxx>
  • Date: Thu, 3 Mar 2022 10:43:00 +0000
  • Accept-language: en-US
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=arm.com; dmarc=pass action=none header.from=arm.com; dkim=pass header.d=arm.com; arc=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=HCD6Q6GpYs4ZMk7FNJRJdzfMT90uWPMZvbl4dWtBx3E=; b=j7xKwaCKHmxJ5tmC9ByScfN3398rdcVDINBT+37CrO/kYIOnWbw7DrtLCm2liLSNTODsDYKf49dIRJ1bgSLkZmgepe4IGUOEwO5o/e+dSR1u+IEwuClfmo+PBw8y+LzLaSP5fxAU3eoM7ECj0BBWmoWwkl8lQtyLnBJzQQLh9eMxgRsQrDMQwK2aHarcY6hOKa+RDsmFVT64W3FGOD5bjnleAxVsD5bZ5t8jDdVG0oMiGDBt2+PvpunP+6ESdDYkd5fGow83WtTTEtAUvFgqQt+Q8aAG6Y9rrq+WgdAWxmJ6KRAQQNPHAU8v9YXsETHERExVq/BF0U+YFGGh4BD8QA==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=XfJ1bw76v1uUO8HYzHC4C2bC3I0mcm2OKZlqq6aZdN7uPMQiewalVTrQPIdyyF02duam6EP7rBFF85sD7m2zzCQl3kNSYwC/jAhlJgdHmfgZaz3YZtjuvgyfX10m1eDZh5e01WGgsX057enaRFdlYW+5ulPBJPt50QAl8soNaXhzn8qlG4acVDPCGvdtoKaqq8v07u4Ya4GhxbyfNV7eZyZ97kHZntAxI/8QL7Cee+LKA3I5S50qxiUunKL07HmrIj8ooJuniLja1Ct92gDurQaEqBVXXSsEZjYJHH3O5aRlniDDboqwa3RfT5hO6HmRy1r1S10vDIN7Hz+QSP867g==
  • Authentication-results-original: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=arm.com;
  • Cc: "xen-devel@xxxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxxx>, Bertrand Marquis <Bertrand.Marquis@xxxxxxx>, Penny Zheng <Penny.Zheng@xxxxxxx>, Henry Wang <Henry.Wang@xxxxxxx>, nd <nd@xxxxxxx>
  • Delivery-date: Thu, 03 Mar 2022 10:43:21 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
  • Nodisclaimer: true
  • Original-authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=arm.com;
  • Thread-index: AdgpQxtXwh7LkfydTgiYk9bhMgU+ogAn0mUAABEK2UAAF1ylAACsO9YwAA5uZgAAI3g7sAAIzZgAAB9QTKAAEI0UgAAC/Q2w
  • Thread-topic: Proposal for Porting Xen to Armv8-R64 - DraftA

Hi Julien,

> -----Original Message-----
> From: Julien Grall <julien@xxxxxxx>
> Sent: 2022年3月3日 17:15
> To: Wei Chen <Wei.Chen@xxxxxxx>; Stefano Stabellini
> <sstabellini@xxxxxxxxxx>
> Cc: xen-devel@xxxxxxxxxxxxxxxxxxxx; Bertrand Marquis
> <Bertrand.Marquis@xxxxxxx>; Penny Zheng <Penny.Zheng@xxxxxxx>; Henry Wang
> <Henry.Wang@xxxxxxx>; nd <nd@xxxxxxx>
> Subject: Re: Proposal for Porting Xen to Armv8-R64 - DraftA
> 
> Hi Wei,
> 
> On 03/03/2022 01:35, Wei Chen wrote:
> >>> 1. Assembly code for EL1 MPU context_switch
> >>
> >> This discussion reminds me when KVM decided to rewrite their context
> >> switch from assembly to C. The outcome was the compiler is able to do a
> >> better job than us when it comes to optimizing.
> >>
> >> With a C version, we could also share the save/restore code with 32-bit
> >> and it is easier to read/maintain.
> >>
> >> So I would suggest to run some numbers to check if it really worth
> >> implementing the MPU save/restore in assembly.
> >>
> >
> > It's interesting to hear KVM guys have similar discussion. Yes, if the
> > gains of assembly code is not very obvious, then reusing the code for
> 32-bit
> > would be more important. As our current platform (FVP) could not do very
> > precise performance measurement. I want to keep current assembly code
> there,
> > when we have a platform that can do such measurement we can have a
> thread
> > to discuss it.
> 
> I briefly looked at the code, the assembly version is not going to be
> trivial to review and we don't know yet whether it has an advantage. So
> I would say this should be the inverse here.
> 
> We want the C version first until we can prove the assembly version is
> better.
> 
> My gut feeling is we will not need the assembly version.
> 

Ok, we will rollback to C version. After we will finish the measurements,
then we will discuss it again (if the assembly has enough gain).

> Cheers,
> 
> --
> Julien Grall

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.