News:

Masm32 SDK description, downloads and other helpful links
Message to All Guests

Main Menu

Instruction Set Detection for Linux, BSD and Mac OS

Started by Gunther, May 09, 2014, 04:17:01 AM

Previous topic - Next topic

Gunther

This is the instruction set detection for the 64-bit *nixes (Linux, BSD, Mac OS). The appropriate 64-bit Windows version can be found here, a 32-bit Windows version exists here. A new thread is necessary, because the 64-bit ABIs for Unix and Windows are very different.

For a detailed description of the files, please check the file readme.txt. The code is well commented and self-explanatory. Here is the output of the program:
Quote
   Supported Features by Processor and Operating System
   ====================================================

Vendor String: GenuineIntel
Brand  String: Intel(R)Core(TM)i7-3770CPU@3.40GHz

   Instruction Sets
   ----------------

MMX  SSE  SSE2  SSE3  SSSE3  SSE4.1  SSE4.2  AVX

   Supported Special Instructions
   ------------------------------

Conditional Moves
FXSAVE and FXSTOR
XSAVE and XSTOR for processor extended state management.
POPCNT
RDRAND
AES (Advanced Encryption Standard) Instruction Set
16-bit floating-point Conversion Instructions

Please, press enter to end the application ...


Your help and test results are very welcome.

Gunther
You have to know the facts before you can distort them.

Gunner

Quote~/projects/64/IsetUnix $ ./cpu
   Supported Features by Processor and Operating System
   ====================================================

Vendor String: AuthenticAMD
Brand  String: AMDPhenom(tm)IIX4955Processor

   Instruction Sets
   ----------------

MMX  SSE  SSE2  SSE3

   Supported Special Instructions
   ------------------------------

Conditional Moves
FXSAVE and FXSTOR

Please, press enter to end the application ...

A FYI, when unzipped, the exe lost the executable permission.
Quotels -l ./cpu
-rw-r--r-- 1 gunner gunner 14090 May  8 19:22 ./cpu

Maybe use tar for your *NIX archives?
~Rob

Gunther

Gunner,

thank you for testing the software.

Quote from: Gunner on May 09, 2014, 11:32:49 AM
A FYI, when unzipped, the exe lost the executable permission.
Quotels -l ./cpu
-rw-r--r-- 1 gunner gunner 14090 May  8 19:22 ./cpu

Maybe use tar for your *NIX archives?

yes, you're right. I should form a tar ball, which can be ziped, to meet the requirements of our forum.

Gunther
You have to know the facts before you can distort them.

dedndave

Quote from: Gunther on May 10, 2014, 01:51:58 AM
I should form a tar ball...

you LINUX guys crack me up   :lol:

hey Rob !!! long time no see   :t

Gunther

You have to know the facts before you can distort them.

DarkWolf

Hey gunther
on my system I get this error.

Which is weird cause I never had a problem running a exe in my home folder (or subfolder) before.

$ ./cpu
bash: ./cpu: cannot execute binary file

Gunther

Hi DarkWolf,

Quote from: DarkWolf on June 13, 2014, 11:39:51 AM
Hey gunther
on my system I get this error.

Which is weird cause I never had a problem running a exe in my home folder (or subfolder) before.

$ ./cpu
bash: ./cpu: cannot execute binary file

That's very strange. But you can re-build the ELF and it should start. Can you try this?

Gunther
You have to know the facts before you can distort them.