flat assembler
Message board for the users of flat assembler.
![]() |
Author |
|
Roman
Code: Zval dd 10,55 Mov eax, [Zval] ;it's ok But how get value to eax, 10? I know abaut EQU. But some times not handful EQU. Code: Mov eax, magic Zval;= Mov eax, 10 |
|||
![]() |
|
sts-q
zval = 1055h
zval_location dd zval mov eax, zval ; eax = 1055h mov ax, [zval_location] ; ax = 1055h ![]() Last edited by sts-q on 10 Feb 2020, 15:35; edited 1 time in total |
|||
![]() |
|
Roman
Not I mean get value from Zval,
But not Mov eax, [Zval] Its read from memory slow I want get to eax 10 from Zval! Unusual method. And for this need unusual macros! |
|||
![]() |
|
Tomasz Grysztar
You probably mean this then:
Code: Zval dd 10,55 load tmp dword from Zval Mov eax, tmp Code: __DATA:: Zval dd 10,55 ; ...in another section: load tmp dword from __DATA:Zval Mov eax, tmp |
|||
![]() |
|
Roman
Thanks this is I want.
|
|||
![]() |
|
Roman
What about load tmp peace of code from?
Code: Lb: Inc ebx Load tmp lb Tmp ; in this place we get Inc ebx |
|||
![]() |
|
Tomasz Grysztar
Roman wrote: What about load tmp peace of code from? Code: Lb: Inc ebx
Load tmp byte from Lb
db tmp Code: Lb: Inc ebx .size = $ - Lb repeat Lb.size Load tmp byte from Lb+%-1 db tmp end repeat |
|||
![]() |
|
Roman
Amazing and cool!
Thanks. |
|||
![]() |
|
< Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2020, Tomasz Grysztar. Also on GitHub, YouTube, Twitter.
Website powered by rwasa.