flat assembler
Message board for the users of flat assembler.
Index
> IDE Development > Fresh 2.0.3 - Semi portable :D |
Author |
|
ouadji 21 Sep 2011, 19:30
JohnFound, Does that interest you ? (or not) multilines comment and/or display the number of bytes out of range |
|||
21 Sep 2011, 19:30 |
|
ouadji 21 Sep 2011, 21:35
bug report |
|||
21 Sep 2011, 21:35 |
|
JohnFound 01 Dec 2011, 11:35
Hi ouadji.
About the multiline comments and the error message - how it is implemented? I am not willing to make changes in the FASM compiler. Because of compatibility reasons you know. About the bug reported - I simply can't reproduce it. Maybe I have to change to another skin or something. Regards |
|||
01 Dec 2011, 11:35 |
|
ouadji 01 Dec 2011, 13:21
The modified compiler is 100% compatible with the original compiler. I'm agree with you and It's also my first priority. Here is my additional code to display the number of bytes out of range.(+) Code: ;========================================================== ;data + ;------ db 11 mess_999 db ' >999 bytes' db 06 mess_bytes db ' bytes' db 07 mess_1byte db ' 1 byte' block dd ? factor_div db 0,1,10,100 ;X86_64.INC ;---------- jump_out_of_range: ;-------------------------------------->+ bts [block],4 jc @F mov [out_of_range],eax ;--------------------------------------<+ @@: cmp [error_line],0 ;========================================================== ;PREPROCE.INC ;------------ preprocessor: mov [block],0 ;+ init mov [out_of_range],0 ;+ mov edi,characters ;========================================================== ;ERRORS.INC ;---------- relative_jump_out_of_range: call Compute_and_Display ;+ push _relative_jump_out_of_range jmp assembler_error ;========================================================== ;MESSAGES.INC ;------------ _relative_jump_out_of_range db \ ' relative jump out of range ' ;+ <- nothing after "'" out_of_range dd 3 dup 0 ;+ ;original:(-) ;_relative_jump_out_of_range db 'relative jump out of range',0 ;========================================================== Compute_and_Display: ;+ btr [block],4 jnc .exit_a ;in theory, never. mov edi,out_of_range mov eax,[edi] cdq xor eax,edx sub eax,127 jc .exit_b mov esi,mess_1byte cmp eax,1 je .direct_ mov esi,mess_999 cmp eax,1000 jnc .direct_ mov ecx,3 @@: div [factor_div + ecx] add al,30h stosb shr ax,8 loop @B mov esi,mess_bytes .direct_: movzx ecx,byte[esi-1] rep movsb .exit_b: mov byte[edi],0 .exit_a: retd ;========================================================== |
|||
01 Dec 2011, 13:21 |
|
JohnFound 01 Dec 2011, 13:57
Hm, the changes of so many files from the FASM distribution is definitely not "compatible". In every new version of FASM you have to make these changes again and again. This is what I want to avoid.
|
|||
01 Dec 2011, 13:57 |
|
ouadji 01 Dec 2011, 14:17
ok, but i think this is an interesting feature. For those interested in the optimization, if only a few bytes are out of range, this feature helps to see if it is possible or not to remove this error. What do the fasm users think about that? useful, useless? |
|||
01 Dec 2011, 14:17 |
|
< Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2024, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.