From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 4891 invoked by alias); 18 Dec 2009 20:03:34 -0000 Received: (qmail 4883 invoked by uid 22791); 18 Dec 2009 20:03:34 -0000 X-SWARE-Spam-Status: No, hits=-2.3 required=5.0 tests=AWL,BAYES_00,SPF_PASS X-Spam-Check-By: sourceware.org Received: from mail.codesourcery.com (HELO mail.codesourcery.com) (38.113.113.100) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Fri, 18 Dec 2009 20:03:24 +0000 Received: (qmail 11197 invoked from network); 18 Dec 2009 20:03:23 -0000 Received: from unknown (HELO macbook-2.local) (stan@127.0.0.2) by mail.codesourcery.com with ESMTPA; 18 Dec 2009 20:03:23 -0000 Message-ID: <4B2BE005.4090004@codesourcery.com> Date: Fri, 18 Dec 2009 20:03:00 -0000 From: Stan Shebs User-Agent: Thunderbird 2.0.0.23 (Macintosh/20090812) MIME-Version: 1.0 To: tromey@redhat.com CC: Stan Shebs , gdb-patches@sourceware.org Subject: Re: [PATCH] Trace state variables References: <4B279456.1010508@codesourcery.com> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit 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 X-SW-Source: 2009-12/txt/msg00267.txt.bz2 Tom Tromey wrote: >>>>>> "Stan" == Stan Shebs writes: >>>>>> > > Stan> Since internalvar handling has changed recently, I've left off the > Stan> value.c bit to make "print $foo" work. > > Will this be forthcoming? > Yep, just have to figure out the new way of things. > Stan> + case BINOP_ASSIGN: > > It seems a little odd to add BINOP_ASSIGN but not BINOP_ASSIGN_MODIFY. > You're going to make me do it, aren't you. :-) > Stan> extern int remote_supports_cond_tracepoints (void); > Stan> + extern char *unpack_varlen_hex (char *buff, ULONGEST *result); > > It seems like this could be in a header somewhere. > This is one of the temporary hacks pending target-vectorization of tracepoint ops. > Stan> + /* The list of all trace state variables. We don't retain pointers to > Stan> + any of these for any reason - API is by name or number only - so it > Stan> + works to have a vector of objects. */ > Stan> + > Stan> + VEC(tsv_s) *tvariables; > Stan> + > Stan> + /* The next integer to assign to a variable. */ > Stan> + > Stan> + int next_tsv_number = 1; > > It seems like these, plus some of the new functions, could be static. > It is hard to say for sure since I don't know what future patches might do. > They could be, yeah, remote.c code will handle tsv's one-by-one, no need to pass whole list. > Stan> + static void > Stan> + tvariables_info (char *args, int from_tty) > [...] > Stan> + printf_filtered (_("Name\t\t Initial\tCurrent\n")); > > I think that brand-new formatted output should be done using the ui_out > machinery. Is there some drawback to doing that? I really don't > know... I would have expected ui_out to be used universally but instead > it seems somewhat random, and I don't know why. (I assume that whoever > was doing this transition ran out of steam... ?) > I can't even remember why I didn't use ui_out. Well, that's why we do reviews... :-) Stan