Doc Req: FeatureSet registry value w/ CentralProcessor?

Talk about code development, features, specific bugs, enhancements, patches, and similar things.
Forum rules
Please keep everything here strictly on-topic.
This board is meant for Pale Moon source code development related subjects only like code snippets, patches, specific bugs, git, the repositories, etc.

This is not for tech support! Please do not post tech support questions in the "Development" board!
Please make sure not to use this board for support questions. Please post issues with specific websites, extensions, etc. in the relevant boards for those topics.

Please keep things on-topic as this forum will be used for reference for Pale Moon development. Expect topics that aren't relevant as such to be moved or deleted.
User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 35631
Joined: 2011-08-28, 17:27
Location: Motala, SE
Contact:

Doc Req: FeatureSet registry value w/ CentralProcessor?

Unread post by Moonchild » 2013-07-21, 08:11

I'm using some basic processor detection in the Pale Moon installer, to determine which version of a software package should be available to the user.
Currently, I'm going through WMI to get some basic information, but I found out that doing that, I very regularly get unreliable results for the CPU features (CPUID is apparently poorly supported on a good number of mobile processors, and apparently some OS versions can bodge it up too when it comes to extended feature sets).

To avoid this kind of issue and to speed things up, I've been looking at getting the processor capabilities from the windows registry instead -- after all, the information should all be available there, under HKEY_LOCAL_MACHINE\HARDWARE\DESCRIPTION\System\CentralProcessor\{n}
Reading a key from the registry makes the installer much simpler in code, less likely to trip "nanny" software, doesn't have to call out to WMI (slow and can fail since I'd have to rely on calling out to a language like VBScript with WMI access, while registry operations are supported as standard in my development scripting language) and should avoid getting incorrect information from CPU value issues through it.

Sure, enough, I found a wealth of information, but the most important part, the "FeatureSet" value stored there, which I assume is a DWORD containing flags about available processor features like SIMD instruction sets etc., is not documented anywhere. I've spent a good while (understatement) searching the 'net now trying to find any sort of documentation about this registry value, to no avail.

Does anyone have a document outlining or describing the bits in that registry value?
"Sometimes, the best way to get what you want is to be a good person." -- Louis Rossmann
"Seek wisdom, not knowledge. Knowledge is of the past; wisdom is of the future." -- Native American proverb
"Linux makes everything difficult." -- Lyceus Anubite

dark_moon

Re: Doc Req: FeatureSet registry value w/ CentralProcessor?

Unread post by dark_moon » 2013-07-21, 10:13

Maybe this can help you: http://www.autoitscript.com/forum/topic ... ntry928963 and below.
(But this is for the AutoIt language), maybe C++ is better: http://msdn.microsoft.com/en-us/library ... 85%29.aspx

Realy hard to find infos about the FeatureSet value

User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 35631
Joined: 2011-08-28, 17:27
Location: Motala, SE
Contact:

Re: Doc Req: FeatureSet registry value w/ CentralProcessor?

Unread post by Moonchild » 2013-07-21, 10:41

dark_moon wrote:Maybe this can help you: http://www.autoitscript.com/forum/topic ... ntry928963 and below.
"[5] = Feature Set (unsure what values are which..)"
I already know how to find it and how to pull it from the registry. But the feature set is what i need info on.
I'm familiar with other detection methods but that's not what I'm looking for. I can't use the C++ method unless I have the installer call a separate compiled detection .exe with C++ code in it, which is something I want to avoid as well (in fact that would be slower than the current method I use, most likely, and easier to go wrong on systems with malware-nannybots running).
Realy hard to find infos about the FeatureSet value
Yup, that's what I found out. Not sure why it's not clearly documented, not even in MSDN/technet, etc.

Popped a question to Microsoft Support directly as well.
"Sometimes, the best way to get what you want is to be a good person." -- Louis Rossmann
"Seek wisdom, not knowledge. Knowledge is of the past; wisdom is of the future." -- Native American proverb
"Linux makes everything difficult." -- Lyceus Anubite


User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 35631
Joined: 2011-08-28, 17:27
Location: Motala, SE
Contact:

Re: Doc Req: FeatureSet registry value w/ CentralProcessor?

Unread post by Moonchild » 2013-07-21, 12:13

No, that's not what I'm looking for, since the FeatureSet value in the registry is not a direct representation of the CPUID function results. If it was, I wouldn't have had such a hard time :P -- Try comparing those values with your own registry entry for your CPU and you'll see.

EDIT: mine is 203b7dfe
That would mean No FPU, no 3dNow, no PAE, no APIC... on a Phenom II? I don't think so ;)
"Sometimes, the best way to get what you want is to be a good person." -- Louis Rossmann
"Seek wisdom, not knowledge. Knowledge is of the past; wisdom is of the future." -- Native American proverb
"Linux makes everything difficult." -- Lyceus Anubite


User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 35631
Joined: 2011-08-28, 17:27
Location: Motala, SE
Contact:

Re: Doc Req: FeatureSet registry value w/ CentralProcessor?

Unread post by Moonchild » 2013-07-21, 16:23

No, it's not the CPUID result.

The installer uses scripting language (internal scripting, plus additional jscript or vbscript) and does NOT have access to WinAPI calls, assembly language, external dll calls, or whatnot. It's only because of VBScript's access to WMI that I get this far now, but reading a registry key/value is basic. I just need to know what the FeatureSet exactly contains.
"Sometimes, the best way to get what you want is to be a good person." -- Louis Rossmann
"Seek wisdom, not knowledge. Knowledge is of the past; wisdom is of the future." -- Native American proverb
"Linux makes everything difficult." -- Lyceus Anubite

dark_moon

Re: Doc Req: FeatureSet registry value w/ CentralProcessor?

Unread post by dark_moon » 2013-07-21, 16:46

Maybe we can give it a try:

I have this value: 0x215b3ffe
My Intel Core 2 Quad Q9550 have MMX, SSE, SSE2, SSE3, SSSE3, SSE4.1, EM64T, VT-x

How to get this infos:
type cmd in windows startmenu or press windows button + r on your keyboard and type cmd
Then paste this code in this open window:
reg query HKEY_LOCAL_MACHINE\HARDWARE\DESCRIPTION\System\CentralProcessor\0
Look for the FeatureSet value

To know which Instructions your CPU use, you can simple run CPU-Z: http://www.cpuid.com/downloads/cpu-z/1.65-en.zip (portable edition- no install required)

User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 35631
Joined: 2011-08-28, 17:27
Location: Motala, SE
Contact:

Re: Doc Req: FeatureSet registry value w/ CentralProcessor?

Unread post by Moonchild » 2013-07-21, 17:03

So, exactly how many different systems would we need to figure out by deduction what is what? :P

I think it's rather silly. it's been in the windows registry since.. I think Win2000. And nobody has a record or idea what is stored in this value?...
"Sometimes, the best way to get what you want is to be a good person." -- Louis Rossmann
"Seek wisdom, not knowledge. Knowledge is of the past; wisdom is of the future." -- Native American proverb
"Linux makes everything difficult." -- Lyceus Anubite

Blacklab
Board Warrior
Board Warrior
Posts: 1081
Joined: 2012-06-08, 12:14

Re: Doc Req: FeatureSet registry value w/ CentralProcessor?

Unread post by Blacklab » 2013-07-21, 17:25

I see you have spent "good while (understatement)" on this one - 2nd item in search results was your MS Community topic: Documentation for the FeatureSet registry key under HKLM CentralProcessor? One of the replies to this stackoverflow query had found the same problem... "however that key is pretty cryptic (I haven't found specific information about it)"
Last edited by Blacklab on 2013-07-21, 17:33, edited 1 time in total.

User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 35631
Joined: 2011-08-28, 17:27
Location: Motala, SE
Contact:

Re: Doc Req: FeatureSet registry value w/ CentralProcessor?

Unread post by Moonchild » 2013-07-21, 17:32

You'll probably also find the entry I made on StackOverflow if you search :P
"Sometimes, the best way to get what you want is to be a good person." -- Louis Rossmann
"Seek wisdom, not knowledge. Knowledge is of the past; wisdom is of the future." -- Native American proverb
"Linux makes everything difficult." -- Lyceus Anubite

Locked