Programming Forums
User Name Password Register
 

RSS Feed
FORUM INDEX | TODAY'S POSTS | UNANSWERED THREADS | ADVANCED SEARCH

Reply
 
Thread Tools Display Modes
Old Apr 18th, 2007, 2:17 PM   #1
Lesliect6
Programmer
 
Join Date: Aug 2005
Posts: 68
Rep Power: 4 Lesliect6 is on a distinguished road
Quick 80386 question

Hello,

In a couple of months' time I will be having my Assembly exams, and to be well prepared for them , I downloaded a free Assembly resource e-book from the internet. The exam will be about the Intel 80386 processor. In this e-book I found some instructions which we haven't seen wet in class, and I would like to have confirmation that they can be used with the 80386 processor. The instructions are :
-CMOV
-BSWAP
-XADD
-conversion instructions such as CBW CWDE etc...
-SET
-BSF, BSR
-string operations

Thank you
Lesliect6 is offline   Reply With Quote
Old Apr 18th, 2007, 8:03 PM   #2
lectricpharaoh
Caffeinated Neural Net
 
lectricpharaoh's Avatar
 
Join Date: Jun 2005
Location: Dry west coast of Canada
Posts: 1,033
Rep Power: 5 lectricpharaoh will become famous soon enough
Quote:
Originally Posted by Lesliect6
In this e-book I found some instructions which we haven't seen wet in class, and I would like to have confirmation that they can be used with the 80386 processor. The instructions are :
-CMOV
-BSWAP
-XADD
-conversion instructions such as CBW CWDE etc...
-SET
-BSF, BSR
-string operations
You're in luck! My old TASM manual was hiding in (one of) the piles on my desk.

CMOV - not listed, so it's safe to say this isn't available for the 80486 or earlier. My NASM references aren't on this machine, but if I get around to it, I'll check the old 386 paperweight- err, laptop.
BSWAP - 486+
XADD - 486+
The conversion ones are available on the 386. Note the difference between CWD and CWDE. The former uses DX:AX as a destination, and the latter uses EAX.
SETcc - These all work on the 386 (I'm assuming you mean the conditional byte set instructions).
BSF, BSR - The bit scan instructions are 386+. If you care, the bit test instructions (BT, BTC, BTR, and BTS) also work on the 386.
If by string instructions, you mean things like STOS, SCAS, MOVS, and the like, those have worked since the 8086/8088. However, if using the 32-bit forms of the instructions, they are limited to 386 and up (this should be obvious).

Note that these refer to the Intel specs. There are some third-party CPUs that support a few instructions beyond the required instruction set, for example, I've heard of a few 80486 chips that support CPUID, even though that's supposed to be Pentium+.
__________________
And once again, Probability proves itself willing to sneak into a back alley and service Drama as would a copper-piece harlot.
- Vaarsuvius, Order of the Stick
lectricpharaoh is offline   Reply With Quote
Old Apr 21st, 2007, 5:19 AM   #3
Lesliect6
Programmer
 
Join Date: Aug 2005
Posts: 68
Rep Power: 4 Lesliect6 is on a distinguished road
Thank you very much!
Lesliect6 is offline   Reply With Quote
Reply

Bookmarks

« Previous Thread in Forum | Next Thread in Forum »

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Quick question.. really Quick Eric the Red Java 14 Jun 2nd, 2006 4:45 PM
Quick n00by question... jobobshishkabob C++ 13 Jan 25th, 2006 5:24 PM
Quick question about c++ massive-war C++ 12 Nov 19th, 2005 2:26 AM
Windows API programming quick question vynkz C++ 4 Apr 24th, 2005 12:33 PM
Quick Introduction and Question snuff Community Introductions 8 Mar 31st, 2005 7:26 AM




DaniWeb IT Discussion Community
All times are GMT -5. The time now is 8:26 PM.

Powered by vBulletin® Version 3.7.0, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Copyright ©2007 DaniWeb® LLC