flat assembler
Message board for the users of flat assembler.
Index
> Windows > What Gets Clobered? |
Author |
|
calm_observer 22 Feb 2005, 19:25
surely someone has an answer for ebx, edi and esi?...johnfound?
|
|||
22 Feb 2005, 19:25 |
|
r22 23 Feb 2005, 04:49
ebx, edi and esi are protected by 99% of windows functions (IE pushed before and pop'd after if used)
mov esi, 99h mov ebx, 99h mov edi, 99h call [WINDOWS API] ;ESI = EDI = EBX |
|||
23 Feb 2005, 04:49 |
|
calm_observer 23 Feb 2005, 17:20
thanks r22...do you have any links on this subject? Or actually any links you think may be of use? Thanks again.
|
|||
23 Feb 2005, 17:20 |
|
drocon 24 Feb 2005, 06:59
i can't think up of an API that doesn't preserve the three for normal use, it's stdcall standard (and common sense). if you're just coding low, ebp can also be used as a general-purpose register (and quite handy too). esi/edi should be saved for string operations, so ebx/ebp could be used. it's all preference.
|
|||
24 Feb 2005, 06:59 |
|
f0dder 24 Feb 2005, 16:26
And remember that you need to preserve ebx,esi,edi,ebp yourself in callbacks, as well as the direction flag.
|
|||
24 Feb 2005, 16:26 |
|
calm_observer 24 Feb 2005, 17:55
thanks drocon and f0dder...
|
|||
24 Feb 2005, 17:55 |
|
< Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2025, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.