Comparison between the textual protocol and the binary protocol

Trond Norbye Trond.Norbye at Sun.COM
Mon Apr 7 10:23:25 UTC 2008


Today I did a comparison between the textual and the binary protocol.

System calls:
I used a single thread to insert 10 000 object into the cache and then  
perform 10 000 get operations. I used truss -c to count the number of  
system calls on the server, and the textual and the binary protocol  
used the exact same number of read / sendmsg calls.

Performance:
I used my test-program to simulate 8 active clients in a pool of 5000  
clients (using 8 threads and that picks a random idle client and  
performs a get-operation). I did 1 000 000 get-operations for 1k  
objects, and the performance and CPU usage was pretty much the same  
(The binary protocol a little bit (2-3%) better/faster).

Trond



More information about the memcached mailing list