From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 14755 invoked by alias); 3 Sep 2009 16:01:48 -0000 Received: (qmail 14229 invoked by uid 22791); 3 Sep 2009 16:01:45 -0000 X-SWARE-Spam-Status: No, hits=-2.5 required=5.0 tests=AWL,BAYES_00,SPF_PASS X-Spam-Check-By: sourceware.org Received: from cam-admin0.cambridge.arm.com (HELO cam-admin0.cambridge.arm.com) (193.131.176.58) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Thu, 03 Sep 2009 16:01:40 +0000 Received: from cam-owa2.Emea.Arm.com (cam-owa2.emea.arm.com [10.1.105.18]) by cam-admin0.cambridge.arm.com (8.12.6/8.12.6) with ESMTP id n83G1aeI020962; Thu, 3 Sep 2009 17:01:36 +0100 (BST) Received: from [10.1.129.129] ([10.1.255.212]) by cam-owa2.Emea.Arm.com with Microsoft SMTPSVC(6.0.3790.3959); Thu, 3 Sep 2009 17:01:36 +0100 Subject: Re: [ARI regression] in arm-tdep.c From: Richard Earnshaw To: Pierre Muller Cc: jules@sourceware.org, gdb-patches@sourceware.org In-Reply-To: <001001ca2c6e$294c4750$7be4d5f0$@u-strasbg.fr> References: <20090730230505.22710.qmail@sourceware.org> <001001ca2c6e$294c4750$7be4d5f0$@u-strasbg.fr> Content-Type: text/plain Date: Thu, 03 Sep 2009 16:01:00 -0000 Message-Id: <1251993692.12941.0.camel@e200601-lin.cambridge.arm.com> Mime-Version: 1.0 Content-Transfer-Encoding: 7bit X-IsSubscribed: yes 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: 2009-09/txt/msg00083.txt.bz2 On Thu, 2009-09-03 at 10:11 +0200, Pierre Muller wrote: > Hi Jules, > > your patch from august 31 > add a new regression about use of abort() function > See > http://sourceware.org/gdb/current/ari/ > > As stated: > Do not use abort, instead use internal_error; GDB should never abort > > Below is a proposition of patch, > but as I have no precise idea of what > displaced_write_reg function does, > it might be better if you commit a > patch with a more adequate description of > the problem, maybe something like > "wrong write_pc argument value in displaced_write_reg fuinction"? > > Could you please take care of this? > > Pierre Muller > GDB ARI maintainer. > > > Index: arm-tdep.c > =================================================================== > RCS file: /cvs/src/src/gdb/arm-tdep.c,v > retrieving revision 1.286 > diff -u -p -r1.286 arm-tdep.c > --- arm-tdep.c 14 Aug 2009 00:32:31 -0000 1.286 > +++ arm-tdep.c 3 Sep 2009 08:01:10 -0000 > @@ -2769,7 +2769,8 @@ displaced_write_reg (struct regcache *re > break; > > default: > - abort (); > + internal_error (__FILE__, __LINE__, > + _("Error inside displaced_write_reg function")); > } > > dsc->wrote_to_pc = 1; OK, though I think "Invalid argument to displaced_write_reg" might be a better error. R.