From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 116155 invoked by alias); 2 Nov 2016 10:01:57 -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 116121 invoked by uid 89); 2 Nov 2016 10:01:55 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-3.9 required=5.0 tests=AWL,BAYES_00,RP_MATCHES_RCVD,SPF_PASS autolearn=ham version=3.3.2 spammy=supervisory, Tel, tel, commercial X-HELO: mga14.intel.com Received: from mga14.intel.com (HELO mga14.intel.com) (192.55.52.115) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Wed, 02 Nov 2016 10:01:43 +0000 Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by fmsmga103.fm.intel.com with ESMTP; 02 Nov 2016 03:01:41 -0700 X-ExtLoop1: 1 Received: from irsmsx107.ger.corp.intel.com ([163.33.3.99]) by fmsmga006.fm.intel.com with ESMTP; 02 Nov 2016 03:01:40 -0700 Received: from irsmsx105.ger.corp.intel.com ([169.254.7.177]) by IRSMSX107.ger.corp.intel.com ([169.254.10.56]) with mapi id 14.03.0248.002; Wed, 2 Nov 2016 10:01:40 +0000 From: "Wiederhake, Tim" To: 'Simon Marchi' CC: "gdb-patches@sourceware.org" , "palves@redhat.com" , "Metzger, Markus T" Subject: RE: [PATCH 3/7] btrace: Use binary search to find instruction. Date: Wed, 02 Nov 2016 10:01:00 -0000 Message-ID: <9676A094AF46E14E8265E7A3F4CCE9AF90CE3F@irsmsx105.ger.corp.intel.com> References: <1477549711-2603-1-git-send-email-tim.wiederhake@intel.com> <1477549711-2603-4-git-send-email-tim.wiederhake@intel.com> <32eeec01cc2ddc61dcb90caab5a6e645@polymtl.ca> In-Reply-To: <32eeec01cc2ddc61dcb90caab5a6e645@polymtl.ca> Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-IsSubscribed: yes X-SW-Source: 2016-11/txt/msg00009.txt.bz2 Hi Simon, Thanks for your input! > Unless you expect to backport this patch in the 7.12 branch (which I don'= t think is the case here), you can use C++ standard containers and function= s. Specifically, std::vector instead of DEF_VEC, and probably std::lower_b= ound (if I understand correctly what the code is doing). struct btrace_thread_info is initialized by memset'ing it to zero. If I'm n= ot mistaken we can't do that if the struct contains a C++ member with a con= structor. > Also, since we now have btrace_function pointers in a sorted vector, do w= e still need them to be linked together as a linked list? The btrace_function pointers will go away in the next patch series. Tim Intel Deutschland GmbH Registered Address: Am Campeon 10-12, 85579 Neubiberg, Germany Tel: +49 89 99 8853-0, www.intel.de Managing Directors: Christin Eisenschmid, Christian Lamprechter Chairperson of the Supervisory Board: Nicole Lau Registered Office: Munich Commercial Register: Amtsgericht Muenchen HRB 186928