public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Mike Frysinger <vapier@gentoo.org>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH] Change dead code in "test" cmd to debug output
Date: Fri, 17 Aug 2012 19:41:15 -0400	[thread overview]
Message-ID: <201208171941.16773.vapier@gentoo.org> (raw)
In-Reply-To: <1345236972-20010-1-git-send-email-joe.hershberger@ni.com>

On Friday 17 August 2012 16:56:12 Joe Hershberger wrote:
> --- a/common/cmd_test.c
> +++ b/common/cmd_test.c
> 
> -#if 0
> +#ifdef DEBUG
>  	{
> -		printf("test:");
> +		debug("test(%d):", argc);
>  		left = 1;
>  		while (argv[left])
> -			printf(" %s", argv[left++]);
> +			debug(" '%s'", argv[left++]);
>  	}
>  #endif

i think you can even remove the #ifdef DEBUG here since debug() will expand to 
nothing, and gcc should do DCE on the whole block
-mike
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: This is a digitally signed message part.
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20120817/a0549fde/attachment.pgp>

  reply	other threads:[~2012-08-17 23:41 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-08-17 20:56 [U-Boot] [PATCH] Change dead code in "test" cmd to debug output Joe Hershberger
2012-08-17 23:41 ` Mike Frysinger [this message]
2012-10-03 20:46   ` Joe Hershberger
2012-10-04  1:19 ` [U-Boot] " Tom Rini

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=201208171941.16773.vapier@gentoo.org \
    --to=vapier@gentoo.org \
    --cc=u-boot@lists.denx.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox