Re: [RFC][PATCH] Make io_submit non-blocking

2012-07-26 Thread Zach Brown
On Fri, Jul 27, 2012 at 01:22:10AM +0530, Ankit Jain wrote: > I should probably be doing better tests, any suggestions on what or > how I can test? Well, is the test actually *doing* anything with these IOs? Calling io_submit() and then immediately waiting for completion is the best case for off

Re: [RFC][PATCH] Make io_submit non-blocking

2012-07-26 Thread Ankit Jain
On 07/25/2012 04:20 AM, Christoph Hellwig wrote: > On Wed, Jul 25, 2012 at 08:31:10AM +1000, Dave Chinner wrote: >> FWIW, if you are going to change generic code, you need to present >> results for other filesystems as well (xfs, btrfs are typical), as >> they may not have the same problems as ext4

Re: [RFC][PATCH] Make io_submit non-blocking

2012-07-25 Thread Ankit Jain
On 07/25/2012 04:07 AM, Zach Brown wrote: > On Tue, Jul 24, 2012 at 05:11:05PM +0530, Ankit Jain wrote: [snip] >> With this patch, io_submit prepares all the kiocbs and then >> adds (kicks) them to ctx->run_list (kicked) in one go and then >> schedules the workqueue. The actual operations are not e

Re: [RFC][PATCH] Make io_submit non-blocking

2012-07-25 Thread Ankit Jain
On 07/25/2012 04:01 AM, Dave Chinner wrote: > On Tue, Jul 24, 2012 at 05:11:05PM +0530, Ankit Jain wrote: [snip] >> **Unpatched** >> read : io=102120KB, bw=618740 B/s, iops=151 , runt=169006msec >> slat (usec): min=275 , max=87560 , avg=6571.88, stdev=2799.57 > > Hmmm, I had to check the numbers t

Re: [RFC][PATCH] Make io_submit non-blocking

2012-07-24 Thread Zach Brown
> And most importantly block devices, as they are one of the biggest > use cases of AIO. With an almost no-op get_blocks callback I can't > see how this change would provide any gain there. Historically we'd often see submission stuck waiting for requests. Tasks often try to submit way more aio t

Re: [RFC][PATCH] Make io_submit non-blocking

2012-07-24 Thread Christoph Hellwig
On Wed, Jul 25, 2012 at 08:31:10AM +1000, Dave Chinner wrote: > FWIW, if you are going to change generic code, you need to present > results for other filesystems as well (xfs, btrfs are typical), as > they may not have the same problems as ext4 or react the same way to > your change. The result mi

Re: [RFC][PATCH] Make io_submit non-blocking

2012-07-24 Thread Zach Brown
On Tue, Jul 24, 2012 at 05:11:05PM +0530, Ankit Jain wrote: > > Currently, io_submit tries to execute the io requests on the > same thread, which could block because of various reaons (eg. > allocation of disk blocks). So, essentially, io_submit ends > up being a blocking call. Yup, sadly that's

Re: [RFC][PATCH] Make io_submit non-blocking

2012-07-24 Thread Dave Chinner
On Tue, Jul 24, 2012 at 05:11:05PM +0530, Ankit Jain wrote: > > Currently, io_submit tries to execute the io requests on the > same thread, which could block because of various reaons (eg. > allocation of disk blocks). So, essentially, io_submit ends > up being a blocking call. > > With this patc

Re: [RFC][PATCH] Make io_submit non-blocking

2012-07-24 Thread Theodore Ts'o
On Tue, Jul 24, 2012 at 06:04:23PM +0530, Rajat Sharma wrote: > > > > Currently, io_submit tries to execute the io requests on the > > same thread, which could block because of various reaons (eg. > > allocation of disk blocks). So, essentially, io_submit ends > > up being a blocking call. > > Ide

Re: [RFC][PATCH] Make io_submit non-blocking

2012-07-24 Thread Rajat Sharma
Hi Ankit, On Tue, Jul 24, 2012 at 5:11 PM, Ankit Jain wrote: > > > Currently, io_submit tries to execute the io requests on the > same thread, which could block because of various reaons (eg. > allocation of disk blocks). So, essentially, io_submit ends > up being a blocking call. > Ideally file

[RFC][PATCH] Make io_submit non-blocking

2012-07-24 Thread Ankit Jain
Currently, io_submit tries to execute the io requests on the same thread, which could block because of various reaons (eg. allocation of disk blocks). So, essentially, io_submit ends up being a blocking call. With this patch, io_submit prepares all the kiocbs and then adds (kicks) them to ctx->ru