From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 25201 invoked by alias); 17 Jul 2013 17:59:59 -0000 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 Received: (qmail 25187 invoked by uid 89); 17 Jul 2013 17:59:59 -0000 X-Spam-SWARE-Status: No, score=-5.5 required=5.0 tests=AWL,BAYES_00,RCVD_IN_HOSTKARMA_W,RCVD_IN_HOSTKARMA_WL,RDNS_NONE,SPF_HELO_PASS,SPF_PASS autolearn=no version=3.3.1 Received: from Unknown (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.84/v0.84-167-ge50287c) with ESMTP; Wed, 17 Jul 2013 17:59:58 +0000 Received: from int-mx02.intmail.prod.int.phx2.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id r6HHxpdG006100 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Wed, 17 Jul 2013 13:59:51 -0400 Received: from barimba (ovpn-113-128.phx2.redhat.com [10.3.113.128]) by int-mx02.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id r6HHxo2D031027 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES128-SHA bits=128 verify=NO); Wed, 17 Jul 2013 13:59:51 -0400 From: Tom Tromey To: Sergio Durigan Junior Cc: GDB Patches Subject: Re: [PATCH 17/17] MIPS support References: <1372664545-3947-1-git-send-email-sergiodj@redhat.com> <1372664545-3947-18-git-send-email-sergiodj@redhat.com> Date: Wed, 17 Jul 2013 17:59:00 -0000 In-Reply-To: <1372664545-3947-18-git-send-email-sergiodj@redhat.com> (Sergio Durigan Junior's message of "Mon, 1 Jul 2013 04:42:25 -0300") Message-ID: <8738rdgj8p.fsf@fleche.redhat.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-SW-Source: 2013-07/txt/msg00406.txt.bz2 >>>>> "Sergio" == Sergio Durigan Junior writes: Sergio> MIPS already has a definition of its signals inside mips-linux-tdep.h Sergio> (see enum mips_signals). I could have used them, but I chose to Sergio> follow the standard and implement an enum containing only differences Sergio> between MIPS and x86 signals. In the battle between code duplication Sergio> and code standardization, the latter won (in my head, at least). But I Sergio> am totally open to suggestions, and I even believe I know what I will Sergio> hear: "Please, use mips_signals". Sergio> Anyway, I thought it was worth raising this point here. Thanks. One thing I'm curious about is why the corresponding gdbarch_gdb_signal_from_target method is only implemented for MIPS, and not for all Linux targets. Consideration of this led me to another possible approach to the problem you mention above: you could use your standard approach for the enum, but also reimplement the MIPS gdbarch_gdb_signal_from_target method to follow. This would be simpler there was already a generic implementation... Tom