From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 13635 invoked by alias); 14 May 2012 15:01:08 -0000 Received: (qmail 13595 invoked by uid 22791); 14 May 2012 15:01:03 -0000 X-SWARE-Spam-Status: No, hits=-3.5 required=5.0 tests=AWL,BAYES_00,KHOP_RCVD_UNTRUST,RCVD_IN_HOSTKARMA_NO,RCVD_IN_HOSTKARMA_W,RCVD_IN_HOSTKARMA_WL X-Spam-Check-By: sourceware.org Received: from rock.gnat.com (HELO rock.gnat.com) (205.232.38.15) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Mon, 14 May 2012 15:00:43 +0000 Received: from localhost (localhost.localdomain [127.0.0.1]) by filtered-rock.gnat.com (Postfix) with ESMTP id B6D461C6DCD; Mon, 14 May 2012 11:00:42 -0400 (EDT) Received: from rock.gnat.com ([127.0.0.1]) by localhost (rock.gnat.com [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 2b3yR57B+22W; Mon, 14 May 2012 11:00:42 -0400 (EDT) Received: from joel.gnat.com (localhost.localdomain [127.0.0.1]) by rock.gnat.com (Postfix) with ESMTP id 49B9A1C6D96; Mon, 14 May 2012 11:00:42 -0400 (EDT) Received: by joel.gnat.com (Postfix, from userid 1000) id 5D457145616; Mon, 14 May 2012 08:00:34 -0700 (PDT) Date: Mon, 14 May 2012 15:01:00 -0000 From: Joel Brobecker To: "Maciej W. Rozycki" Cc: Mark Kettenis , gdb-patches@sourceware.org Subject: Re: [RFA 1/2] mips: Switch inferior function calls to ON_STACK method. Message-ID: <20120514150034.GG10253@adacore.com> References: <201205051144.q45Bitv4006357@glazunov.sibelius.xs4all.nl> <20120508160542.GB15555@adacore.com> <20120508204257.GC15555@adacore.com> <20120508220805.GD15555@adacore.com> <201205090823.q498Njc7019605@glazunov.sibelius.xs4all.nl> <20120509143537.GH15555@adacore.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.20 (2009-06-14) Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2012-05/txt/msg00512.txt.bz2 > I gave it yet more thinking and came to the conclusion that at least > for the MIPS target, where it is safe to use either way, but both > have some drawbacks, we should really apply both, switching > dynamically. The reason is the stack may be unwritable for whatever > reason (e.g. not correctly set up), so we should try ON_STACK first > and if that fails (e.g. SP is NULL or writing to the stack has > faulted), then fall back to AT_ENTRY_POINT. This is another corner > case however and I don't feel compelled to implement it right now. > Let's leave it for another sunny day in Cambridgeshire. ;) Is that something we could detect at gdbarch init? (I don't think we have a process at init time) > 2012-05-14 Maciej W. Rozycki > > gdb/ > * mips-tdep.c (mips_push_dummy_code): Handle microMIPS code. FWIW, the change looks good to me. -- Joel