From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:51181) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1R0Uhh-0002xG-AJ for qemu-devel@nongnu.org; Mon, 05 Sep 2011 04:38:54 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1R0Uhg-0002dW-3Z for qemu-devel@nongnu.org; Mon, 05 Sep 2011 04:38:52 -0400 Received: from mx1.redhat.com ([209.132.183.28]:56791) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1R0Uhf-0002d6-RV for qemu-devel@nongnu.org; Mon, 05 Sep 2011 04:38:52 -0400 Message-ID: <4E648A91.1080305@redhat.com> Date: Mon, 05 Sep 2011 10:38:41 +0200 From: Gerd Hoffmann MIME-Version: 1.0 References: <1315063347-26961-1-git-send-email-stefanha@linux.vnet.ibm.com> In-Reply-To: <1315063347-26961-1-git-send-email-stefanha@linux.vnet.ibm.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH] ehci: avoid string arguments in trace events List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Stefan Hajnoczi Cc: qemu-devel@nongnu.org On 09/03/11 17:22, Stefan Hajnoczi wrote: > String arguments are not supported by all trace backends. This patch > replaces existing string arguments in hw/usb-ehci.c either with > individual trace events that remain human-friendly or by printing raw > addresses when there is no alternative or downside to that. Printing raw addresses *is* a downside. > States and usbsts bits remain human-friendly since it is hard to > remember all of them. MMIO addresses are printed raw because they would > create many individual trace events and the addresses are usually easy > to remember when debugging. I find it hard to rememeber them. There is a reason why the code to print the names for the mmio addresses is there in the first place. I don't want to loose that. Can't we just fix the backends instead? Replacing debug fprintf with trace points isn't going to work if tracing can't handle strings. cheers, Gerd