Poor boost.ASIO performance

后端 未结 2 1706
北荒
北荒 2021-01-30 11:45

I have a very simple server/client performance test using boost::asio on Windows and it seems to be performing really poorly. I\'m hoping that I\'m just using the library incor

2条回答
  •  耶瑟儿~
    2021-01-30 12:06

    You must turn off the Nagle algorithm. Call:

    m_socket.set_option(tcp::no_delay(true));
    

    Where appropriate for your code.

提交回复
热议问题