Find the answer to your Linux question:
Results 1 to 3 of 3
Short introduction: my PC processor is an AMD64-whatever. I have had debian etch installed for that architecture for one or two weeks, but apparently it was slightly worse than the ...
  1. #1
    Linux Newbie
    Join Date
    Apr 2007
    Posts
    211

    Kernels, processor architectures and program packages

    Short introduction: my PC processor is an AMD64-whatever. I have had debian etch installed for that architecture for one or two weeks, but apparently it was slightly worse than the previous installation I had, which I believe, was etch for a i386 architecture.

    I decided to reinstall etch for i386, but acidentally (little mistake while trying to install through a netinst from HD) a 2.6.18-6-k7 (i686) was installed. Apparently it was selected by the minimal installer, business-card like. Could be that I downloaded the wrong "bare installer" kernel, but I don't think so, the ftp folder was i386, i686, or i86, whatever, without -k7. And it's working, if that really means anything.

    Now the actual questions:

    Assuming that it was correctly chosen by the installation process, for future updates (like 2.6.20 required for ntfs-3g) should I prefer to keep with "-k7" images, if they exist?

    There are different program packages for amd64 and i386 (actually, I never know wheter it is i3 or i686... I miss the old times with less sorts of different things), do they differ also between -k7 and "generic" architectures?

  2. #2
    Linux Guru techieMoe's Avatar
    Join Date
    Aug 2004
    Location
    Texas
    Posts
    9,496
    Quote Originally Posted by the dsc View Post
    There are different program packages for amd64 and i386 (actually, I never know wheter it is i3 or i686... I miss the old times with less sorts of different things), do they differ also between -k7 and "generic" architectures?
    I don't know the difference between i686 and i686-k7 when referring to Debian kernels, but there's most definitely a difference between the amd64 and X86 kernels.

    i286,i386,i486,i586 and i686 (collectively called X86) are all 32-bit Intel-compatible kernels. They will work on just about any processor on the market, from a 486 to a Core 2 Duo or an AMD K-series all the way to an AMD64 X2.

    The amd64 kernels are 64-bit kernels designed for AMD64-compatible chips, which include the Intel Core 2 Duo and AMD64 series.
    Registered Linux user #270181
    TechieMoe's Tech Rants

  3. #3
    Linux Guru
    Join Date
    Nov 2007
    Location
    Córdoba (Spain)
    Posts
    1,513
    Quote Originally Posted by the dsc View Post
    I decided to reinstall etch for i386, but acidentally (little mistake while trying to install through a netinst from HD) a 2.6.18-6-k7 (i686) was installed. Apparently it was selected by the minimal installer, business-card like. Could be that I downloaded the wrong "bare installer" kernel, but I don't think so, the ftp folder was i386, i686, or i86, whatever, without -k7. And it's working, if that really means anything.
    When in doubt about architectures and such, the best way is usually to look into the gcc man page. If you haven't gcc installed, google for "man gcc". There you will learn that, in which regards the linux compiler.

    In this case, k7 means that the compiler will be using -march=athlon or any of it's variants (athlon, athlon-tbird, athlon-4, athlon-xp, athlon-mp as of gcc 4.2, which is the one I have installed).

    Object code compiled for K7 *is not* compatible with x86 cpu's. The opposite is true, though. So, you will have no problem running software compiled for x86 on an amd64 cpu working on 32 bits mode, because these cpus default to the k7 instruction set when not in 64 bits mode.

    But you can't run this k7 kernel on a pentium classic, for example.

    There's no harm in running the i686 kernel instead. It will run without using all the features that your cpu is capable of. But I doubt that you will be able to notice that. "Optimizations" are often overrated.


    Now the actual questions:

    Assuming that it was correctly chosen by the installation process, for future updates (like 2.6.20 required for ntfs-3g) should I prefer to keep with "-k7" images, if they exist?
    Your amd64 cpu is capable of running k7 kernel. And they will perform better than i686 ones because they are more specific to your cpu.

    When gcc compiles for i686 (-march=i686) it uses the pentium-pro (basically the same thing that pentium2 but without mmx). When you use -march=athlon instead, it optimizes for k7 cpus, and includes support for mmx, 3dnow, 3dnowext and sse. As I say, you will hardly notice this. But in some applications (mencoder is a classic at this) that makes intensive use of these instructions, it will for sure make a difference. Of course, the application needs to be compiled to support this as well, which is not always true on binary distros.

    There are different program packages for amd64 and i386 (actually, I never know wheter it is i3 or i686... I miss the old times with less sorts of different things), do they differ also between -k7 and "generic" architectures?
    I386 is the old 386 cpu by intel (the first 32 bits cpu on pcs). i686 is pentium-pro/II. Searching in the wikipedia about cpus you can find many interesting pages about processors.

    You can run i386 binaries on any 32 bits cpu (pc architecture, of course). Nowadays, x86 and i386 have come to mean mostly the same. When we speak about x86, we are talking about the i386 instruction set. If a given app is x86 compatible, it should work (without needing recompilation) on any cpu from 386 to amd64 (in 32 bits mode).

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
...