nasm - Can one deallocate stack memory on x86_64 by substracting from rbp? -


the title pretty says it. writing algorithm (and right porting nasm) need allocate lots (upwards of 8gb) of ram (as severe tradeoff cpu usage). on every iteration stores int onto stack (for output , later usage). then, periodically free set of values bottom of stack. done decrementing stack base (rbp)?

a stack stack. can push , pop values on top nothing more. cannot deallocate in other way.

changing rbp doesn't anything, helper register use current stack frame. rsp shows current top of stack , moving changes next value stored or retrieved within stack. can drop bunch of values top if needed, not bottom.

if have need temporarily store values , later release them circular buffer or blocks of regular memory better suited that.


Comments