SBCL: the ultimate assembly code breadboard
EDIT: Lutz Euler points out that the NEXT sequence (used to) encode
an effective address with an index register but no base. The mistake
doesn’t affect the meaning of the instruction, but forces a wasteful
encoding. The difference in machine code are as follows.
Before (14 bytes):
1
2
3
4
; 03: 8B043D00000000 MOV EAX, [RDI] ; _5_ useless bytes!
; 0A: 4883C704 ADD RDI, 4
; 0E: 4801F0 ADD RAX, RSI
; 11: FFE0 JMP RAX
No...
Read more at pvk.ca