I think it is not problem of gc, it is my fault: The operations is serialized: clent send -> server recv -> server send -> client recv, so if one operation takes too long time, the throughput will definitely fall down. I cant explain why it so fast when buffer is big enough, and so low when buffer is smaller than data size.