Hello, I recently installed a minimal 32bit version of Debian Etch, and then also installed Xen from Debian''s package repository. When Xen booted up, memory usage was just below 40MB (typical for such a debian install). Then I decided to do the exact same install, but using the 64bit version of Debian Etch and Xen. This time when Xen booted up, memory usage was just over 90MB - at least double that of the 32bit version. Can anybody explain this to me? Why 64bit XEN would use double the memory? If I try 32bit vs 64bit debian without using XEN, then memory use about 30MB with each - no doubling. Jamie Burns. _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Jamie Burns wrote:> Hello, > > I recently installed a minimal 32bit version of Debian Etch, and then > also installed Xen from Debian''s package repository. > > When Xen booted up, memory usage was just below 40MB (typical for such > a debian install). > > Then I decided to do the exact same install, but using the 64bit > version of Debian Etch and Xen. > > This time when Xen booted up, memory usage was just over 90MB - at > least double that of the 32bit version. > > Can anybody explain this to me? Why 64bit XEN would use double the > memory? > > If I try 32bit vs 64bit debian without using XEN, then memory use > about 30MB with each - no doubling. > > Jamie Burns. > > _______________________________________________ > Xen-users mailing list > Xen-users@lists.xensource.com > http://lists.xensource.com/xen-users >64 bit pointers and 64 bit memory address slots are twice as big as corresponding 32 bit ones. So unless you have 4 GB of memory or more, using 64bit software is actually slower for the system, not faster. _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
On 5 Feb 2007 at 10:00, Tom Miller wrote: [...]> 64 bit pointers and 64 bit memory address slots are twice as big as > corresponding 32 bit ones. So unless you have 4 GB of memory or more, > using 64bit software is actually slower for the system, not faster.Are you sure? You are not saying that 64-bit programs are twice as large as 32-bit programs, do you? Besides of that I''d expect a 64-bit CPU to load a 64 bit word from memory in the same speed as a 32-bit CPU would load a 32-bit word. Also these AMD/Intel CPUs seem to have additional registers in 64bit mode. I think the memory overhead comes from (As Andrew S Tanenbaum explained in one of his books about 10 years ago) the fact that the tables to manage the huge 64 bit virtual address space are a great deal larger than those for 32-bit. Finally (as in HP-UX 11), a 64 bit OS does not mean that every program is a 64-bit executable: a 32-bit Shell, Perl and Emacs is sufficient for most users I''d think ;-) Regards, Ulrich> > > _______________________________________________ > Xen-users mailing list > Xen-users@lists.xensource.com > http://lists.xensource.com/xen-users_______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Hi, Well, I didn''t ask if it was faster...... And no it is not necessarily slower, x86-64 architecture has various other improvements, in particular the number of available CPU registers. Jamie. ----- Original Message ----- From: "Tom Miller" <madprogextrodinr@gmail.com> To: <xen-users@lists.xensource.com> Sent: Monday, February 05, 2007 3:00 PM Subject: Re: [Xen-users] 32bit vs 64bit memory usage question> Jamie Burns wrote: >> Hello, >> >> I recently installed a minimal 32bit version of Debian Etch, and then >> also installed Xen from Debian''s package repository. >> >> When Xen booted up, memory usage was just below 40MB (typical for such a >> debian install). >> >> Then I decided to do the exact same install, but using the 64bit version >> of Debian Etch and Xen. >> >> This time when Xen booted up, memory usage was just over 90MB - at least >> double that of the 32bit version. >> >> Can anybody explain this to me? Why 64bit XEN would use double the >> memory? >> >> If I try 32bit vs 64bit debian without using XEN, then memory use about >> 30MB with each - no doubling. >> >> Jamie Burns. >> >> _______________________________________________ >> Xen-users mailing list >> Xen-users@lists.xensource.com >> http://lists.xensource.com/xen-users >> > 64 bit pointers and 64 bit memory address slots are twice as big as > corresponding 32 bit ones. So unless you have 4 GB of memory or more, > using 64bit software is actually slower for the system, not faster. > > > _______________________________________________ > Xen-users mailing list > Xen-users@lists.xensource.com > http://lists.xensource.com/xen-users >_______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Thanks for your insight. But nothing else in my Debian install uses up double memory. Only XEN. Why only XEN? ----- Original Message ----- From: "Ulrich Windl" <ulrich.windl@rz.uni-regensburg.de> To: <xen-users@lists.xensource.com> Sent: Monday, February 05, 2007 3:28 PM Subject: Re: [Xen-users] 32bit vs 64bit memory usage question> On 5 Feb 2007 at 10:00, Tom Miller wrote: > > [...] >> 64 bit pointers and 64 bit memory address slots are twice as big as >> corresponding 32 bit ones. So unless you have 4 GB of memory or more, >> using 64bit software is actually slower for the system, not faster. > > Are you sure? You are not saying that 64-bit programs are twice as large > as 32-bit > programs, do you? Besides of that I''d expect a 64-bit CPU to load a 64 bit > word > from memory in the same speed as a 32-bit CPU would load a 32-bit word. > Also these > AMD/Intel CPUs seem to have additional registers in 64bit mode. > > I think the memory overhead comes from (As Andrew S Tanenbaum explained in > one of > his books about 10 years ago) the fact that the tables to manage the huge > 64 bit > virtual address space are a great deal larger than those for 32-bit. > > Finally (as in HP-UX 11), a 64 bit OS does not mean that every program is > a 64-bit > executable: a 32-bit Shell, Perl and Emacs is sufficient for most users > I''d think > ;-) > > Regards, > Ulrich > > >> >> >> _______________________________________________ >> Xen-users mailing list >> Xen-users@lists.xensource.com >> http://lists.xensource.com/xen-users > > > > _______________________________________________ > Xen-users mailing list > Xen-users@lists.xensource.com > http://lists.xensource.com/xen-users >_______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
At 2007-02-05 10:00 -0500, Tom Miller wrote:>Jamie Burns wrote: >>Hello, >> >>I recently installed a minimal 32bit version of Debian Etch, and then >>also installed Xen from Debian''s package repository. >> >>When Xen booted up, memory usage was just below 40MB (typical for such a >>debian install). >> >>Then I decided to do the exact same install, but using the 64bit version >>of Debian Etch and Xen. >> >>This time when Xen booted up, memory usage was just over 90MB - at least >>double that of the 32bit version. >> >>Can anybody explain this to me? Why 64bit XEN would use double the memory? >> >>If I try 32bit vs 64bit debian without using XEN, then memory use about >>30MB with each - no doubling. >> >>Jamie Burns. >> >>_______________________________________________ >>Xen-users mailing list >>Xen-users@lists.xensource.com >>http://lists.xensource.com/xen-users >64 bit pointers and 64 bit memory address slots are twice as big as >corresponding 32 bit ones. So unless you have 4 GB of memory or more, >using 64bit software is actually slower for the system, not faster. > > >_______________________________________________ >Xen-users mailing list >Xen-users@lists.xensource.com >http://lists.xensource.com/xen-usersSometimes it is more about address space than real memory. Some apps like to map very large files. If you have one 64 bit app you NEED to run then you have no choice but to run a 64 bit kernel. In addition apps that really want to use memory in the range 2-4GB are better implemented using 64 bit. Geoff Streeter _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Petersson, Mats
2007-Feb-05 17:40 UTC
RE: [Xen-users] 32bit vs 64bit memory usage question
> -----Original Message----- > From: xen-users-bounces@lists.xensource.com > [mailto:xen-users-bounces@lists.xensource.com] On Behalf Of > Jamie Burns > Sent: 05 February 2007 16:31 > To: Ulrich Windl; xen-users@lists.xensource.com > Subject: Re: [Xen-users] 32bit vs 64bit memory usage question > > Thanks for your insight. > > But nothing else in my Debian install uses up double memory. > > Only XEN. > > Why only XEN?There''s no sensible reason for Xen using twice as much memory in itself. However, as stated elsewhere, page-table-entries are 64-bit (as they are for PAE!), and that may account for SOME of the difference. If you compare 32-bit PAE with your previous measurements, how does it stand? The other difference that I see is that x86-64 has a bigger heap, but that''s only 4MB, so that wouldn''t match what you''re seeing. Of course, there''s a little bit extra code in the code dealing with page-tables due to 4-level page-tables, as this is not present in other models of Xen. But since all the CODE in Xen is about 600K [64-bit build] ("latest" unstable), it doesn''t account for the difference you''re seeing. -- Mats> > ----- Original Message ----- > From: "Ulrich Windl" <ulrich.windl@rz.uni-regensburg.de> > To: <xen-users@lists.xensource.com> > Sent: Monday, February 05, 2007 3:28 PM > Subject: Re: [Xen-users] 32bit vs 64bit memory usage question > > > > On 5 Feb 2007 at 10:00, Tom Miller wrote: > > > > [...] > >> 64 bit pointers and 64 bit memory address slots are twice as big as > >> corresponding 32 bit ones. So unless you have 4 GB of > memory or more, > >> using 64bit software is actually slower for the system, not faster. > > > > Are you sure? You are not saying that 64-bit programs are > twice as large > > as 32-bit > > programs, do you? Besides of that I''d expect a 64-bit CPU > to load a 64 bit > > word > > from memory in the same speed as a 32-bit CPU would load a > 32-bit word. > > Also these > > AMD/Intel CPUs seem to have additional registers in 64bit mode. > > > > I think the memory overhead comes from (As Andrew S > Tanenbaum explained in > > one of > > his books about 10 years ago) the fact that the tables to > manage the huge > > 64 bit > > virtual address space are a great deal larger than those for 32-bit. > > > > Finally (as in HP-UX 11), a 64 bit OS does not mean that > every program is > > a 64-bit > > executable: a 32-bit Shell, Perl and Emacs is sufficient > for most users > > I''d think > > ;-) > > > > Regards, > > Ulrich > > > > > >> > >> > >> _______________________________________________ > >> Xen-users mailing list > >> Xen-users@lists.xensource.com > >> http://lists.xensource.com/xen-users > > > > > > > > _______________________________________________ > > Xen-users mailing list > > Xen-users@lists.xensource.com > > http://lists.xensource.com/xen-users > > > > > _______________________________________________ > Xen-users mailing list > Xen-users@lists.xensource.com > http://lists.xensource.com/xen-users > > >_______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users