Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
32bit over 64bit question
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Gentoo on AMD64
View previous topic :: View next topic  
Author Message
SAngeli
l33t
l33t


Joined: 16 Apr 2004
Posts: 904
Location: Italy

PostPosted: Sat Feb 11, 2006 11:36 am    Post subject: 32bit over 64bit question Reply with quote

Hi,

Question (1)
I curently run amd64 but wish to better understand what is the benefit of choosing 64bit over 32bit seen that 64bit world is not so mature as of now (major improvements have been made).

I consider as a way of comparison: a pc with gentoo os, xorg, kde and applications.
I know that for compilation time 64bit is way faster. But how about boot-up time, starting an application, and other parameters?
I ask this because I have a feeling that 32bit is still plenty for ordinary usage.
Please help me better understand.

PS: keep in mind that all this is for desktop pc and not for server. Servers I believe 64bit is the best ever.


Question (2)
How about CPU? What to choose from between Intel dual core and AMD on the 32bit platform? What about Viiv™ technology and Gentoo - Linux?
As for 64bit I believe it is still AMD to be chosen, right?


Thank you,
Spiro
Back to top
View user's profile Send private message
felicehome
Apprentice
Apprentice


Joined: 30 Sep 2004
Posts: 217

PostPosted: Sat Feb 11, 2006 12:10 pm    Post subject: Reply with quote

The biggest advantage I guess is native memory allocation over 2GB. This is because with 64 bit you can address more memory. So this answers the question why most servers running 64 bit nowadays.
Other advantages are various speed improvments. You've already mentioned compilation time. But there is also a lot of speed improvment in encoder / decoder apps like lame and transcode. But Boot up time won't be faster and starting applications either. This is because the bottleneck for starting applications and boot up isn't the CPU. The bottleneck is your harddrive. If your harddrive could deliver data faster startup time would be way faster even with slow CPU's.

There are also a few disadvantages running 64bit Gentoo or a 64bit system in general:

You're applications will consume more memory. Because storing an integer or a pointer into RAM will now consume 64bit and not 32bit. It's not much more though.
Not all gentoo packages are available for 64bit. But an AMD64 is able to nativly run 32 bit code, so there are a few workarounds for this:
1) emerge 32 binary packages for those few applications
2) compile them in a 32 bit chroot

So if you asked me, my advice would be to go with the 64 bit enviroment. Because I think there are more advantages than disadvantages. I installed my new 64bit machine a month ago. No problems at all. And I can run every program I want.

As for CPU I would go for an AMD64 (as they own most benchmarks. But I don't want to start an Intel vs. AMD war here.) also consider an AMD64 X2 dualcore. My system is way more responsive since I went dualcore.

Greetings Felice
Back to top
View user's profile Send private message
6D7474
Tux's lil' helper
Tux's lil' helper


Joined: 08 Sep 2005
Posts: 135

PostPosted: Sat Feb 11, 2006 3:55 pm    Post subject: Reply with quote

in x86_64 pointers are indeed 64-bit, but AFAIK integers are still 32-bit...
Back to top
View user's profile Send private message
felicehome
Apprentice
Apprentice


Joined: 30 Sep 2004
Posts: 217

PostPosted: Sat Feb 11, 2006 5:33 pm    Post subject: Reply with quote

you're right only 32bit with standard integers I just tested this with:

#include <iostream>
using namespace std;
int main ()
{
cout << "Size of Int in bytes: " << sizeof(int) << endl;
return 0;
}
Back to top
View user's profile Send private message
thedopefishlives
Tux's lil' helper
Tux's lil' helper


Joined: 23 Nov 2005
Posts: 84

PostPosted: Sat Feb 11, 2006 11:36 pm    Post subject: Reply with quote

Integers are still 32-bit, but the nice thing is that the processor can natively handle a 64-bit datatype in the registers. Unfortunately, there are few people who use such data types. It is particularly nice for video encoding/decoding, though.
Back to top
View user's profile Send private message
thagame
Apprentice
Apprentice


Joined: 07 Mar 2004
Posts: 210
Location: Windsor, Ontario, Canada

PostPosted: Sun Feb 12, 2006 2:00 am    Post subject: Reply with quote

as far as 64bit being faster i beg to differ. i have amd64 and i switched to ~x86 to see for myself and the packages emerge way faster in x86 then they did running ~amd64
Back to top
View user's profile Send private message
piercey
Apprentice
Apprentice


Joined: 28 Jan 2005
Posts: 182

PostPosted: Sun Feb 12, 2006 3:35 am    Post subject: Reply with quote

Were you using non standard CFLAGS or something, because there is a noticeable improvement when I tested it. A very noticeable improvement.
_________________
[ 2008.0 X86 E8400 @ 4.0Ghz ]
Back to top
View user's profile Send private message
Fran
Guru
Guru


Joined: 29 Feb 2004
Posts: 530
Location: Coruña (Spain)

PostPosted: Sun Feb 12, 2006 3:41 pm    Post subject: Reply with quote

Compilation times were faster when I compared 18 months ago. But I don't know why, 64 bit compilation times have been getting worse with every gcc version, and right now, with gcc-4.1.0:

64bit:
Code:
franjva@tay64 ~ $ sudo genlop -t xorg-server qt kdelibs k3b
 * x11-base/xorg-server

     Thu Feb  9 15:42:47 2006 >>> x11-base/xorg-server-1.0.1-r2
       merge time: 15 minutes and 21 seconds.

 * x11-libs/qt

     Thu Feb  9 21:14:29 2006 >>> x11-libs/qt-3.3.4-r8
       merge time: 19 minutes and 45 seconds.

 * kde-base/kdelibs

     Thu Feb  9 22:26:58 2006 >>> kde-base/kdelibs-3.5.1-r1
       merge time: 47 minutes and 48 seconds.

 * app-cdr/k3b

     Fri Feb 10 11:22:31 2006 >>> app-cdr/k3b-0.12.10
       merge time: 10 minutes and 59 seconds.

     Sun Feb 12 16:20:26 2006 >>> app-cdr/k3b-0.12.11
       merge time: 12 minutes and 17 seconds.


32bit:
Code:
tay64 / # genlop -t xorg-server qt kdelibs k3b
 * x11-base/xorg-server

     Sun Feb  5 21:26:06 2006 >>> x11-base/xorg-server-1.0.1-r2
       merge time: 15 minutes and 10 seconds.

 * x11-libs/qt

     Sun Feb  5 22:28:30 2006 >>> x11-libs/qt-3.3.4-r8
       merge time: 17 minutes and 45 seconds.

 * kde-base/kdelibs

     Sun Feb  5 23:25:38 2006 >>> kde-base/kdelibs-3.5.1
       merge time: 50 minutes and 3 seconds.

     Mon Feb  6 21:53:53 2006 >>> kde-base/kdelibs-3.5.1-r1
       merge time: 44 minutes and 49 seconds.

 * app-cdr/k3b

     Mon Feb  6 22:47:26 2006 >>> app-cdr/k3b-0.12.10
       merge time: 10 minutes and 17 seconds.


This is in the same machine; I have 2 gentoos installed with exactly the same packages in both (see sig.)
Back to top
View user's profile Send private message
whig
l33t
l33t


Joined: 27 Nov 2004
Posts: 973
Location: New Zealand

PostPosted: Mon Feb 13, 2006 3:49 am    Post subject: Reply with quote

In amd64 I compiled my base kernel in 2:47, compare that to 3:33 for "amd32" (shall I say). Also oggenc goes almost twice as fast in 64 land.
Back to top
View user's profile Send private message
drwook
Veteran
Veteran


Joined: 30 Mar 2005
Posts: 1324
Location: London

PostPosted: Mon Feb 13, 2006 10:11 pm    Post subject: Reply with quote

I'd have to say compilation is noticably quicker under x86_64 than x86....

Are the systems identical - e.g. CFLAGS/USE flags/compiler/glibc/binutils/ccache? Same behaviour/similar timings with a non-experimental compiler? same (as far as practical) kernel patchset, version and .config?
Back to top
View user's profile Send private message
Fran
Guru
Guru


Joined: 29 Feb 2004
Posts: 530
Location: Coruña (Spain)

PostPosted: Mon Feb 13, 2006 10:41 pm    Post subject: Reply with quote

drwook wrote:
I'd have to say compilation is noticably quicker under x86_64 than x86....

Have you measured it?

drwook wrote:
Are the systems identical - e.g. CFLAGS/USE flags/compiler/glibc/binutils/ccache? Same behaviour/similar timings with a non-experimental compiler? same (as far as practical) kernel patchset, version and .config?

Yep, everything exactly the same. Same USEs, CFLAGS (O2, march=athlon64, pipe), glibcs, gccs and kernel configs. No ccache. Both in ext3 partitions. In fact, ALL the programs have the same versions in both installations (I like to have them this way; they share /usr/portage, and /usr/portage/distfiles doesn't have the same sources twice for any program).

And the last time I looked with gcc-3.4.5, compilation times were also lower in x86 than in x86-64. The last time I remember x86-64 being faster compiling than x86 was with gcc-3.4.0. Back then it was WAY faster. But now... well... Other tests:

64 bit:
Code:
franjva@tay64 ~ $ sudo genlop -t kopete gnumeric
 * kde-base/kopete

     Fri Feb 10 20:21:09 2006 >>> kde-base/kopete-3.5.1
       merge time: 26 minutes and 31 seconds.

 * app-office/gnumeric

     Fri Feb 10 12:40:27 2006 >>> app-office/gnumeric-1.6.1
       merge time: 5 minutes and 46 seconds.

     Sun Feb 12 10:23:50 2006 >>> app-office/gnumeric-1.6.1
       merge time: 6 minutes.

     Sun Feb 12 20:40:52 2006 >>> app-office/gnumeric-1.6.1
       merge time: 6 minutes.


32bit:
Code:
tay64 / # genlop -t kopete gnumeric
 * kde-base/kopete

     Tue Feb  7 15:03:14 2006 >>> kde-base/kopete-3.5.1
       merge time: 22 minutes and 8 seconds.

     Mon Feb 13 22:29:33 2006 >>> kde-base/kopete-3.5.1
       merge time: 25 minutes and 54 seconds.

 * app-office/gnumeric

     Tue Feb  7 22:44:52 2006 >>> app-office/gnumeric-1.6.1
       merge time: 5 minutes and 48 seconds.

     Mon Feb 13 21:30:59 2006 >>> app-office/gnumeric-1.6.1
       merge time: 5 minutes and 59 seconds.
Back to top
View user's profile Send private message
pgilbert
n00b
n00b


Joined: 03 Dec 2005
Posts: 17
Location: Ottawa

PostPosted: Wed Feb 15, 2006 4:33 am    Post subject: Reply with quote

I have found many things use up a lot more memory on my 64 bit system. For example, the Gnome clock-applet uses 94M vs 22M on my 32 bit system. I assume this is because of longer pointers, but it is a bit hard to believe. The result of all this is that I use swap much more, and then the system in much slower than a 32 bit system. (One application I use frequently tends to use a lot of memory. I have only 1G memory, which would be reasonable with a 32 bit system, but does not seem nearly enough on the 64.) Am I doing something stupid?
Back to top
View user's profile Send private message
6D7474
Tux's lil' helper
Tux's lil' helper


Joined: 08 Sep 2005
Posts: 135

PostPosted: Wed Feb 15, 2006 11:12 am    Post subject: Reply with quote

pgilbert wrote:
I have found many things use up a lot more memory on my 64 bit system. For example, the Gnome clock-applet uses 94M vs 22M on my 32 bit system. I assume this is because of longer pointers, but it is a bit hard to believe. The result of all this is that I use swap much more, and then the system in much slower than a 32 bit system. (One application I use frequently tends to use a lot of memory. I have only 1G memory, which would be reasonable with a 32 bit system, but does not seem nearly enough on the 64.) Am I doing something stupid?


there is definitely sth strange with your system... i'm running 64bit gentoo and memory usage is sane (i have 1GB ram and system doesn't use swap at all) - it's really fast and responsive...
maybe post your "emerge info"..
also what kernel do you use?
is it only gnome-clock applet or other apps as well?

cheers
Back to top
View user's profile Send private message
pgilbert
n00b
n00b


Joined: 03 Dec 2005
Posts: 17
Location: Ottawa

PostPosted: Wed Feb 15, 2006 4:37 pm    Post subject: Reply with quote

It is not just the clock applet. Most things use more memory (but not all as extreme as the clock). On the 64 bit system with 1G running just Gnome, Firefox, Thunderbird, and a few shells the memory monitor typically shows about 90% of which 10% cache, whereas a 32 bit system with only 512M and the same apps shows 55% of which 25% cache.

Here is my emerge --info. If you see something strange I would really appreciate suggestions.

Code:
Portage 2.0.54 (default-linux/amd64/2005.1, gcc-3.4.4, glibc-2.3.5-r2, 2.6.14-gentoo-r2 x86_64)
=================================================================
System uname: 2.6.14-gentoo-r2 x86_64 AMD Athlon(tm) 64 X2 Dual Core Processor 4200+
Gentoo Base System version 1.6.14
distcc 2.18.3 x86_64-pc-linux-gnu (protocols 1 and 2) (default port 3632) [disabled]
dev-lang/python:     2.3.5-r2, 2.4.2
sys-apps/sandbox:    1.2.12
sys-devel/autoconf:  2.13, 2.59-r6
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r1
sys-devel/binutils:  2.16.1
sys-devel/libtool:   1.5.22
virtual/os-headers:  2.6.11-r2
ACCEPT_KEYWORDS="amd64"
AUTOCLEAN="yes"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-O2"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3/share/config /usr/lib/X11/xkb /usr/lib64/mozilla/defaults/pref /usr/share/config /usr/share/texmf/dvipdfm/config/ /usr/share/texmf/dvips/config/ /usr/share/texmf/tex/generic/config/ /usr/share/texmf/tex/platex/config/ /usr/share/texmf/xdvi/ /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-O2"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoconfig distlocks sandbox sfperms strict"
GENTOO_MIRRORS="http://64.50.236.52/ ftp://gentoo.mirrors.tds.net/gentoo http://gentoo.mirrors.tds.net/gentoo ftp://mirror.datapipe.net/gentoo"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="amd64 X alsa audiofile avi berkdb bitmap-fonts blas bzip2 cdr crypt cups dri dvd dvdr eds emboss encode esd exif expat f77 fam foomaticdb fortran gif glut gnome gpm gstreamer gtk gtk2 gtkhtml imagemagick imlib ipv6 java jpeg kde lcms libwww lzw lzw-tiff mng motif mozilla mp3 mpeg mysql ncurses nls nsplugin ogg opengl pam pdflib perl png python qt quicktime readline sdl spell ssl tcpd tetex tiff truetype truetype-fonts type1-fonts udev usb userlocales vorbis xine xml2 xmms xpm xv zlib userland_GNU kernel_linux elibc_glibc"
Unset:  ASFLAGS, CTARGET, LANG, LC_ALL, LDFLAGS, LINGUAS, MAKEOPTS, PORTDIR_OVERLAY

Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Gentoo on AMD64 All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum