mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "Adam J. Richter" <adam@yggdrasil.com>
To: davej@suse.de
Cc: axboe@suse.de, linux-kernel@vger.kernel.org
Subject: Re: Patch?: linux-2.5.2-pre9/drivers/block/ll_rw_blk.c blk_rq_map_sg simplification
Date: Mon, 7 Jan 2002 05:23:28 -0800	[thread overview]
Message-ID: <200201071323.FAA04244@adam.yggdrasil.com> (raw)

>>> = Adam Richter (adam@yggdrasil.com)
>>  = Jens Axboe (axboe@suse.de)
>   = Dave Jones (davej@suse.de)
>>> 	The following patch removes gotos from blk_rq_map_sg, making
>>> it more readable and five lines shorter.  I think the compiler should
>>> generate the same code.  I have not tested this other than to
>>> verify that it compiles.
>> Well, I really think the original is much more readable than the changed
>> version :-)

>I agree. Upon seeing the patch, I was reminded of the monster
>enormous conditional at http://gcc.gnu.org/projects/beginner.html
>not quite _that_ bad, but getting there 8)

	The conditional is one level deep (it's just a list of
"and" conjunctions) and has a single conceptual meaning, "are
the segments joinable?"  For what it's worth, I really could not
understand the old version until I rewrote it without gotos.

Adam J. Richter     __     ______________   4880 Stevens Creek Blvd, Suite 104
adam@yggdrasil.com     \ /                  San Jose, California 95129-1034
+1 408 261-6630         | g g d r a s i l   United States of America
fax +1 408 261-6631      "Free Software For The Rest Of Us."

             reply	other threads:[~2002-01-07 13:27 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-01-07 13:23 Adam J. Richter [this message]
2002-01-07 13:25 ` Dave Jones
  -- strict thread matches above, loose matches on Subject: below --
2002-01-07  8:55 Adam J. Richter
2002-01-07  9:03 ` Jens Axboe
2002-01-07 13:02   ` Dave Jones

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=200201071323.FAA04244@adam.yggdrasil.com \
    --to=adam@yggdrasil.com \
    --cc=axboe@suse.de \
    --cc=davej@suse.de \
    --cc=linux-kernel@vger.kernel.org \
    /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

all inboxes | Powered by JetHome®