From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 17609 invoked by alias); 18 Mar 2010 16:44:42 -0000 Received: (qmail 17601 invoked by uid 22791); 18 Mar 2010 16:44:42 -0000 X-SWARE-Spam-Status: No, hits=-7.4 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_HI,SPF_HELO_PASS X-Spam-Check-By: sourceware.org Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Thu, 18 Mar 2010 16:44:37 +0000 Received: from int-mx04.intmail.prod.int.phx2.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.17]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id o2IGW7VN025445 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Thu, 18 Mar 2010 12:32:07 -0400 Received: from ns3.rdu.redhat.com (ns3.rdu.redhat.com [10.11.255.199]) by int-mx04.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id o2IGW7cC013248; Thu, 18 Mar 2010 12:32:07 -0400 Received: from opsy.redhat.com (ovpn01.gateway.prod.ext.phx2.redhat.com [10.5.9.1]) by ns3.rdu.redhat.com (8.13.8/8.13.8) with ESMTP id o2IGW6cu004674; Thu, 18 Mar 2010 12:32:06 -0400 Received: by opsy.redhat.com (Postfix, from userid 500) id 1BEC5379848; Thu, 18 Mar 2010 10:32:06 -0600 (MDT) From: Tom Tromey To: Stan Shebs Cc: gdb-patches@sourceware.org Subject: Re: [PATCH] More C++ static fields for tracepoints References: <4BA15504.9020707@codesourcery.com> Reply-To: tromey@redhat.com Date: Thu, 18 Mar 2010 16:44:00 -0000 In-Reply-To: <4BA15504.9020707@codesourcery.com> (Stan Shebs's message of "Wed, 17 Mar 2010 15:17:40 -0700") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii 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: 2010-03/txt/msg00667.txt.bz2 >>>>> "Stan" == Stan Shebs writes: Stan> This patch solves a couple intertwined problems relating to Stan> tracepoint collection of C++ classes with static fields. First, Stan> it adds recognition of variables (including static fields) whose Stan> location expressions indicate that they have been optimized out. As ax-gdb grows I am starting to wonder whether we could unify it with eval.c somehow. Stan> Second, to collect an instance of a class with static fields, we Stan> need to issue more bytecodes, since static fields are stored at Stan> their own addresses, separately from the instance. A static field may itself be of a type with static fields. That doesn't seem to be handled in this code... should it be? And if so, be careful about the case where a class refers to itself recursively via static fields; we still have some printing bugs in this area :( Tom