Hello,
I'm busy re-engineering the BIOS-es of old IBM-XT and I'm trying to generate BIN files that are the same as the original as exactly as possible. So far I ran into the problem that NASM doesn't assemble an instruction into the same bytes as the original assembler used to create the original BINs. For example: "8B D9" is translated by NASM's disassembler into "mov bx,cx". But the assembler translates this instruction into "89 CB". I can live with that because I tested several of the NASM generated BIOS-es and they worked fine. But if somebody knows a way to tell NASM to use the other code, it would make me happy.
Today I ran into a real problem. "81 E2 0E 00" is disassembled into "and dx,0xe" and that is assembled into "83 E2 0E". I now miss one byte. I tried with adding "word", using 000Eh, 0x000E and combinations of it but with no result. OK, I could fill it up with a NOP but I will only do that when there is no other solution.
Who can tell me what to do to get at least my original length of four bytes?
Many thanks in advance!
Kind regards, Ruud Baltissen