From patchwork Mon Dec 21 13:58:19 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yao Qi X-Patchwork-Id: 10092 Received: (qmail 112068 invoked by alias); 21 Dec 2015 13:58:29 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Delivered-To: mailing list gdb-patches@sourceware.org Received: (qmail 112055 invoked by uid 89); 21 Dec 2015 13:58:29 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.3 required=5.0 tests=AWL, BAYES_00, FREEMAIL_FROM, RCVD_IN_DNSWL_LOW, SPF_PASS autolearn=ham version=3.3.2 spammy=aarch32, Hx-languages-length:2226 X-HELO: mail-pa0-f51.google.com Received: from mail-pa0-f51.google.com (HELO mail-pa0-f51.google.com) (209.85.220.51) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES128-GCM-SHA256 encrypted) ESMTPS; Mon, 21 Dec 2015 13:58:27 +0000 Received: by mail-pa0-f51.google.com with SMTP id wq6so100202927pac.1 for ; Mon, 21 Dec 2015 05:58:27 -0800 (PST) X-Received: by 10.67.3.230 with SMTP id bz6mr27279535pad.118.1450706306036; Mon, 21 Dec 2015 05:58:26 -0800 (PST) Received: from E107787-LIN (gcc1-power7.osuosl.org. [140.211.15.137]) by smtp.gmail.com with ESMTPSA id q66sm28367688pfi.13.2015.12.21.05.58.22 (version=TLS1_2 cipher=AES128-SHA bits=128/128); Mon, 21 Dec 2015 05:58:24 -0800 (PST) From: Yao Qi To: Antoine Tremblay Cc: Subject: Re: [PATCH v8 5/7] Support software single step on ARM in GDBServer References: <1450361684-29536-1-git-send-email-antoine.tremblay@ericsson.com> <1450361684-29536-6-git-send-email-antoine.tremblay@ericsson.com> Date: Mon, 21 Dec 2015 13:58:19 +0000 In-Reply-To: <1450361684-29536-6-git-send-email-antoine.tremblay@ericsson.com> (Antoine Tremblay's message of "Thu, 17 Dec 2015 09:14:42 -0500") Message-ID: <86bn9jewec.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux) MIME-Version: 1.0 X-IsSubscribed: yes Antoine Tremblay writes: > -#if (defined __ARM_EABI__ || defined __aarch64__) > -static const unsigned long arm_breakpoint = arm_eabi_breakpoint; > -#else > -static const unsigned long arm_breakpoint = arm_abi_breakpoint; > -#endif > - > + > +#ifndef __ARM_EABI__ > +static const unsigned long arm_breakpoint = arm_abi_breakpoint; > +#else > +static const unsigned long arm_breakpoint = arm_eabi_breakpoint; > +#endif Your code move actually changes the code. My recent fix https://sourceware.org/ml/gdb-patches/2015-12/msg00215.html was removed by mistake. This breaks the whole aarch64 multi-arch debugging. I'll push the patch below in. diff --git a/gdb/gdbserver/ChangeLog b/gdb/gdbserver/ChangeLog index e38d71d..1d240f2 100644 --- a/gdb/gdbserver/ChangeLog +++ b/gdb/gdbserver/ChangeLog @@ -1,3 +1,8 @@ +2015-12-21 Yao Qi + + * linux-aarch32-low.h [__aarch64__]: Use arm_abi_breakpoint + arm breakpoint. + 2015-12-18 Antoine Tremblay * server.c (handle_query): Call target_supports_software_single_step. diff --git a/gdb/gdbserver/linux-aarch32-low.h b/gdb/gdbserver/linux-aarch32-low.h index d452894..fe0aaf5 100644 --- a/gdb/gdbserver/linux-aarch32-low.h +++ b/gdb/gdbserver/linux-aarch32-low.h @@ -24,10 +24,10 @@ ABI's breakpoint instruction. For now at least. */ #define arm_eabi_breakpoint 0xe7f001f0UL -#ifndef __ARM_EABI__ -static const unsigned long arm_breakpoint = arm_abi_breakpoint; -#else +#if (defined __ARM_EABI__ || defined __aarch64__) static const unsigned long arm_breakpoint = arm_eabi_breakpoint; +#else +static const unsigned long arm_breakpoint = arm_abi_breakpoint; #endif #define arm_breakpoint_len 4