From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 23104 invoked by alias); 10 Mar 2004 17:45:05 -0000 Mailing-List: contact libc-hacker-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libc-hacker-owner@sources.redhat.com Received: (qmail 23086 invoked from network); 10 Mar 2004 17:45:04 -0000 Received: from unknown (HELO palrel13.hp.com) (156.153.255.238) by sources.redhat.com with SMTP; 10 Mar 2004 17:45:04 -0000 Received: from hplms2.hpl.hp.com (hplms2.hpl.hp.com [15.0.152.33]) by palrel13.hp.com (Postfix) with ESMTP id F29A51C0138B; Wed, 10 Mar 2004 09:45:03 -0800 (PST) Received: from napali.hpl.hp.com (napali.hpl.hp.com [15.4.89.123]) by hplms2.hpl.hp.com (8.12.10/8.12.10/HPL-PA Hub) with ESMTP id i2AHj17u029718; Wed, 10 Mar 2004 09:45:01 -0800 (PST) Received: from napali.hpl.hp.com (napali [127.0.0.1]) by napali.hpl.hp.com (8.12.11/8.12.11/Debian-1) with ESMTP id i2AHj1KA001563; Wed, 10 Mar 2004 09:45:01 -0800 Received: (from davidm@localhost) by napali.hpl.hp.com (8.12.11/8.12.11/Debian-1) id i2AHj0UK001559; Wed, 10 Mar 2004 09:45:00 -0800 From: David Mosberger MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-ID: <16463.21532.841079.452596@napali.hpl.hp.com> Date: Wed, 10 Mar 2004 17:45:00 -0000 To: Jakub Jelinek Cc: davidm@hpl.hp.com, Andreas Schwab , Ulrich Drepper , Glibc hackers Subject: Re: [PATCH] getpid/vfork/raise fix In-Reply-To: <20040310145052.GX3822@sunsite.ms.mff.cuni.cz> References: <404BDA36.6000202@redhat.com> <200403080237.i282bXG6004322@magilla.sf.frob.com> <20040308110105.GN3822@sunsite.ms.mff.cuni.cz> <404D76CA.4010500@redhat.com> <20040309115038.GO3822@sunsite.ms.mff.cuni.cz> <20040310101515.GS3822@sunsite.ms.mff.cuni.cz> <16463.17524.280448.143159@napali.hpl.hp.com> <20040310145052.GX3822@sunsite.ms.mff.cuni.cz> Reply-To: davidm@hpl.hp.com X-URL: http://www.hpl.hp.com/personal/David_Mosberger/ X-SW-Source: 2004-03/txt/msg00052.txt.bz2 >>>>> On Wed, 10 Mar 2004 15:50:52 +0100, Jakub Jelinek said: >> Most scratch registers are _not_ preserved across system calls. >> You could spill the register onto the memory stack though. If it >> uses at most 16 bytes, you won't have to adjust the stack pointer >> even. Jakub> But as soon as you spill something into memory the vfork Jakub> child can clobber it and you restore in the parent something Jakub> different from what you saved. How many registers need to be preserved? Just one? (Sorry, I could read the code but I'm a bit preoccupied with other stuff at the moment.) If it's just one, I think you could use r11 because that one is required to be preserved for the light-weight syscall convention. --david