flat assembler
Message board for the users of flat assembler.
![]() |
Author |
|
vid 02 Nov 2005, 13:00
maybe alocate bigger chunk of memory, copy wntire stack there and set (somehow) SS:ESP to point there?
|
|||
![]() |
|
farrier 02 Nov 2005, 14:23
Posetf,
You don't say what environment you are programming to: Windows, DOS, Linux, ... If Windows, is the problem when you are using a lot of local variables? If so, you can protect against gaurd page exceptions by using the following: Code: mov eax, ebp sub eax, 4096 .while eax, a, esp mov dword [eax], 0 sub eax, 4096 .endw immediately after the declaration of your locals and before any code which might use the stack variables. This will touch, if necessary, every page of the stack that your locals will use. As each 4096 byte page is touched, it sets up the following 4096 byte page as the next guard page, and will prevent exceptions for this reason. hth, farrier _________________ Some Assembly Required It's a good day to code! U.S.Constitution; Bill of Rights; Amendment 1: ... the right of the people peaceably to assemble, ... The code is dark, and full of errors! |
|||
![]() |
|
< Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2023, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.