flat assembler
Message board for the users of flat assembler.
Index
> Main > why does this line crashes? |
Author |
|
Teehee 08 Oct 2011, 17:05
Code: cmp byte[esi-1],0 _________________ Sorry if bad english. |
|||
08 Oct 2011, 17:05 |
|
ouadji 08 Oct 2011, 18:35
esi ? a page fault ? |
|||
08 Oct 2011, 18:35 |
|
typedef 08 Oct 2011, 19:29
check direction flag maybe
|
|||
08 Oct 2011, 19:29 |
|
Teehee 08 Oct 2011, 19:33
> esi ? a page fault ?
could be!? > check direction flag maybe both crash: Code: cld mov byte[esi-1],0 std mov byte[esi-1],0 |
|||
08 Oct 2011, 19:33 |
|
ouadji 08 Oct 2011, 20:48
Code: ;@Teehee cld mov byte[esi-1],0 std mov byte[esi-1],0 but in this case it is not the direction flag that is causing the problem, but it is also a page fault. Only a page fault can trigger a crash with this code. (or a power outage ) A breakpoint just before, a good debugger ... (3 min) 100% agree with Goplat edit: cld and std does not affect cmp or mov |
|||
08 Oct 2011, 20:48 |
|
typedef 09 Oct 2011, 02:29
ouadji wrote:
Which power outage are we talking about here lol |
|||
09 Oct 2011, 02:29 |
|
Teehee 09 Oct 2011, 12:28
Goplat wrote: If the "cmp byte[esi-1],0" instruction crashes it can only be because ESI-1 is not a valid address. Without seeing more of your code there's no way for anyone to know why that would be. I just made a new file with just that instruction. Quote: cld and std does not affect cmp or mov LOL i forgot that haha _________________ Sorry if bad english. |
|||
09 Oct 2011, 12:28 |
|
< Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2024, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.