> Mostly it looks okay. I worry a bit about the qword/dword rel syntax.
Having to type "dword rel" and "qword rel" is cumbersome.
You really ought to consider "eip" and "rip" instead.
> It could get confusing, since nasm already uses those keywords inside
> of brackets to control offset value sizes:
> [byte ebx-1] ... store offset in one byte
> [dword ebx-1] ... store offset in four bytes
> [dword rel -1] ... use EIP-relative addressing
> [dword dword rel -1] ... ???
> I'm not sure if the last one is even possible (I haven't had time to
> learn x64 yet).
The assembler should warn if there are multiple conflicting qualifiers.
And it should pick one of them in a documented manner.
In my case I made it pick the first one; later ones warn and get ignored.
> And of course, dword is already overloaded when it appears outside of
> the brackets. Would this be legal?
> mov dword [dword dword rel ebx-1], 100
IP-relative addressing can not be combined with registers.
Also, IP-relative addressing and tradditonal EAs are mutually exclusive.
That is, you can have "dword ebx-1" or "eip-1", but not both at the same time.
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
Get latest updates about Open Source Projects, Conferences and News.