C++ Socket Server - Unable to saturate CPU

后端 未结 6 1025
刺人心
刺人心 2020-11-29 23:18

I\'ve developed a mini HTTP server in C++, using boost::asio, and now I\'m load testing it with multiple clients and I\'ve been unable to get close to saturating the CPU. I

6条回答
  •  遥遥无期
    2020-11-29 23:48

    From your comments on network utilization,
    You do not seem to have much network movement.

    3 + 2.5 MiB/sec is around the 50Mbps ball-park (compared to your 1Gbps port).

    I'd say you are having one of the following two problems,

    1. Insufficient work-load (low request-rate from your clients)
      • Blocking in the server (interfered response generation)

    Looking at cmeerw's notes and your CPU utilization figures
    (idling at 50% + 20% + 0% + 0%)
    it seems most likely a limitation in your server implementation.
    I second cmeerw's answer (+1).

提交回复
热议问题