From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 118998 invoked by alias); 14 Oct 2015 08:37:53 -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 117320 invoked by uid 89); 14 Oct 2015 08:37:51 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.2 required=5.0 tests=AWL,BAYES_00,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,SPF_PASS autolearn=ham version=3.3.2 X-HELO: mail-pa0-f54.google.com Received: from mail-pa0-f54.google.com (HELO mail-pa0-f54.google.com) (209.85.220.54) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES128-GCM-SHA256 encrypted) ESMTPS; Wed, 14 Oct 2015 08:37:50 +0000 Received: by pacex6 with SMTP id ex6so48251666pac.3 for ; Wed, 14 Oct 2015 01:37:48 -0700 (PDT) X-Received: by 10.68.69.79 with SMTP id c15mr2427615pbu.90.1444811868543; Wed, 14 Oct 2015 01:37:48 -0700 (PDT) Received: from E107787-LIN (gcc2-power8.osuosl.org. [140.211.9.43]) by smtp.gmail.com with ESMTPSA id pc8sm8172788pbc.27.2015.10.14.01.37.45 (version=TLS1_2 cipher=AES128-SHA256 bits=128/128); Wed, 14 Oct 2015 01:37:47 -0700 (PDT) From: Yao Qi To: Sergio Durigan Junior Cc: Yao Qi , gdb-patches@sourceware.org Subject: Re: [PATCH 06/11] Support displaced stepping in aarch64-linux References: <1444209985-15829-1-git-send-email-yao.qi@linaro.org> <1444209985-15829-7-git-send-email-yao.qi@linaro.org> <87612a7bx1.fsf@redhat.com> Date: Wed, 14 Oct 2015 08:37:00 -0000 In-Reply-To: <87612a7bx1.fsf@redhat.com> (Sergio Durigan Junior's message of "Tue, 13 Oct 2015 16:26:18 -0400") Message-ID: <86lhb54zhk.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-IsSubscribed: yes X-SW-Source: 2015-10/txt/msg00193.txt.bz2 Sergio Durigan Junior writes: > This patch broke GDB when compiling with --enable-build-with-cxx: > > > > You should also have received a message from the BuildBot, but I decided > to send this one just to be safe. Hi Sergio, I don't see such message in my linaro box. I only saw one message before, and I've fixed this build failure. "Your commit '[aarch64] use aarch64_decode_insn to decode instructions in G= DB' broke GDB" Anyway, patch below fixes the build failure. I've pushed it in. --=20 Yao (=E9=BD=90=E5=B0=A7) =46rom 6448a3e4daecbdba25e5c76b0fbb0c21583a1347 Mon Sep 17 00:00:00 2001 From: Yao Qi Date: Wed, 14 Oct 2015 09:23:14 +0100 Subject: [PATCH] Define enum out of struct This patch moves the definition of enum out of the scope of struct aarch64_memory_operand, otherwise it breaks GDB build in c++ mode. gdb: 2015-10-14 Yao Qi * arch/aarch64-insn.h (struct aarch64_memory_operand): Move enum out of it. (enum aarch64_memory_operand_type): New. diff --git a/gdb/ChangeLog b/gdb/ChangeLog index cabfe36..4b8ffb7 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,9 @@ +2015-10-14 Yao Qi + + * arch/aarch64-insn.h (struct aarch64_memory_operand): Move enum + out of it. + (enum aarch64_memory_operand_type): New. + 2015-10-13 David Edelsohn =20 * xcoffread.c (dwarf2_xcoff_names): Add .dwmac and .dwpbtyp. diff --git a/gdb/arch/aarch64-insn.h b/gdb/arch/aarch64-insn.h index d51cabc..cc7ec48 100644 --- a/gdb/arch/aarch64-insn.h +++ b/gdb/arch/aarch64-insn.h @@ -117,6 +117,13 @@ struct aarch64_register int is64; }; =20 +enum aarch64_memory_operand_type +{ + MEMORY_OPERAND_OFFSET, + MEMORY_OPERAND_PREINDEX, + MEMORY_OPERAND_POSTINDEX, +}; + /* Representation of a memory operand, used for load and store instructions. =20 @@ -129,12 +136,8 @@ struct aarch64_register struct aarch64_memory_operand { /* Type of the operand. */ - enum - { - MEMORY_OPERAND_OFFSET, - MEMORY_OPERAND_PREINDEX, - MEMORY_OPERAND_POSTINDEX, - } type; + enum aarch64_memory_operand_type type; + /* Index from the base register. */ int32_t index; };