From: Tejun Heo <htejun@gmail.com>
To: Shaohua Li <shaohua.li@intel.com>
Cc: lkml <linux-kernel@vger.kernel.org>,
linux-ide <linux-ide@vger.kernel.org>,
Jens Axboe <jaxboe@fusionio.com>, Jeff Garzik <jgarzik@pobox.com>,
Christoph Hellwig <hch@infradead.org>,
"Darrick J. Wong" <djwong@us.ibm.com>
Subject: Re: [PATCH 1/2]block: optimize non-queueable flush request drive
Date: Tue, 26 Apr 2011 12:40:14 +0200 [thread overview]
Message-ID: <20110426104014.GA878@htj.dyndns.org> (raw)
In-Reply-To: <1303778559.3981.279.camel@sli10-conroe>
Hey,
On Tue, Apr 26, 2011 at 08:42:39AM +0800, Shaohua Li wrote:
> > What I was saying is that request completion is decoupled from driver
> > fetching requests from block layer and that the order of completion
> > doesn't necessarily follow the order of execution. IOW, nothing
> > guarantees that FLUSH completion code would run before the low level
> > driver fetches the next command and _completes_ it, in which case your
> > code would happily mark flush complete after write without actually
> > doing it.
>
> What I described is in the background of non-queueable flush request.
> For queueable flush, this definitely isn't correct.
We're definitely having communication issues. The above doesn't have
anything to do with queueability of flushes. It's about the
asynchronous nature of block request completion and issue paths, so it
can happen whether flush is queueable or not, or am I still
misunderstanding you?
> > Eh, wasn't your optimization only applicable if flush is not
> > queueable? IIUC, what your optimization achieves is merging
> > back-to-back flushes and you're achieving that in a _very_ non-obvious
> > round-about way. Do it in straight-forward way even if that costs
> > more lines of code.
>
> This isn't a problem of more code or less code. I thought my patch is
> already quite simple.
Well, then, we'll have to agree to disagree there as it looks really
hackish to me and I don't think it's even correct as written above.
> The method your described only works for non-queueable flush too. And it
> has limitation that the requests between two back-to-back flushes must
> not be write. my patch works for non-queueable flush but has no such
> limitation.
No, I'm saying you can achieve about the same effect in cleaner and
safer way if you teach the issue and completion paths properly about
these back-to-back flushes at the cost of more code changes. Your
patch doesn't work reliably whether flush is queueable or not.
> > Darrick, do you see flush performance regression between rc1 and rc2?
> > You're testing on higher end, so maybe it's still okay for you?
>
> please ignore the regression. the patch isn't related to the regression,
> but that problem motivates me to do the patch.
> Actually I still need the RFC patch in another thread to recover the
> regression. I hope you and Jens can seriously look at that issue too.
Ah, okay, it's a separately issue. Sorry about confusing the two.
I'll continue on another reply.
Thanks.
--
tejun
prev parent reply other threads:[~2011-04-26 10:40 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-04-19 8:44 [PATCH 1/2]block: optimize non-queueable flush request drive Shaohua Li
2011-04-22 23:32 ` Tejun Heo
2011-04-25 1:33 ` Shaohua Li
2011-04-25 8:58 ` Tejun Heo
2011-04-25 9:13 ` Tejun Heo
2011-04-26 0:46 ` Shaohua Li
2011-04-26 10:48 ` Tejun Heo
2011-04-28 7:50 ` Shaohua Li
2011-04-30 14:37 ` Tejun Heo
2011-05-03 6:44 ` Shaohua Li
2011-05-03 8:23 ` Tejun Heo
2011-05-04 6:20 ` Shaohua Li
2011-04-26 0:42 ` Shaohua Li
2011-04-26 10:40 ` Tejun Heo [this message]
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=20110426104014.GA878@htj.dyndns.org \
--to=htejun@gmail.com \
--cc=djwong@us.ibm.com \
--cc=hch@infradead.org \
--cc=jaxboe@fusionio.com \
--cc=jgarzik@pobox.com \
--cc=linux-ide@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=shaohua.li@intel.com \
/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).