I'm tired of it. I tried to grab the assembly a bit for a while, but it seems to me that I am coding my compiler, not the language.
I used this tutorial , and so far it has been giving me hell. I use NASM and this may be a problem, but I thought it was the most popular. I'm just trying to learn the most general form of assembly, so I decided to study x86. I continue to encounter such stupid mistakes as the inability to increment a variable. Here's the last one: the inability to use the div.
mov bx, 0;
mov cx, 0;
jmp start;
start:
inc cx;
mov ax, cx;
div 3; <-- invalid combination of opcode and operand
cmp ah,0;
jz totalvalue;
mov ax, cx;
div 5; <-- invalid combination of opcode and operand
cmp ah, 0;
jz totalvalue;
cmp cx, 1000;
jz end;
totalvalue:
add bx,cx;
jmp start;
jmp end;
end:
mov ah,4ch;
mov al,00;
int 21h;
Should I change compilers? Seems like separation should be standard. I need to read two tutorials (one on NASM and one on x86?). Any specific help on this issue?