From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 52556 invoked by alias); 25 Jun 2018 10:38:35 -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 52144 invoked by uid 89); 25 Jun 2018 10:38:34 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.8 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_LOW,SPF_PASS autolearn=ham version=3.3.2 spammy= X-HELO: mx0a-001b2d01.pphosted.com Received: from mx0b-001b2d01.pphosted.com (HELO mx0a-001b2d01.pphosted.com) (148.163.158.5) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Mon, 25 Jun 2018 10:38:33 +0000 Received: from pps.filterd (m0098419.ppops.net [127.0.0.1]) by mx0b-001b2d01.pphosted.com (8.16.0.22/8.16.0.22) with SMTP id w5PAXgkp089531 for ; Mon, 25 Jun 2018 06:38:32 -0400 Received: from e06smtp02.uk.ibm.com (e06smtp02.uk.ibm.com [195.75.94.98]) by mx0b-001b2d01.pphosted.com with ESMTP id 2jtus601a7-1 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=NOT) for ; Mon, 25 Jun 2018 06:38:31 -0400 Received: from localhost by e06smtp02.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Mon, 25 Jun 2018 11:38:30 +0100 Received: from b06cxnps4075.portsmouth.uk.ibm.com (9.149.109.197) by e06smtp02.uk.ibm.com (192.168.101.132) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; (version=TLSv1/SSLv3 cipher=AES256-GCM-SHA384 bits=256/256) Mon, 25 Jun 2018 11:38:28 +0100 Received: from d06av25.portsmouth.uk.ibm.com (d06av25.portsmouth.uk.ibm.com [9.149.105.61]) by b06cxnps4075.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id w5PAcRsG30146646 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=FAIL); Mon, 25 Jun 2018 10:38:27 GMT Received: from d06av25.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 9FDFE11C058; Mon, 25 Jun 2018 11:38:22 +0100 (BST) Received: from d06av25.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 8F80C11C05C; Mon, 25 Jun 2018 11:38:22 +0100 (BST) Received: from oc3748833570.ibm.com (unknown [9.152.213.77]) by d06av25.portsmouth.uk.ibm.com (Postfix) with ESMTP; Mon, 25 Jun 2018 11:38:22 +0100 (BST) Received: by oc3748833570.ibm.com (Postfix, from userid 1000) id 77C0BD801CC; Mon, 25 Jun 2018 12:38:27 +0200 (CEST) Subject: Re: [PATCH 4/4] Variable size for regs mask in collection list To: pedromfc@linux.vnet.ibm.com (Pedro Franco de Carvalho) Date: Mon, 25 Jun 2018 10:38:00 -0000 From: "Ulrich Weigand" Cc: gdb-patches@sourceware.org In-Reply-To: <20180620210855.6385-5-pedromfc@linux.vnet.ibm.com> from "Pedro Franco de Carvalho" at Jun 20, 2018 06:08:55 PM MIME-Version: 1.0 X-TM-AS-GCONF: 00 x-cbid: 18062510-0008-0000-0000-0000024B812F X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 18062510-0009-0000-0000-000021B1EBCD Message-Id: <20180625103827.77C0BD801CC@oc3748833570.ibm.com> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 8bit X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:,, definitions=2018-06-25_05:,, signatures=0 X-SW-Source: 2018-06/txt/msg00576.txt.bz2 Pedro Franco de Carvalho wrote: > * tracepoint.h (collection_list) : Change type to > std::vector. > * tracepoint.c (collection_list::collection_list): Remove > m_regs_mask initializer from initializer list. Resize m_regs_mask > in using the number of registers from the arch. > (collection_list::add_register): Resize m_regs_mask instead of > throwing error when regno is too large. > (collection_list::stringify): Use size () instead of sizeof. Use > xsnprintf instead of sprintf. This is OK, but: > private: > /* room for up to 256 regs */ > - unsigned char m_regs_mask[32]; > + std::vector m_regs_mask; The comment is now wrong, so please remove it as well. Bye, Ulrich -- Dr. Ulrich Weigand GNU/Linux compilers and toolchain Ulrich.Weigand@de.ibm.com