From: Yohanes Santoso Date: 2002-11-09T02:00:22+09:00 Subject: Re: File::read Performance "Daniel Schnell" writes: > Hi there, > > if I make the following implementation of the command "cp" with ruby, the > read Performance is really bad. Can I improve it in any way ? First, make sure you're running ruby 1.6.7 (or is it 1.7) that has an improved IO#read and IO#write. Secondly, if you still think IO#read and IO#write are still too slow, use IO#sysread and IO#syswrite. Sometimes ago, I published a benchmark of ruby reading using IO#read, and IO#sysread, againsts UNIX's cat and perl's read. The result was IO#sysread was slightly faster than cat which was faster than perl's read which was faster than IO#read. Read more at: http://rubytalk.org/42780 YS.