fixed stack problems in invoke_static, memory_write8, memory_write16