MMX instruction assembly 
Author Message
 MMX instruction assembly

Hello,

It's me again asking how to assembly MMX instructions... ;-)

I have the following instructions, and I have assembled them like this:

  movq mm1,[edx]    ->    db 0F,6F,0A
  movq mm0,[eax]    ->    db 0F,6F,00
  pxor mm0,mm1      ->    db 0F,EF,C1
  movq [eax],mm0    ->    db 0F,7F,00

I'm pretty sure that the first three instructions are correct, but I'm
not sure about the last one. I'm running this code from a 32-bit Windows
program, so I guess 32-bit addressing is already enabled.

Any comments would be much appreciated. Please e-mail your reply as well
-- I'm not a regular reader to this NG.

Regards,

Jani J=E4rvinen



Fri, 27 Aug 1999 03:00:00 GMT  
 MMX instruction assembly

[snip]

Quote:
> I have the following instructions, and I have assembled them like this:

[snip]

Why in Gods name are you assembling by hand?

Get yourself an assembler or a C compiler, that can assemble MMX
instructions! And if you still want to write the instruction byte
by byte for some {*filter*}ed (?) reason, you can then check the
disassembly or listing of the assembler/compiler output to make
sure...

Here is the URL of NASM

http://www.*-*-*.com/ ~jules/nasm1.html

There you can find NASM 0.93, which should, AFAIK, assemble MMX
instructions.

==> Vesa Karvonen

An optimizing programmer can always beat a C programmer.



Sat, 28 Aug 1999 03:00:00 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. MMX instruction assembly - Help!

2. TASM 3 / MMX instructions CMPXCHG ORG

3. mmx instructions

4. Saturated Addition with MMX instructions

5. Cache Miss Reduction & MMX Instructions

6. MMX instructions.

7. MMX instructions in native 386 code

8. MMX - EMMS instruction.

9. mmx instruction reference

10. mmx instructions

11. MMX and extended instruction sets in TASM 5.0

12. Using mmx instructions.

 

 
Powered by phpBB® Forum Software