_start:
jmp welcome
This means that all code under JMP is not executed, especially mov ecx, 0 (which should be xor ecx, ecx for a shorter instruction)
, . JMP - , , , .
, Welcome:, Loop:, , ecx = 0.
cmp ecx, 10
jl loop
ECX 0, 10h, .
:
_start:
mov eax, 4
mov ebx, 1
mov ecx, hello
mov edx, sLength
int 80 ;prints out the string in "hello"
xor ecx,ecx ;ecx = 0
loop:
push ecx ;save loop index
mov eax, 4
mov ebx, 1
mov ecx, notDone
mov edx, nDLength
int 80 ;prints out that the loop isn't finished
pop ecx ;get loop index back in ECX
add ecx, 1 ;add one to ecx value
cmp ecx, 10
jl loop ;if the value is not ten or more, repeat
theend: