flat assembler
Message board for the users of flat assembler.
![]() |
Author |
|
16bitPM 08 Jul 2011, 12:57
Hello all,
I'm totally new on this forum so please forgive me if I'm asking stupid questions ![]() I'm fairly new with FASM but I'm quite experienced with x86 assembly. To learn the syntax of FASM a bit, I decided to convert the code from LATTICE.ASM (256 byte demo). The problem is as follows: the code uses inline offset arithmetic using the $⁻operator. However, FASM appears to calculate the offsets differently. I used debugx to disassemble the code and I got the following result, in this example for the following code: Code: ROTATE fild word [si-EYE+ZMOVE] fidiv word [si-EYE+SCALE] ORIGINAL object code: Code: 0863:015F DF 44 C6 FILD WORD PTR [SI-3A] 0863:0162 DE 41 C1 FIDIV WORD PTR [SI-3F] FASM object code: Code: 0863:015F DF 44 FC FILD WORD PTR [SI-04] 0863:0162 DE 41 A8 FIDIV WORD PTR [SI-58] I was wondering if this behaviour is known and what to do about it. Thanks for you reply! PS: I included the full source code of both versions.
|
|||||||||||||||||||||
![]() |
|
16bitPM 08 Jul 2011, 21:14
revolution wrote: The problem is the operation of equ. In fasm equ is a textural replacement not a numeric computation. Use equals (=) instead. Thank you! That totally worked! ![]() |
|||
![]() |
|
< Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2025, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.