News:

MASM32 SDK Description, downloads and other helpful links
MASM32.com New Forum Link
masmforum WebSite

CPUID test piece.

Started by hutch--, April 23, 2010, 06:27:50 AM

Previous topic - Next topic

hutch--

I have the attached test piece tested on the hardware I have running here but there are old timers and AMD hardware that I don't have access at so if it is not to much innconvenience, I would appreciate people with different hardware to test this app and publish the results for each processor they have available.

These are the results I have on the Intel hardware I have running. 0 means not available, 1 means instruction set IS available.


GenuineIntel
Intel(R) Core(TM) i7 CPU         860  @ 2.80GHz
1 SSE 4.2
1 SSE 4.1
1 SSE 3
1 SSE 2
1 SSE
1 MMX
Press any key to continue ...

GenuineIntel
Intel(R) Core(TM)2 Quad CPU    Q9650  @ 3.00GHz
0 SSE 4.2
1 SSE 4.1
1 SSE 3
1 SSE 2
1 SSE
1 MMX
Press any key to continue ...

GenuineIntel
Genuine Intel(R) CPU 3.80GHz
0 SSE 4.2
0 SSE 4.1
1 SSE 3
1 SSE 2
1 SSE
1 MMX
Press any key to continue ...
Download site for MASM32      New MASM Forum
https://masm32.com          https://masm32.com/board/index.php

jj2007

GenuineIntel
Intel(R) Celeron(R) M CPU        420  @ 1.60GHz
0 SSE 4.2
0 SSE 4.1
1 SSE 3
1 SSE 2
1 SSE
1 MMX

:U

MichaelW

P3:

GenuineIntel
☺☺☻♥
0 SSE 4.2
0 SSE 4.1
0 SSE 3
0 SSE 2
1 SSE
1 MMX
eschew obfuscation

hutch--

My young brother can be useful occasionally, tested it on 2 AMD machines.


AuthenticAMD
AMD Athlon(tm) 64 X2 Dual Core Processor 6000+
0 SSE 4.2
0 SSE 4.1
1 SSE 3
1 SSE 2
1 SSE
1 MMX


The next one is unusual, its an AMD Sempron that gave unusual results with the long ID string.
CPUZ says its a AMD Sempron LE-1150 (Sparta) Socket AM2(940)


AuthenticAMD
AMD Processor model unknown
0 SSE 4.2
0 SSE 4.1
1 SSE 3
1 SSE 2
1 SSE
1 MMX
Download site for MASM32      New MASM Forum
https://masm32.com          https://masm32.com/board/index.php

Vortex

Intel(R) Pentium(R) 4 CPU 3.20GHz
0 SSE 4.2
0 SSE 4.1
1 SSE 3
1 SSE 2
1 SSE
1 MMX

clive

GenuineIntel
Intel(R) Atom(TM) CPU N270   @ 1.60GHz
0 SSE 4.2
0 SSE 4.1
1 SSE 3
1 SSE 2
1 SSE
1 MMX
It could be a random act of randomness. Those happen a lot as well.

rags


AuthenticAMD
AMD Athlon(tm) II X2 215 Processor
0 SSE 4.2
0 SSE 4.1
1 SSE 3
1 SSE 2
1 SSE
1 MMX
God made Man, but the monkey applied the glue -DEVO

dedndave

prescott
GenuineIntel
Intel(R) Pentium(R) 4 CPU 3.00GHz
0 SSE 4.2
0 SSE 4.1
1 SSE 3
1 SSE 2
1 SSE
1 MMX

FORTRANS

Hi,


Pentium III Windows 2000

GenuineIntel
☺☺☻♥
0 SSE 4.2
0 SSE 4.1
0 SSE 3
0 SSE 2
1 SSE
1 MMX
Press any key to continue ...

Pentium MMX Windows 98

CPUFIX caused an invalid page fault in
module CPUFIX.EXE at 0167:0040133e.
Registers:
<snip>

Celeron Windows XP

GenuineIntel
Mobile Intel(R) Celeron(R) processor     600MHz
0 SSE 4.2
0 SSE 4.1
0 SSE 3
1 SSE 2
1 SSE
1 MMX
Press any key to continue ...


Steve

hutch--

I have done some work on the earlier one, this one calls each routine and returns results that are not printed locally in each proc. I used a suggestion of Dave's to try and pick up the earlier processors from PIIIs back to later 486s. problem is I have no way of testing old timers as I no longer have any that will run.

I get these types of results on the boxes I am using.


Manufacturer = GenuineIntel

Model ID string = Intel(R) Core(TM)2 Quad CPU    Q9650  @ 3.00GHz

Supported Instruction Sets
SSE4.2 NO
SSE4.1 YES
SSE3   YES
SSE2   YES
SSE    YES
MMX    YES
Press any key to continue ...


I don't target anything earlier than Win2000 but I would be interested to see how this version works on PIIIs and earlier. The processor cutoff will probably be something late enough to run Win2000 but I do not expect that it will run correctly on earlier hardware or win9x series OS versions.
Download site for MASM32      New MASM Forum
https://masm32.com          https://masm32.com/board/index.php

dedndave

the worst OS for this stuff is Windows CE (for embedded systems)
on the plus side, you'd think they already know what CPU they have if they developed an embedded system - lol

the problem is - some versions of CE are "buildable" and the designer has the opportunity
to trim down the OS - i don't know what that entails, nor was i able to find a clear answer for
whether or not CE supports multiple cores
i suspect, in the near future, it will have to

muliple cores means there is a possibility that CPUID will execute on one package one time
and another package the next time - however likely or unlikely
with most motherboards, the packages are the same device, so it makes no real difference unless you are reading cache parms
there are a few instances where the packages may be different, however
that makes it a good idea to affinitize to a single core, i think

if a programmer is to use this routine in an app that is distributed, he may want it to work on all systems

hutch--

Dave,

The only part of the example that I see as important is the available instruction sets and its primarily so a program can choose whether it uses SSE2 or SSE4.1 rather than and real interest in the old stuff, most of which cannot run Win2000 or later. Microsoft will shortly pension off XP SP3 so I don't see the point of wasting the effort on very early AMD or Cyrix hardware.

The ID strings are OK as headings on sysinfo dialogs but they are not much real use in determining if you can use an SSE instruction or not.
Download site for MASM32      New MASM Forum
https://masm32.com          https://masm32.com/board/index.php

dioxin

Hutch,
your tests aren't exhaustive. The Phenom has SSE4a (not SSE4.1 or SSE4.2)
The K6-III has 3DNow!
Neither of these is detected in your tests but maybe you aren't interested in looking for them.

Paul.

Phenom X4 945
AuthenticAMD

AMD Phenom(tm) II X4 945 Processor

0             SSE 4.2
0             SSE 4.1
1             SSE 3
1             SSE 2
1             SSE
1             MMX



Intel Atom N270
GenuineIntel

         Intel(R) Atom(TM) CPU N270   @ 1.60GHz

0             SSE 4.2
0             SSE 4.1
1             SSE 3
1             SSE 2
1             SSE
1             MMX




Intel Celeron
GenuineIntel

Intel(R) Celeron(R) M processor          900MHz

0             SSE 4.2
0             SSE 4.1
0             SSE 3
1             SSE 2
1             SSE
1             MMX




AMD Athlon XP (Barton)
AuthenticAMD

AMD Athlon(tm) XP 2600+

0             SSE 4.2
0             SSE 4.1
0             SSE 3
0             SSE 2
1             SSE
1             MMX




AMD k6-III
AuthenticAMD

AMD-K6(tm) 3D+ Processor

0             SSE 4.2
0             SSE 4.1
0             SSE 3
0             SSE 2
0             SSE
1             MMX

clive

Some of the older chips (pre CPUID) could be identified by looking at things like the barrel shift, flag bits, prefetch queue size (self modifying code). For instance the the 386DX and 386SX could be identified by different prefetch queue sizes. I need to dig up the DOS code I had that would identifiy 8080/86,V20/30 thru Pentium III Coppermine.
It could be a random act of randomness. Those happen a lot as well.

FORTRANS

Hi,


Pentium III Windows 2000

Model ID string = Pentium Pro, II or Celeron Processor

Supported Instruction Sets
SSE4.2 NO
SSE4.1 NO
SSE3   NO
SSE2   NO
SSE    YES
MMX    YES
Press any key to continue ...
Manufacturer = GenuineIntel

Pentium MMX  Windows 98

Model ID string = i486 or early Pentium Processor

Supported Instruction Sets
SSE4.2 NO
SSE4.1 NO
SSE3   NO
SSE2   NO
SSE    NO
MMX    YES
Press any key to continue ...


Cheers,

Steve N.