Ret
July 23rd, 2012, 10:38
greetings..!
question is related to assembly lang...request, if this's a trespass, it may be overlooked for once!
comment
the above asm code links to form .obj and .exe file, gives output: 76543210.
1-slightly modifying the above code to:
why this code (without calling dwtoa), doesn't give the same output, although the same value is saved at the address of var1.?
2-next, i would like to declare and save the data, in the code section like:
linker doesnot agree to it - how to convince linker to accept it.
thank you..!
question is related to assembly lang...request, if this's a trespass, it may be overlooked for once!
Code:
include c:\masm32\include\masm32rt.inc
.data
var1 dword ?
.code
start:
mov eax, 76543210
mov var1, eax
push offset var1
push eax
call dwtoa
invoke StdOut, offset var1
invoke ExitProcess, 0
end start
comment
the above asm code links to form .obj and .exe file, gives output: 76543210.
1-slightly modifying the above code to:
Code:
.start:
mov eax, 76543210
mov var1, eax
invoke StdOut, offset var1
why this code (without calling dwtoa), doesn't give the same output, although the same value is saved at the address of var1.?
2-next, i would like to declare and save the data, in the code section like:
Code:
invoke StdOut, offset var1
invoke ExitProcess, 0
var1 dword ?
end start
linker doesnot agree to it - how to convince linker to accept it.
thank you..!