Skip to contentSkip to conversation

initramfs programs (was [RFC] klibc requirements)

DISCUSSION Giacomo Catenazzi 4 participants 8 messages Jan 10, 2002 1 message not in the archive

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): [email protected]

#1 lore raw
Quoted 9 lines · Dave Jones
Quoted 3 lines · Alan Cox

We've also proved the DMI data is too unreliable to be used, so the entire problem space is irrelevant

That's not a problem, remember Eric volunteered to maintain the enormous black list 8-)

Surelly I will not maintain the DMI table!
It is already difficult to maintain the database of CPU. The newer CPUs have name stored directly in CPU and no more in kernel :-(

(
This is a call for help: how to write a table CPU - CONFIG_SYMBOL ?
Now I use Vendor/Name/Family/Stepping/, but maybe with Vendor + flags (CPUID flags) the result will be more correct?

Other suggestions?

giacomo

#2 lore raw
Quoted 1 line

Surelly I will not maintain the DMI table!

Quite

Quoted 5 lines

This is a call for help: how to write a table CPU - CONFIG_SYMBOL ?
Now I use Vendor/Name/Family/Stepping/, but maybe with Vendor + flags (CPUID flags) the result will be more correct?

You need the family/model information to get the right optimisations. Its often not that the instruction set is different but that the cpu implementation is different that determines the choice. With a couple of exceptions cpu type is actually not too important and accidentally using 486 will make little difference

#3 lore raw
Quoted 13 lines · Alan Cox
Quoted 2 lines

Surelly I will not maintain the DMI table!

Quite

Quoted 6 lines

This is a call for help: how to write a table CPU - CONFIG_SYMBOL ?
Now I use Vendor/Name/Family/Stepping/, but maybe with Vendor + flags (CPUID flags) the result will be more correct?

Quoted 5 lines

You need the family/model information to get the right optimisations. Its
often not that the instruction set is different but that the cpu
implementation is different that determines the choice. With a couple of exceptions cpu type is actually not too important and accidentally using 486 will make little difference

Something I'd really like to see would be to split "optimize for..." and "run on..." for CPU type; just like gcc has -mmach= and -march=.

-hpa

#4 lore raw
In reply to Giacomo Catenazzi
Quoted 3 lines · Giacomo Catenazzi

It is already difficult to maintain the database of CPU. The newer CPUs have name stored directly in CPU and no more in kernel :-(

It's worse than you think.
Distinguishing between XP and MP athlon for example needs capability bit testing. (And some XP's _are_ now multiprocessor capable, just to confuse the issue some more), so relying on the cpuid identity string isn't foolproof.
(Also, some implementations allow for this string to be changed,
some folks have it set to "PenguinPowered" and the likes 8-)

Quoted 5 lines

This is a call for help: how to write a table CPU - CONFIG_SYMBOL ?
Now I use Vendor/Name/Family/Stepping/, but maybe with Vendor + flags (CPUID flags) the result will be more correct?

Asides from the above issues, multiple CPUs have the same cpuid sometimes, meaning you have to check things like cache size as well (though most (all?) of these should end up with the same CONFIG_ option iirc, so this shouldn't be an issue -- you should check to be sure though)

x86info's identify.c files should give you a fairly comprehensive guide to the various types.

Signature · 2 lines
| Dave Jones.        http://www.codemonkey.org.uk
| SuSE Labs
#5 lore raw
Quoted 9 lines · Dave Jones

It's worse than you think.
Distinguishing between XP and MP athlon for example needs capability bit testing. (And some XP's _are_ now multiprocessor capable, just to confuse the issue some more), so relying on the cpuid identity string isn't foolproof.
(Also, some implementations allow for this string to be changed,
some folks have it set to "PenguinPowered" and the likes 8-)

Sure, but if you do that you're *asking*, in a very literal way, for your CPU to misidentified. In fact, a major reason for making this string modifiable is due to certain vendors who hard-code CPUID strings in their code.

Quoted 7 lines

Asides from the above issues, multiple CPUs have the same cpuid sometimes, meaning you have to check things like cache size as well (though most (all?) of these should end up with the same CONFIG_ option iirc, so this shouldn't be an issue -- you should check to be sure though)

Why -- if it doesn't change anything, all you're doing is making it confusing when the next derivative appears. Remember that we *do* need,
as much as possible, to be forward compatible with future CPUs.

Quoted 2 lines

x86info's identify.c files should give you a fairly comprehensive guide to the various types.

-hpa

#6 lore raw
Quoted 6 lines · H. Peter Anvin
Quoted 2 lines

(Also, some implementations allow for this string to be changed,
some folks have it set to "PenguinPowered" and the likes 8-)

Sure, but if you do that you're *asking*, in a very literal way, for your CPU to misidentified. In fact, a major reason for making this string modifiable is due to certain vendors who hard-code CPUID strings in their code.

Absolutely, no argument from me there.

Quoted 8 lines
Quoted 5 lines

Asides from the above issues, multiple CPUs have the same cpuid sometimes, meaning you have to check things like cache size as well (though most (all?) of these should end up with the same CONFIG_ option iirc, so this shouldn't be an issue -- you should check to be sure though)

Why -- if it doesn't change anything, all you're doing is making it confusing when the next derivative appears. Remember that we *do* need,
as much as possible, to be forward compatible with future CPUs.

If every combination for a given cpuid translates to the same CONFIG_ option, fine. I'm just not sure from memory if thats the case or not. The various Celeron/PIII's for example, some have SSE, some don't. Assuming Intel cpuid xxx translates to CONFIG_PENTIUMIII would break if thats the case.

Signature · 2 lines
| Dave Jones.        http://www.codemonkey.org.uk
| SuSE Labs
#7 lore raw
Quoted 7 lines · Dave Jones

If every combination for a given cpuid translates to the same CONFIG_ option, fine. I'm just not sure from memory if thats the case or not. The various Celeron/PIII's for example, some have SSE, some don't. Assuming Intel cpuid xxx translates to CONFIG_PENTIUMIII would break if thats the case.

Right, which is why you should look at the SSE feature flag and nothing else.

-hpa

#8 lore raw
Quoted 2 lines · H. Peter Anvin

Right, which is why you should look at the SSE feature flag and nothing else.

Agreed.

Signature · 2 lines
| Dave Jones.        http://www.codemonkey.org.uk
| SuSE Labs