From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:51024) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bK1Qn-0004iM-JO for qemu-devel@nongnu.org; Mon, 04 Jul 2016 06:48:50 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bK1Qj-0001AQ-Dj for qemu-devel@nongnu.org; Mon, 04 Jul 2016 06:48:48 -0400 Received: from mx1.redhat.com ([209.132.183.28]:34503) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bK1Qj-0001AF-7f for qemu-devel@nongnu.org; Mon, 04 Jul 2016 06:48:45 -0400 References: <1467272240-32123-1-git-send-email-pl@kamp.de> <1467272240-32123-2-git-send-email-pl@kamp.de> <851cfb04-5e9d-6f9a-5932-09e697aa500e@twiddle.net> <6bc08536-27f5-e4b1-fc8b-4bb04a8655dc@twiddle.net> <5779FF99.20605@kamp.de> <8b78fc50-8bbd-4383-6dda-6d56fd28e449@redhat.com> <577A39B7.2010007@kamp.de> <577A3BFD.5000109@kamp.de> From: Paolo Bonzini Message-ID: <5c329185-c10f-be6c-0dba-d3b72f610457@redhat.com> Date: Mon, 4 Jul 2016 12:48:40 +0200 MIME-Version: 1.0 In-Reply-To: <577A3BFD.5000109@kamp.de> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH 1/6] oslib-posix: add helpers for stack alloc and free List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Peter Lieven , Richard Henderson , qemu-devel@nongnu.org Cc: kwolf@redhat.com, peter.maydell@linaro.org, mst@redhat.com, dgilbert@redhat.com, mreitz@redhat.com On 04/07/2016 12:35, Peter Lieven wrote: > Am 04.07.2016 um 12:34 schrieb Paolo Bonzini: >> >> On 04/07/2016 12:25, Peter Lieven wrote: >>>> No, you just pass the stack and the runtime takes care of initializing >>>> the two stack pointers: >>>> >>>> uc.uc_link = &old_uc; >>>> uc.uc_stack.ss_sp = co->stack; >>>> uc.uc_stack.ss_size = stack_size; >>>> uc.uc_stack.ss_flags = 0; >>> So, you would basically copy the if/elif part from allocatestack.c ? >> Yes, but note that _STACK_GROWS_{DOWN,UP} and >> NEED_SEPARATE_REGISTER_STACK are glibc-specific. You need to use >> HOST_IA64 and HOST_HPPA. > > Is HOST_HPPA the only supported target where the stack grows up? Yes, I think so. Paolo