netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Petko Manolov <petkan@mip-labs.com>
To: Oliver Neukum <oneukum@suse.com>
Cc: Guenter Roeck <linux@roeck-us.net>,
	Heinrich Schuchardt <xypron.glpk@gmx.de>,
	Petko Manolov <petkan@nucleusys.com>,
	linux-kernel@vger.kernel.org, linux-usb@vger.kernel.org,
	netdev@vger.kernel.org
Subject: Re: [1/1] net: pegasus: remove dead coding
Date: Wed, 18 May 2016 10:50:45 +0300	[thread overview]
Message-ID: <20160518075045.GC4388@p310> (raw)
In-Reply-To: <1463555740.22748.0.camel@suse.com>

On 16-05-18 09:15:40, Oliver Neukum wrote:
> On Tue, 2016-05-17 at 23:30 -0700, Guenter Roeck wrote:
> > On Wed, May 18, 2016 at 02:13:30AM +0200, Heinrich Schuchardt wrote:
> > > (!count || count < 4) is always true.
> > 
> > Even if count >= 4 ?
> 
> The check for !count is redundant, though. Gcc, however,
> will surely simplify the expression.

Yep, gcc-6 generates this code:

	...
	cmp	$0x3,%edx
	jle	b9 <read_bulk_callback+0x69>
	...

Which does not invalidate your statement that "!count" is redundant. :)


		Petko

  reply	other threads:[~2016-05-18  7:50 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-05-18  0:13 [PATCH 1/1] net: pegasus: remove dead coding Heinrich Schuchardt
2016-05-18  6:25 ` Petko Manolov
2016-05-18  6:30 ` [1/1] " Guenter Roeck
2016-05-18  7:15   ` Oliver Neukum
2016-05-18  7:50     ` Petko Manolov [this message]
2016-05-18 18:40     ` [PATCH 1/1] net: pegasus: simplify logical constraint Heinrich Schuchardt
2016-05-19  5:57       ` Petko Manolov
2016-05-23 20:49       ` David Miller
2016-05-19 18:35 ` [PATCH 1/1] net: pegasus: remove dead coding David Miller
2016-05-20  7:33   ` Petko Manolov
2016-05-20 16:38     ` David Miller

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=20160518075045.GC4388@p310 \
    --to=petkan@mip-labs.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-usb@vger.kernel.org \
    --cc=linux@roeck-us.net \
    --cc=netdev@vger.kernel.org \
    --cc=oneukum@suse.com \
    --cc=petkan@nucleusys.com \
    --cc=xypron.glpk@gmx.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;
as well as URLs for NNTP newsgroup(s).