Article View: net.micro.pc
Article #5998Re: Identifying an iAPX series processo
From: kevin
Date: Wed, 19 Mar 1986 22:43
Date: Wed, 19 Mar 1986 22:43
22 lines
1587 bytes
1587 bytes
> Question: is it possible to identify in software the type of processor
> a program is running on (assuming MS-DOS here...)? I would like to
> know whether it's an 8088, 8086, 80188, 80186 or an 80286. If it
> is possible, how do I do it?
Yes, it is possible, at least to distinguish between {8086|8088},
{80186|80188}, and 80286 flavors of processors. The 8086 (and the 8088,
I guess) don't mask shift counts, so if you shift a 2 in AX by a number
of places greater than 16 (?or 32, maybe -- 32 works for sure) you'll
get a zero. On the 186 and 286 you'll get a non-zero value. To
distinguish between the 186 and the 286, do a PUSH SP, pop it into
another register and compare it. The 186 pushes the SP value *after*
it's been decremented, the 286 pushes the SP value *before* it's
decremented.
I don't know if you can tell if you're on a *8 or *6 version processor,
though.
Good luck!
Kevin Dack
..ctvax!trsvax!kevin
Technical Details
Message-ID:
<53500027@trsvax>Path:
arc1-ca.pugleaf.net!utzoo!watmath!clyde!burl!ulysses!mhuxr!mhuxn!ihnp4!inuxc!pur-ee!uiucdcs!convex!trsvax!kevinReferences:
<7901@watrose.UUCP>Show Full Headers
Complete Article Headers
Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: Notesfiles $Revision: 1.7.0.10 $; site trsvax Path: arc1-ca.pugleaf.net!utzoo!watmath!clyde!burl!ulysses!mhuxr!mhuxn!ihnp4!inuxc!pur-ee!uiucdcs!convex!trsvax!kevin From: kevin@trsvax Newsgroups: net.micro.pc Subject: Re: Identifying an iAPX series processo Message-ID: <53500027@trsvax> Date: Wed, 19-Mar-86 17:43:00 EST Article-I.D.: trsvax.53500027 Posted: Wed Mar 19 17:43:00 1986 Date-Received: Sat, 22-Mar-86 14:14:41 EST References: <7901@watrose.UUCP> Lines: 22 Nf-ID: #R:watrose.UUCP:7901:trsvax:53500027:000:929 Nf-From: trsvax!kevin Mar 19 16:43:00 1986