A simple CPUID decoder/dumper for x86/x86_64
C Python Makefile C++
Latest commit b7bb8dd Jun 24, 2017 @tycho SConstruct: remove -lrt on non-Linux platforms
Not even sure if it's still necessary on a modern glibc, but retaining it for
the Travis builders

Signed-off-by: Steven Noonan <steven@uplinklabs.net>
Permalink
Failed to load latest commit information.
getopt add NO_GNU_GETOPT make flag, fix GCC warnings Jul 31, 2011
msvc threads.{c,h}: support up to 64 processors Oct 18, 2011
tools CPUID v1.4.5 Mar 17, 2016
.gitignore msvc: add Visual C++ 6.0 project Aug 15, 2011
.travis.yml travis: add build notifications via pushover Mar 23, 2016
COPYING update all copyright headers Feb 18, 2015
COPYING.asc update all copyright headers Feb 18, 2015
CPUID.dsw msvc: add Visual C++ 6.0 project Aug 15, 2011
CPUID.sln msvc: adding visual c++ support Jul 31, 2011
GNUmakefile GNUmakefile: fix optimization level Mar 17, 2016
README README: updated to be a bit more useful and verbose Nov 22, 2011
SConstruct SConstruct: remove -lrt on non-Linux platforms Jun 23, 2017
cache.c make code compatible with C++ standards Feb 18, 2015
cache.h update all copyright headers Feb 18, 2015
clock.c make code compatible with C++ standards Feb 18, 2015
clock.h update all copyright headers Feb 18, 2015
cpuid.c update all copyright headers Feb 18, 2015
cpuid.h update all copyright headers Feb 18, 2015
feature.c feature: add missing bits from latest Intel manuals Feb 24, 2017
feature.h update all copyright headers Feb 18, 2015
handlers.c handlers: fix xsave leaf names in handle_std_ext_state Jun 23, 2017
handlers.h implement support for overriding processor vendor string on command line Mar 17, 2016
main.c implement support for overriding processor vendor string on command line Mar 17, 2016
platform.h platform.h: update copyright Feb 8, 2015
prefix.h make code compatible with C++ standards Feb 18, 2015
sanity.c make code compatible with C++ standards Feb 18, 2015
sanity.h update all copyright headers Feb 18, 2015
state.h cpuid state: fix memory leak when loading from dump file Oct 19, 2015
threads.c thread_bind_native: don't dereference a NULL state Nov 4, 2015
threads.h update all copyright headers Feb 18, 2015
util.c update all copyright headers Feb 18, 2015
util.h handlers: use better bounds checking for xsave feature identification Oct 19, 2015
vendor.h vmm: add Parallels vendor string match Mar 11, 2016
version.c update all copyright headers Feb 18, 2015
version.h update all copyright headers Feb 18, 2015

README

"cpuid" is a very simple C program, designed to dump and extract information
from the x86 CPUID instruction.

cpuid is capable of dumping all CPUID leaves (except any unknown leaves which
require special ECX values to dump all information). cpuid can only decode
certain leaves, but this functionality will be expanded as the CPUID
specifications provided by AMD and Intel change.


BUILDING
========

The build process is simplified compared to a plethora of other open source
projects out there. You don't need autoconf/automake or any of the headaches
that go along with those tools.

Required:
- C compiler (GNU C Compiler, Microsoft Visual C++, and the Intel C++
  Compiler are known to work)
- Perl 5.8 or later

And one of:
- GNU Make 3.80 or later
- SCons 2.0 or later

Depending on whether you have GNU Make or SCons, do one of:

$ scons

or

$ make

And you should have a new executable called 'cpuid' in a few seconds.


USING
=====

Since the usage will likely change over time, I recommend that you take a look
at the output of:

$ ./cpuid --help


REPORTING BUGS
==============

If you find a bug in CPUID, please submit details about it to the bug tracker
on GitHub:

https://github.com/tycho/cpuid/issues

If the bug is regarding the decoding or dumping of CPUID details, then you
should include the dump.txt and decode.txt generated with these commands:

$ ./cpuid -d -c -1 > dump.txt
$ ./cpuid -c -1 > decode.txt

You should also specify what revision of CPUID you are running. If you don't
know, you can find out with:

$ ./cpuid --version


REFERENCE DOCUMENTATION
=======================

You can find current Intel and AMD CPUID specifications at these locations:

http://www.intel.com/content/www/us/en/processors/processor-identification-cpuid-instruction-note.html
http://support.amd.com/us/Embedded_TechDocs/25481.pdf

I try to keep up with these as they change, but sometimes I'm slow on the
uptake. Please notify me if you notice any inconsistencies or if features you
find relevant are not being decoded.


CONTACT
=======

I'm contactable via email and respond frequently.

Steven Noonan <steven@uplinklabs.net>