Some quick test with the sftp and sftp_nonblocking programs in
example/simple shows that the amount of data requested in the call to
libssh2_sftp_read() is much more important the the SSH packet size.
All test were between two computers on the same network connected by
100MBs switch and transferring a 616M zip compressed file
sftp/sftp_nonblock read size: 1K
================================
sftp sftp_nonblock
+---------+--------------
libssh2 max | 1:06.98 | 1:05.01
packet: 4K | 1:07.37 | 1:05.14
| 1:05.14 | 1:05.00
-------------+---------+--------------
libssh2 max | 1:05.71 | 1:11.32
packet: 32K | 1:05.19 | 1:04.83
| 1:05.30 | 1:05.22
sftp/sftp_nonblock read size: 16K
=================================
sftp sftp_nonblock
+---------+--------------
libssh2 max | 0:06.03 | 0:06.03
packet: 4K | 0:06.11 | 0:06.03
| 0:06.56 | 0:05.96
-------------+---------+--------------
libssh2 max | 0:06.14 | 0:06.01
packet: 32K | 0:06.04 | 0:05.93
| 0:06.11 | 0:05.92
Although these tests were simple, it shows that when reading the more
data you ask the library for in each call the better the performance.
Jim
--
/"\ ASCII Ribbon Campaign .
\ / - NO HTML/RTF in e-mail .
X - NO Word docs in e-mail .
/ \ -----------------------------------------------------------------
http://www.FreeBSD.org The Power to Serve
jim@TheHousleys.Net http://www.TheHousleys.net
---------------------------------------------------------------------
In theory there is no difference between theory and practice.
In practice there is no similarity.
-- From the "I wish I'd said that" archives.
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
libssh2-devel mailing list
libssh2-devel_at_lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/libssh2-devel
Received on 2007-06-19