Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754155Ab1BHNYP (ORCPT ); Tue, 8 Feb 2011 08:24:15 -0500 Received: from mail-gy0-f174.google.com ([209.85.160.174]:46578 "EHLO mail-gy0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752644Ab1BHNYO convert rfc822-to-8bit (ORCPT ); Tue, 8 Feb 2011 08:24:14 -0500 DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type:content-transfer-encoding; b=cAgCsSarg1+LWNkED/1x4LbMxPNUyoLzg1MegAMHMqMcNI6rK9Sarm9+A8hHemQvvv o67FkifhY/IshZZuqP00HR4yB7qZwdY00t/qDGDYuPxSpX7kUyfSo+WojY8NCSCv2Hha 5o/26NGQTuwEsn5I0gwQgciHmlKiSk4IRTClo= MIME-Version: 1.0 In-Reply-To: References: From: Hui Zhu Date: Tue, 8 Feb 2011 21:23:52 +0800 Message-ID: Subject: Re: [PATCH] Linux Kernel GDB tracepoint module 2011-02-05 To: Tom Tromey Cc: linux-kernel@vger.kernel.org, Michael Snyder , Marc Khouzam , Thiago Jung Bauermann , Steven , colyli@gmail.com, Christoph Hellwig , "gdb@sourceware.org" Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8BIT Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1625 Lines: 39 On Tue, Feb 8, 2011 at 00:25, Tom Tromey wrote: >>>>>> ">" == Hui Zhu writes: > >>> We have trouble for this printf is GDB is still not accept the patch >>> that make tracepoint support printf, So if you want use it, you need >>> patch the patch in >>> http://sourceware.org/ml/gdb-patches/2011-02/msg00063.html and build >>> your GDB with yourself. > > Thanks, I think this example was helpful. > >>> Sometimes, GDB will output some value like: >>> inode has been optimized out of existence. >>> res has been optimized out of existence. >>> That is because value of inode and res is optimized. Linux Kernel is >>> built with -O2 so you will get this trouble sometimes. If you do not >>> care about the speed when you debug the Kernel, you can use the patch >>> for Linux Kernel in > > I am curious to know what version of GCC you are using. ?IME, the VTA > patches really helped with this problem a lot -- though not completely. > If you are not using a VTA-enabled GCC, you should. ?And if you are, I > think bug reports about values that are still optimized out would be > useful. My gcc is 4.4.5. Does it have VTA? Use the patch is easier than update gcc sometimes, right? :) BTW does VTA can handle the issue that after -O2 a lot of code execution order is worong? It affect me when I debug the Linux Kernel in qemu. Thanks, Hui -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/