flat assembler
Message board for the users of flat assembler.
![]() |
Author |
|
vid 24 Oct 2007, 15:29
yep... and multi-pass assembling (which allows "used") is powerfull too.
You might read mine article about external dependencies |
|||
![]() |
|
bitRAKE 24 Oct 2007, 16:25
It seems like you were just making note of a deficiency in NASM that caused difficulty in your unified approach.
I like the way FASM allow the interface names to be independant of the source code: Code: public YouAreHere as '_Impressive' YouAreHere: Code: extrn '_Impressive' as NotThereYet:dword call NotThereYet |
|||
![]() |
|
vid 24 Oct 2007, 16:57
Quote: It seems like you were just making note of a deficiency in NASM that caused difficulty in your unified approach. kinda... also deficiency of GAS, and also i demonstrated how are things done in FASM and MASM. by the way, why do you place that ":DWORD" everywhere? |
|||
![]() |
|
bitRAKE 24 Oct 2007, 17:24
vid wrote: by the way, why do you place that ":DWORD" everywhere? Code: ; overload extrn to reduce size of obj macro extrn s { match str =as nm:d,s \{ if used nm extrn str as nm:d end if \} } |
|||
![]() |
|
vid 24 Oct 2007, 18:07
Quote: By that statement I assume it is the default. I have never liked data size defaults - more so on an interface. I doubt Tomasz would change the default and most all will be DWORDS; but I do have some :BYTEs. Should maybe change the macro: no, it isn't default. Default is label without any assigned size. Difference is demonstrated here: Code: label1 dd 10 ;dword size assigned label2: ;no size assigned dd 10 cmp [label1], 10 ;we know label1 is dword, so this compares dword mov [label1], eax ;OK, moves to dword at label1 mov [label1], ax ;error, ax is word and label1 is dword, use following mov word [label1], ax ;OK cmp [label2], 10 ;label2 has no size assigned, this throws error mov [label2], eax ;OK, both eax and label2 are dwords mov [label2], ax ;OK, moves to word at label2 now i hope you see what is difference between label without any size assigned, and label that has assigned size Last edited by vid on 24 Oct 2007, 18:53; edited 1 time in total |
|||
![]() |
|
LocoDelAssembly 24 Oct 2007, 18:14
vid, check your example in fasm to see if all comments are true
![]() |
|||
![]() |
|
bitRAKE 24 Oct 2007, 18:31
vid wrote: Default is label without any assigned size. I'll keep assigning a size on the interface when known. This does bring up and interesting question though: Is the windows API call DWORD or QWORD in Win64? From the PE64DEMO with FASM it does appear that they are QWORDs! I'll need to factor this into my include files it seems. Thanks for bringing this to light. |
|||
![]() |
|
LocoDelAssembly 24 Oct 2007, 18:39
Code: mov ecx,eax call [ExitProcess] Code: kernel_table: ExitProcess dq RVA _ExitProcess dq 0 The type is specified in the label and hence fasm assembles "call qword [ExitProcess]" |
|||
![]() |
|
vid 24 Oct 2007, 18:53
LocoDelAssembly wrote: vid, check your example in fasm to see if all comments are true hell ![]() fixed... |
|||
![]() |
|
< Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2025, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.