Counter in FASM assembly
Load [incr] into a register instead, for example eax, and increment the register.

Instead of cmp [incr], 1000000000 and jne, try loading 1000000 into the ecx register and using the loop opcode.

The advice above to use loop is probably obsolete. Instead it may be faster to do load 1000000 into a register like ebx, and do a dec ebx and jnz loop.

Intel's Branch and Loop Reorganization to Prevent Mispredicts seems to recommend you code a loop like this ...

loop_top:
... do work inside the loop here ...
cmp ebx,1000000
jz loop_end ; happens rarely
inc ebx
jmp loop_top ; happens often
loop_end:


... in order to optimize the branch prediction.

Unrolling the loop might make it faster. In fact given how dumb the algorithm is, the best optimization is to immediately 1000000 to [incr] without looping.