6916202: (so) improve scatter/gather implementation

Alan Bateman Alan.Bateman at oracle.com
Mon Jul 26 12:20:07 PDT 2010


The scatter/gather operations have always been slower than they should 
have been. The changes proposed here fix a couple of issues. The main 
one is that each scatter/gather operation was allocating and freeing a 
native iovec area. The second issue is that the implementation copied or 
iterated over the array of buffers several times. The third issue arose 
with applications invoking these methods with more than 3 buffers backed 
by arrays in the heap as this exceeded the capacity of the per thread 
buffer pool. The webrev with changes to fix these issues is here:
    http://cr.openjdk.java.net/~alanb/6916202/webrev/

Thanks,
Alan.


More information about the nio-dev mailing list