[ITP] cpuid

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

[ITP] cpuid

Brian Inglis
I would like to offer to package cpuid:

        dumps CPUID information about the CPU(s)

The program dumps detailed information about the CPU(s) gathered from
the CPUID instruction, and also determines the exact model of CPU(s).

Whereas /proc/cpuinfo is like an abstract of the features important to
Linux in a system, cpuid is a standalone utility which writes a paper
expounding on every feature in each CPU's architecture and what it can
do, at about the one line per bit level.

It is updated and released frequently and appears current with Intel and
AMD info and supports other vendors' chips.

It is available under major Linux and BSD flavours:
        https://pkgs.org/download/cpuid
        https://repology.org/project/cpuid/versions

See the project home page for more information:
        http://www.etallen.com/cpuid.html

Control files, sources, and binaries are available under the cpuid folder at:
        https://drive.google.com/open?id=1-79JVHv7kYQV4712vWHp5ZaVkfpnQYMY

The source needed minor tweaks to build on Cygwin and for packaging as
the main sources are one .c file and a Makefile.

--
Take care. Thanks, Brian Inglis, Calgary, Alberta, Canada

This email may be disturbing to some readers as it contains
too much technical detail. Reader discretion is advised.
Reply | Threaded
Open this post in threaded view
|

Re: [ITP] cpuid

marco atzeri-4
Am 22.02.2020 um 05:49 schrieb Brian Inglis:

> I would like to offer to package cpuid:
>
> dumps CPUID information about the CPU(s)
>
> The program dumps detailed information about the CPU(s) gathered from
> the CPUID instruction, and also determines the exact model of CPU(s).
>
> Whereas /proc/cpuinfo is like an abstract of the features important to
> Linux in a system, cpuid is a standalone utility which writes a paper
> expounding on every feature in each CPU's architecture and what it can
> do, at about the one line per bit level.
>

build fine, but while cpuid produces an output
cpuinfo2cpuid seems stack waiting for some inputs

any suggestion ?

In addition the cpu count 16 is baffling as i5-8250 is a 4+4 CPU

CPU 7:
       cpu count                      = 0x10 (16)
       0xff: cache data is in CPUID leaf 4
       index of CPU's row in feedback struct   = 0x0 (0)
    brand = "Intel(R) Core(TM) i5-8250U CPU @ 1.60GHz"
       number of CPU cores                 = 0x1 (1)
Reply | Threaded
Open this post in threaded view
|

Re: [ITP] cpuid

Brian Inglis
On 2020-02-21 23:24, Marco Atzeri wrote:

> Am 22.02.2020 um 05:49 schrieb Brian Inglis:
>> I would like to offer to package cpuid:
>>
>>     dumps CPUID information about the CPU(s)
>>
>> The program dumps detailed information about the CPU(s) gathered from
>> the CPUID instruction, and also determines the exact model of CPU(s).
>>
>> Whereas /proc/cpuinfo is like an abstract of the features important to
>> Linux in a system, cpuid is a standalone utility which writes a paper
>> expounding on every feature in each CPU's architecture and what it can
>> do, at about the one line per bit level.
>>
>
> build fine, but while cpuid produces an output
> cpuinfo2cpuid seems stack waiting for some inputs
>
> any suggestion ?

man cpuinfo2cpuid -- expects < /proc/cpuinfo and dumps a couple of fake raw regs
which you can feed back into cpuid to get a garrulously inaccurate report:

        $ cpuinfo2cpuid < /proc/cpuinfo | tee /dev/stderr | cpuid -f -

> In addition the cpu count 16 is baffling as i5-8250 is a 4+4 CPU
>
> CPU 7:
>       cpu count                      = 0x10 (16)
>       0xff: cache data is in CPUID leaf 4
>       index of CPU's row in feedback struct   = 0x0 (0)
>    brand = "Intel(R) Core(TM) i5-8250U CPU @ 1.60GHz"
>       number of CPU cores                 = 0x1 (1)

That cpu count and its neighbours are just a straight byte dump from CPUID fn 1
xfn 0 ebx - from MSB lapicid lpus clflsh brandid - look at cpuid -r third line
0x00000001 0x00: eax=... ebx= second MSB should be e.g. 0x00100801 - x10 -
compare /proc/cpuinfo for comparable cores and siblings counts:

        $ egrep 'cpu cores|siblings' /proc/cpuinfo

The 16 is (to us) inexplicable (and could be an erratum) but cores shown by
CPUID and the values are totally up to the Intel product line, its designers,
and how they see the topology and choose to indicate it.
Intel has come up with a bunch of random decisions and values over the years.
They and Microsoft make suitable partners, and both keep developers in work
handling pointless quirks!
AMD keeps mainly to their CPUID architecture manual, although compatibility with
Intel sometimes challenges that, but they often just reserve some bits used by
Intel and stick to their own way, which seems a lot more orthogonal and regular:
having an architecture manual, reading it, and using it will do that for you.

--
Take care. Thanks, Brian Inglis, Calgary, Alberta, Canada

This email may be disturbing to some readers as it contains
too much technical detail. Reader discretion is advised.
Reply | Threaded
Open this post in threaded view
|

Re: [ITP] cpuid

marco atzeri-4
Am 22.02.2020 um 17:59 schrieb Brian Inglis:

> On 2020-02-21 23:24, Marco Atzeri wrote:
>> Am 22.02.2020 um 05:49 schrieb Brian Inglis:
>>> I would like to offer to package cpuid:
>>>
>>>      dumps CPUID information about the CPU(s)
>>>
>>> The program dumps detailed information about the CPU(s) gathered from
>>> the CPUID instruction, and also determines the exact model of CPU(s).
>>>
>>> Whereas /proc/cpuinfo is like an abstract of the features important to
>>> Linux in a system, cpuid is a standalone utility which writes a paper
>>> expounding on every feature in each CPU's architecture and what it can
>>> do, at about the one line per bit level.
>>>

GTG , you can upload

Regards
Marco

Reply | Threaded
Open this post in threaded view
|

Re: [ITP] cpuid

Brian Inglis
On 2020-02-23 07:24, Marco Atzeri wrote:

> Am 22.02.2020 um 17:59 schrieb Brian Inglis:
>> On 2020-02-21 23:24, Marco Atzeri wrote:
>>> Am 22.02.2020 um 05:49 schrieb Brian Inglis:
>>>> I would like to offer to package cpuid:
>>>>
>>>>      dumps CPUID information about the CPU(s)
>>>>
>>>> The program dumps detailed information about the CPU(s) gathered from
>>>> the CPUID instruction, and also determines the exact model of CPU(s).
>>>>
>>>> Whereas /proc/cpuinfo is like an abstract of the features important to
>>>> Linux in a system, cpuid is a standalone utility which writes a paper
>>>> expounding on every feature in each CPU's architecture and what it can
>>>> do, at about the one line per bit level.
>>>>
>
> GTG , you can upload
Thanks Marco.

Could you please either post, or PM me (to save you time) or [hidden email]
directly, your anomalous cpuid display output log, plus the cpuid -r dump from
the same CPU, and the /proc/cpuinfo display output log, as Todd uses these to
refine cpuid operation and reporting, and none of these depend on any system
characteristics other than the processor and support chips.

Likewise, anyone else seeing anomalous results should also feel free to either
post, or PM me (to save you time) or [hidden email] directly, your anomalous
cpuid display output log, plus the cpuid -r dump from the same CPU, and the
/proc/cpuinfo display output log, for cpuid improvement.

Todd also welcomes non-anomalous results provided in all the forms above plus
any additional info or links relevant to that specific processor model directly
to [hidden email] for cpuid testing.

--
Take care. Thanks, Brian Inglis, Calgary, Alberta, Canada

This email may be disturbing to some readers as it contains
too much technical detail. Reader discretion is advised.