> I don''t thing the performance argument is that important for > the xen tools though. Booting or migrating a domain is a > rare event (when compared to the page table manipulations the > xen kernel has to do all the time). > > > The only way it can reasonably be done cleanly and with decent > > performance is double compilation of the relevant mm > functions in Xen > > (and libxc too). In which case, having separate hypercall vectors > > makes most sense. > > Well, I''d try to get away without double compilation for libxc. > > But you guys know that part of the code much better than I > do, so if you think double compilation is the best way to > deal with it, lets take that route.The inner most guts of the domain builder where we build the pagetables, it''s probably best to have two totally separate functions as there are significant differences between the PAE and non PAE initial pagetables. For the save/restore functions I''d like to share the source code. However, it would be very ugly indeed to butcher the code such that the same compiled code can run-time switch. I think the best soloution is just to run it through the compiler twice with different header files. [Aside: we need to give the save/restore code the same treatment that the improved pte typing patch gave to Xen.] Ian _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
On 1 Jun 2005, at 10:30, Ian Pratt wrote:> The inner most guts of the domain builder where we build the > pagetables, > it''s probably best to have two totally separate functions as there are > significant differences between the PAE and non PAE initial pagetables. > > For the save/restore functions I''d like to share the source code. > However, it would be very ugly indeed to butcher the code such that the > same compiled code can run-time switch. I think the best soloution is > just to run it through the compiler twice with different header files. > [Aside: we need to give the save/restore code the same treatment that > the improved pte typing patch gave to Xen.]Restructuring the code so that the minimal amount of stuff has to be double-compiled will not be very difficult. Just anything that looks at or modifies pagetable entries, pretty much. There really isn''t that much p.t. code in libxc -- just a few hundred lines total I would say. But I think just making everything u64 (both ptr and val in mmu_update_t, and val in update_va_mapping) is simple, won;t hurt performance, and probably makes the tools code a bit simpler to read and to build. So let''s just do that then and argue about something more important. :-) -- Keir _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel