def stack_push ( self , thing ) : # increment sp sp = self . regs . sp + self . arch . stack_change self . regs . sp = sp return self . memory . store ( sp , thing , endness = self . arch . memory_endness )
stack python memory map
Push thing to the stack writing the thing to memory and adjusting the stack pointer .
def stack_push(self, thing):
        """
        Push 'thing' to the stack, writing the thing to memory and adjusting the stack pointer.
        """
        # increment sp
        sp = self.regs.sp + self.arch.stack_change
        self.regs.sp = sp
        return self.memory.store(sp, thing, endness=self.arch.memory_endness)