From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 32121 invoked by alias); 24 Apr 2013 20:35:43 -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 32112 invoked by uid 89); 24 Apr 2013 20:35:43 -0000 X-Spam-SWARE-Status: No, score=-7.1 required=5.0 tests=AWL,BAYES_00,RCVD_IN_HOSTKARMA_W,RCVD_IN_HOSTKARMA_WL,RP_MATCHES_RCVD,SPF_HELO_PASS,SPF_PASS,TW_RG autolearn=ham version=3.3.1 Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.84/v0.84-167-ge50287c) with ESMTP; Wed, 24 Apr 2013 20:35:42 +0000 Received: from int-mx11.intmail.prod.int.phx2.redhat.com (int-mx11.intmail.prod.int.phx2.redhat.com [10.5.11.24]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id r3OKZa29002795 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Wed, 24 Apr 2013 16:35:36 -0400 Received: from barimba (ovpn01.gateway.prod.ext.phx2.redhat.com [10.5.9.1]) by int-mx11.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id r3OKZXHd006996 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES128-SHA bits=128 verify=NO); Wed, 24 Apr 2013 16:35:34 -0400 From: Tom Tromey To: Hui Zhu Cc: Pedro Alves , Eli Zaretskii , Hui Zhu , gdb-patches ml , Marc Khouzam Subject: Re: [PATCH] add -s option to make -break-insert support dprintf References: <515451EA.1000200@mentor.com> <83y5d7wpvq.fsf@gnu.org> <516454DA.9040109@redhat.com> <87ppxzhfqy.fsf@fleche.redhat.com> <516C2549.3060808@redhat.com> <87vc7ithtj.fsf@fleche.redhat.com> Date: Thu, 25 Apr 2013 06:51:00 -0000 In-Reply-To: (Hui Zhu's message of "Sun, 21 Apr 2013 12:59:13 +0800") Message-ID: <87wqrrll9m.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-04/txt/msg00759.txt.bz2 >>>>> "Hui" == Hui Zhu writes: Hui> Does GDB have some function can convert string to "" inside string? I wouldn't rule it out but I couldn't think of one offhand. Hui> Could you give me some comments about the new format for -s. Hui> My thought is: Hui> -s format argv1 argv2, other options Hui> "-break-insert -s FORMAT LOCATION ARG ARG ARG ..." is too different Hui> with current options of -break-insert and very hard to support. What is hard about it? In mi_cmd_break_insert, if '-s' was given, use argv[oind+1] through argv[argc-1] as the arguments. Maybe the hard part is getting this through create_breakpoint? That is just further proof that it is a bad API. TBH I don't see why this needs to be in -break-insert. A new command seems cleaner to me. But I don't want to press too hard either. Tom