[zeromq-dev] ZMQ Performance

Patrick Sulin pjsulin at yahoo.com
Tue Jun 23 01:44:01 CEST 2009

I have just started to test the c++ and c# implementations of zeromq.  I have been running simple test to determine the relative 
speed of each implementation with respect to each other and to different message sizes.  Before I begin to tune my settings, I wanted 
to see if I could confirm two of my findings regarding throughput with others have made this comparison.

I began testing different message lengths with each implementation and with the c++ soon found that there was a serious drop-off, 
which I found to be 30 bytes.  I ran the following byte lengths, each 5 times and took the average, and got the following table:

Language        Message Length      Messages/sec
C++                        28                      1.52 million
C++                        29                      1.59 million         
C++                        30                      1.5 million
C++                        31                       .86 million
C++                        32                       .83

C#                        28                      .474 million
C#                        29                      .450 million         
C#                        30                      .446 million
C#                        31                       .360 million
C#                        32                       .345 million

So my questions are:

1. Is it accurate to say that the c++ library is about 3x as fast as the C#?
2. Is the steep drop-off after 30 bytes caused by obvious TCP setting, 
    and if so why does the c++ library lose over 40% and the C# only 20%?

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.zeromq.org/pipermail/zeromq-dev/attachments/20090622/932c3c16/attachment.htm>

More information about the zeromq-dev mailing list