flat assembler
Message board for the users of flat assembler.

Index > DOS > How to write code for the 8087 Co processor?

Author
Thread Post new topic Reply to topic
farmingdale



Joined: 08 Feb 2006
Posts: 1
farmingdale
Question Can I use Fasm to write a program that uses the 8087 c0-processor? If so how? Can you show me an example?
Post 08 Feb 2006, 20:42
View user's profile Send private message Reply with quote
Madis731



Joined: 25 Sep 2003
Posts: 2140
Location: Estonia
Madis731
I don't know if it makes any difference whether its a co-CPU or integrated into it. The FPU instruction-set should be the same. Somebody correct me if I stand wrong here...
http://courses.ece.uiuc.edu/ece390/books/labmanual/inst-ref-general.html#INST-REF-F2XM1
...and look down from there
Post 08 Feb 2006, 21:50
View user's profile Send private message Visit poster's website Yahoo Messenger MSN Messenger Reply with quote
vid
Verbosity in development


Joined: 05 Sep 2003
Posts: 7105
Location: Slovakia
vid
wow, there is something like 8087???
Post 08 Feb 2006, 21:55
View user's profile Send private message Visit poster's website AIM Address MSN Messenger ICQ Number Reply with quote
Tomasz Grysztar



Joined: 16 Jun 2003
Posts: 7750
Location: Kraków, Poland
Tomasz Grysztar
8087 was the first model of FPU for PC computers, in times when the FPU was in form of co-processor (additional processing unit you could plug into the motherboard). And yes, the instruction set is the same no matter whether FPU is a co-processor or is integrated into CPU.

In fact the encodings of FPU instructions are affected by the fact that they initially were instructions for the separate unit, as they are were in fact single ESC instruction of 8086, which escaped the command out to the co-processor, and the interpretation of escaped code was done by that separate unit - thus you possibly might have different co-processors with different instruction sets, but I have never heard of any instruction set for 8086 co-processors other that 8087 one.
Post 08 Feb 2006, 22:02
View user's profile Send private message Visit poster's website Reply with quote
vid
Verbosity in development


Joined: 05 Sep 2003
Posts: 7105
Location: Slovakia
vid
hmmmm, isn't ESC opcode 0F, which was pop cs on 086?
Post 08 Feb 2006, 23:03
View user's profile Send private message Visit poster's website AIM Address MSN Messenger ICQ Number Reply with quote
Tomasz Grysztar



Joined: 16 Jun 2003
Posts: 7750
Location: Kraków, Poland
Tomasz Grysztar
No, 0F is just the part of two-byte encodings, it has no memonic itself.
The ESC instruction used opcodes D8-DF.
Quick description of ESC: http://library.n0i.net/hardware/i8086opcodes/#ESC
Post 08 Feb 2006, 23:11
View user's profile Send private message Visit poster's website Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  


< Last Thread | Next Thread >
Forum Rules:
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Copyright © 1999-2020, Tomasz Grysztar. Also on YouTube, Twitter.

Website powered by rwasa.