4 ms·
I was quite adept at 6800 and 68000 assembler but I can't imagine getting to that level with modern x86. Maybe some glue routines, but beyond that give me any o
by TomMasz 10y ago
I was quite adept at 6800 and 68000 assembler but I can't imagine getting to that level with modern x86. Maybe some glue routines, but beyond that give me any of the current compilers.
- ndesaulniers 10y agohttps://nickdesaulniers.github.io/blog/2014/04/18/lets-write-some-x86-64/ https://nickdesaulniers.github.io/blog/2014/04/18/lets-write...
- csense 10y agoIt looked promising right up until the first code, and then I saw you're writing in AT&T syntax. AT&T syntax is such an abomination against nature and the gods of computing that every time I see it I want to gouge my eyes out. AT&T syntax is this weird awful syntax only used by GNU as. The syntax is some leftover from an assembler from the early UNIX days which was clearly written by a very lazy person. Whoever came up with it apparently thought to themselves, "If we make source files put a % character in front of registers and a $ character in front of constants, then I don't have to think too hard about how to write a parser. If we make source files specify their width in a suffix, then we don't have to think too hard about how to get this information out of the register name. And let's put our operands in (source, destination) order instead of (destination, source) order just to be evil and confuse people!" Aaagggghh. If gas wasn't used as the backend of gcc, I guarantee exactly zero people would use it, because AT&T syntax is so awful. You should consider posting an update using NASM / YASM (or if you feel you must use GAS, use its directive for Intel syntax). Your readers will thank you.
- ndesaulniers 10y agoYou should do it on your blog.