Home > Software engineering >  IOCP performance issues, really will use more and more slow?
IOCP performance issues, really will use more and more slow?

Time:10-23

The test hardware:
64 10 Windows 32-bit programs (C/S)
I7 8-core
8 gb of memory

A test scenario:

C is the same as the S IOCP core, occupy the IO queue system together, of course, is two separate programs, but I want to now that are using IOCP core, should be take up system IOCP queue

Testing of business:
C for S long TCP/IP connections, connection, send a heartbeat every 10 seconds, connection bolt not actively

This is a stress test to see where maximum performance can achieve:

Say first server status:
S basic not how CPU and memory consumption, low consumption has been below 10%, memory slowly climb to 100 m
According to my performance statistics: S 1500 IO operations per second, 1000 ~ 2500 of

Question:
From the beginning, until completely can't response (about 9000 links don't don't of the timeout)

[23:06:01 (580)] connection Socket set up successful, thread ID: 735 c, the Socket=1276
[23:06:01 (580)] connection Socket set up successful, thread ID: 2 ec8, Socket=1256
[23:06:01 (593)] connect to the server success 192.168.0.101:39999, thread ID: 735 c, the local connection information: 192.168.0.101:32896, SOCKET=1276, time: 0.65 ms
[23:06:01 (594)] connect to the server success 192.168.0.101:39999, thread ID: 2 ec8, local connection information: 192.168.0.101:32897, SOCKET=1256, time: 0.45 ms

Until then, now 8000 connection

[23:56:41 (146)] connect to the server success 192.168.0.101:39999, thread ID: 2 d7c, local connection information: 192.168.0.101:43193, SOCKET=33380, time: 16776.38 ms
[23:56:41 (146)] from [the CHECKIN] time-consuming to 22814.94 ms
[23:56:41 (147)] from [the CHECKIN] time-consuming to 22848.86 ms

Is really to,,, IOCP is more with more slow?
Time consuming, because now large level server and client CPU is not more than 5%, is take up all of the systems is 20%

I understand, have delivery, then the delivery has been processed, then the queue will reduce, I don't know how to get to the monitoring or for system resides on IOCP queue, unable to see, can only guess,
In ProcXP, see IO processing value is as follows (8000)

S IO READS: 111
S IO WRITE 104290
S IO OTHRE 1857981

15 C IO READS:
C IO WRITE 7531489
The CIO OTHRE 1933050

My understanding is that READS is Recv, why the server only 111? And the Write is so big, and the OTHER is what the devil, more large

Don't know whether there is a great god, and to solve the problem of a kind of want to grant instruction,

CodePudding user response:

Ok, write their own posts is to look at, I know why S & amp; C IO WRITE why so high, because it is in that first log writing, but still don't know what is the OTHER, is there any way we can see the IOCP queue, I want to know why the IOCP why more and more slow

CodePudding user response:

The
refer to the original poster jasonabc1 response:
test hardware:
64 10 Windows 32-bit programs (C/S)
I7 8-core
8 gb of memory

A test scenario:

C is the same as the S IOCP core, occupy the IO queue system together, of course, is two separate programs, but I want to now that are using IOCP core, should be take up system IOCP queue

Testing of business:
C for S long TCP/IP connections, connection, send a heartbeat every 10 seconds, connection bolt not actively

This is a stress test to see where maximum performance can achieve:

Say first server status:
S basic not how CPU and memory consumption, low consumption has been below 10%, memory slowly climb to 100 m
According to my performance statistics: S 1500 IO operations per second, 1000 ~ 2500 of

Question:
From the beginning, until completely can't response (about 9000 links don't don't of the timeout)

[23:06:01 (580)] connection Socket set up successful, thread ID: 735 c, the Socket=1276
[23:06:01 (580)] connection Socket set up successful, thread ID: 2 ec8, Socket=1256
[23:06:01 (593)] connect to the server success 192.168.0.101:39999, thread ID: 735 c, the local connection information: 192.168.0.101:32896, SOCKET=1276, time: 0.65 ms
[23:06:01 (594)] connect to the server success 192.168.0.101:39999, thread ID: 2 ec8, local connection information: 192.168.0.101:32897, SOCKET=1256, time: 0.45 ms

Until then, now 8000 connection

[23:56:41 (146)] connect to the server success 192.168.0.101:39999, thread ID: 2 d7c, local connection information: 192.168.0.101:43193, SOCKET=33380, time: 16776.38 ms
[23:56:41 (146)] from [the CHECKIN] time-consuming to 22814.94 ms
[23:56:41 (147)] from [the CHECKIN] time-consuming to 22848.86 ms

Is really to,,, IOCP is more with more slow?
Time consuming, because now large level server and client CPU is not more than 5%, is take up all of the systems is 20%

I understand, have delivery, then the delivery has been processed, then the queue will reduce, I don't know how to get to the monitoring or for system resides on IOCP queue, unable to see, can only guess,
In ProcXP, see IO processing value is as follows (8000)

S IO READS: 111
S IO WRITE 104290
S IO OTHRE 1857981

15 C IO READS:
C IO WRITE 7531489
The CIO OTHRE 1933050

My understanding is that READS is Recv, why the server only 111? And the Write is so big, and the OTHER is what the devil, more large

Don't know whether there is a great god, and to solve the problem of a kind of want to grant instruction,


Problem is basically out of in your code, memory application difficulty, file does not block processing, memory is not timely release, etc., can contribute to the efficiency problem

CodePudding user response:

Basic track, not my response is slow, IOCP response is slow, and the application of the postback handling only need less than 5 ms response time, but the completion port accumulation is overmuch, ever do IOCP concurrent processing performance testing? My machine configuration, and about the client, server to take up concurrent processing system is 5000 times per second (contain a small amount of business)

CodePudding user response:

Changing the questions, is there any API can query the IOCP queue information? In order to make the right treatment, the number of connections to say, 10 w static link easily, but if take the business process, then trouble, IOCP to tell the truth, a very egg pain points, good for bad server machine, dry turning points minutes each other,,,

CodePudding user response:

refer to the second floor worldy response:
Quote: refer to the original poster jasonabc1 response:

The test hardware:
64 10 Windows 32-bit programs (C/S)
I7 8-core
8 gb of memory

A test scenario:

C is the same as the S IOCP core, occupy the IO queue system together, of course, is two separate programs, but I want to now that are using IOCP core, should be take up system IOCP queue

Testing of business:
C for S long TCP/IP connections, connection, send a heartbeat every 10 seconds, connection bolt not actively

This is a stress test to see where maximum performance can achieve:

Say first server status:
S basic not how CPU and memory consumption, low consumption has been below 10%, memory slowly climb to 100 m
According to my performance statistics: S 1500 IO operations per second, 1000 ~ 2500 of

Question:
From the beginning, until completely can't response (about 9000 links don't don't of the timeout)

[23:06:01 (580)] connection Socket set up successful, thread ID: 735 c, the Socket=1276
[23:06:01 (580)] connection Socket set up successful, thread ID: 2 ec8, Socket=1256
[23:06:01 (593)] connect to the server success 192.168.0.101:39999, thread ID: 735 c, the local connection information: 192.168.0.101:32896, SOCKET=1276, time: 0.65 ms
[23:06:01 (594)] connect to the server success 192.168.0.101:39999, thread ID: 2 ec8, local connection information: 192.168.0.101:32897, SOCKET=1256, time: 0.45 ms

Until then, now 8000 connection

nullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnull
  • Related