News:

Masm32 SDK description, downloads and other helpful links
Message to All Guests
NB: Posting URL's See here: Posted URL Change

Main Menu

How to Know the Processor architecture?

Started by x64Core, June 27, 2012, 03:53:13 PM

Previous topic - Next topic

x64Core

Hello all  :biggrin: I would like know how to get the processor architecture, for example, know if it's 80386,80486,80586, etc
because if would want to use instructiones which  they are on a determined architecture... for example the xadd(80486) instruction, if I make an
application that uses that instruction but the application runs on 80386... :S

hey, thanks guys

MichaelW

Starting with the Pentium-class processors you can use CPUID. For the earlier processors you would need specialized code, but in recent times I think encountering a pre-Pentium processor in any sort of mainstream use is unlikely.
Well Microsoft, here's another nice mess you've gotten us into.

x64Core

Quote from: MichaelW on June 27, 2012, 04:25:14 PM
Starting with the Pentium-class processors you can use CPUID. For the earlier processors you would need specialized code, but in recent times I think encountering a pre-Pentium processor in any sort of mainstream use is unlikely.

thanks, MichaelW  :biggrin:
yeah you're right, I was searching the date of 80486... and I find this:
Producction 1989 — 1997

think anyone would have a computer older than that date lol

dedndave

you can narrow it down, according to which OS's you want to support

when i first started writing win32 code, i tried to make programs compatible with win95, or newer OS's
it is hard to make a lot of stuff win98 compatible - even harder to make it win95 compatible

so, now, i try to make programs compatible with win 2000 or newer

if they have win2000, they must have a pentium at least   :biggrin:

win95 will install on a 386 system (i think that's right - maybe a 486 is required)
win98 will install on a 486 system, FPU required (i know that's right)

Ryan

How many of the Windows API functions are even supported previous to Windows 2000?

I chose to look for something simple like GetWindowText on MSDN.  The minimum supported client is Windows 2000 Professional.  I tried some other functions.  I don't see any listed as being supported before Windows 2000.

MichaelW

QuoteI don't see any listed as being supported before Windows 2000.

Some time after Windows 9x passed end of life most of the references to it were eliminated from MSDN and the more recent PSDKs. According to my 2003 PSDK GetWindowText is supported all the way back to Windows 95 and Windows NT 3.1.
Well Microsoft, here's another nice mess you've gotten us into.

hutch--

Ryan,

Get a copy of win32.hlp, it goes back to Win95 OEM. Almost all of the API functions from that period still work on Win7 64 bit.

http://www.masmforum.com/winhelp_files/

dedndave

....i.e., you can't rely on what MSDN says about minimum supported OS
for example, CreateFile is documented as XP or newer
of course, CreateFile was probably available on windows 1.0   :P

it would really be nice if MSDN provided backwards documentation
at least win95/98 on up would be great
i suppose, if you searched around, you might be able to find the older MSDN library CD images