Re: [cp-patches] RFC: InputStreamReader and OutputStreamWriter cleanup

2007-01-04 Thread Roman Kennke
Hi again, > >> However, if you look at the old code you'll see that we did use Buffers > >> even there. And copy from array into buffer and back. This is cleaned up > >> by this patch a little and also removed some copies and allocations. > >> I'll benchmark it this evening and see what comes out

Re: [cp-patches] RFC: InputStreamReader and OutputStreamWriter cleanup

2007-01-04 Thread David Daney
David Daney wrote: Roman Kennke wrote: Hi again, On most free JVMs that I know of (libgcj), array accesses are much faster than the corresponding actions on a java.nio.Buffer. I don't think so. The normal bytebuffer is also only an array. The accessor methods should not make much differe

Re: [cp-patches] RFC: InputStreamReader and OutputStreamWriter cleanup

2007-01-04 Thread David Daney
Roman Kennke wrote: Hi again, On most free JVMs that I know of (libgcj), array accesses are much faster than the corresponding actions on a java.nio.Buffer. I don't think so. The normal bytebuffer is also only an array. The accessor methods should not make much difference. The key differ

Re: [cp-patches] RFC: InputStreamReader and OutputStreamWriter cleanup

2007-01-04 Thread Roman Kennke
Hi again, > >>On most free JVMs that I know of (libgcj), array accesses are much > >>faster than the corresponding actions on a java.nio.Buffer. > > > > > > I don't think so. The normal bytebuffer is also only an array. The > > accessor methods should not make much difference. > > > > The key

Re: [cp-patches] RFC: InputStreamReader and OutputStreamWriter cleanup

2007-01-04 Thread David Daney
Roman Kennke wrote: On most free JVMs that I know of (libgcj), array accesses are much faster than the corresponding actions on a java.nio.Buffer. I don't think so. The normal bytebuffer is also only an array. The accessor methods should not make much difference. The key difference is that

Re: [cp-patches] RFC: InputStreamReader and OutputStreamWriter cleanup

2007-01-04 Thread Roman Kennke
Hi David, > > Ingo has done some work to clean up the encoding/decoding in > > InputStreamReader and OutputStreamWriter. Basically it uses NIO buffers > > now at both ends of the encoder or decoder which makes the code more > > clean and hopefully more efficient. > > > > It also improves the read

Re: [cp-patches] RFC: InputStreamReader and OutputStreamWriter cleanup

2007-01-04 Thread David Daney
Roman Kennke wrote: Hi, Ingo has done some work to clean up the encoding/decoding in InputStreamReader and OutputStreamWriter. Basically it uses NIO buffers now at both ends of the encoder or decoder which makes the code more clean and hopefully more efficient. It also improves the read() and w

[cp-patches] RFC: InputStreamReader and OutputStreamWriter cleanup

2007-01-04 Thread Roman Kennke
Hi, Ingo has done some work to clean up the encoding/decoding in InputStreamReader and OutputStreamWriter. Basically it uses NIO buffers now at both ends of the encoder or decoder which makes the code more clean and hopefully more efficient. It also improves the read() and write() methods to avoi