I make an experiment of the simple buffering system on HDDs(cheetah)
controling with linux generic SCSI interface.
But, the SCSI command which is such a 'READ6' for /dev/sgX with the generic
interface is slower than the standard C function 'read()' for /dev/sdX.
Measuring difference between 'READ6' and 'read()' is below.
This test reads 200MByte to /dev/sda sequencially from the head of HDD.
The machine using this test is PPro with 128MByte DRAM.
Number of Data: 32k x 6400, 8k x 25600, 4k x 51200
READ6 : 41 sec, 154 sec, 308 sec
read() : 14 sec, 14 sec, 14 sec
Test program is such:
for( i=0; i<GETDATA; i++ ) {
memcpy( readbuffer, Read6( pos, BlockSize ), BlockSize*512 );
Or, read( fd, readbuffer, BlockSize*512 );
pos++;
}
READ6( pos, BlockSize ) puts 'READ6' SCSI command through generic SCSI
interface refering to SCSI-Programming-HOWTO.
pos means the logical block address, and BlockSize means one block size
in this test trying: 32k, 8k, 4k.
The result is teached me that the generic SCSI interface takes 6 msec
per one 'READ6' SCSI command.
It seems that the kernel blocks when kernel gets the generic SCSI
interface command.
Now question:
* How method is the generic SCSI interface to make more faster?
* Can a program using the generic SCSI interface run with pthread?
* Are there any way to make simple buffering system?
Regards,
--
GOTO Masanori
Tokyo Institute of Technology, Department of Computer Science
-
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
the body of a message to [EMAIL PROTECTED]