linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* File IO performance
@ 2001-02-14 12:47 simon
  2001-02-14 14:07 ` Marcelo Tosatti
  0 siblings, 1 reply; 6+ messages in thread
From: simon @ 2001-02-14 12:47 UTC (permalink / raw)
  To: linux-kernel

I have been performing some IO tests under Linux on SCSI disks.
I noticed gaps between the commands and decided to investigate.
I am new to the kernel and do not profess to underatand what 
actually happens. My observations suggest that the file 
structured part of the io consists of the following file phases 
which mainly reside in mm/filemap.c . The user read call ends up in
a generic file read routine. If the requested buffer is not in
the file cache then the data is requested from disk via the disk 
readahead routine. When this routine completes the data is copied 
to user space. I have been looking at these phases on an analyzer
and it seems that none of them overlap for a single user process. 

This creates gaps in the scsi commands which significantly reduce
bandwidth, particularly at todays disk speeds. 

I am interested in making changes to the readahead routine. In this 
routine there is a loop


 /* Try to read ahead pages.
  * We hope that ll_rw_blk() plug/unplug, coalescence, requests sort
  * and the scheduler, will work enough for us to avoid too bad 
  * actuals IO requests. 
  */ 

 while (ahead < max_ahead) {
  ahead ++;
  if ((raend + ahead) >= end_index)
   break;
  if (page_cache_read(filp, raend + ahead) < 0)
 }


this whole loop completes before the disk command starts. If the 
commands are large and it is for a maximum read ahead this loops 
takes some time and is followed by disk commands. 

It seems that the performance could be improved if the disk commands 
were overlapped in some way with the time taken in this loop. I have 
not traced page_cache_read so I have no idea what is happening but I 
guess this is some page location and entry onto the specific device 
buffer queues ?

I am really looking for some help in underatanding what is happening 
here and suggestions in ways which operations may be overlapped.
__________________________

Simon Haynes - Baydel 
Phone : 44 (0) 1372 378811
Email : simon@baydel.com
__________________________

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2001-02-14 21:14 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-02-14 12:47 File IO performance simon
2001-02-14 14:07 ` Marcelo Tosatti
2001-02-14 17:19   ` simon
2001-02-14 17:44   ` Steve Lord
2001-02-14 17:38     ` Marcelo Tosatti
2001-02-14 21:15       ` Steve Lord

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).