4a559807a5
In the current implementation, the first transmission of the new connection handshake is depends entirely by tcp_timer(), which will caused 0.5s - 1s delay each time in connect(). This patch is mainly to improve the performance of TCP handshake. Original: nsh> tcp_client [ 1.536100] TCP connect start. [ 2.000200] TCP connect end. DIFF: tick: 4641, 464ms. [ 3.000300] TCP connect start. [ 4.000400] TCP connect end. DIFF: tick: 10001, 1000ms. [ 5.000500] TCP connect start. [ 6.000600] TCP connect end. DIFF: tick: 10001, 1000ms. [ 7.000700] TCP connect start. [ 8.000800] TCP connect end. DIFF: tick: 10001, 1000ms. Optimized: nsh> tcp_client [ 3.263600] TCP connect start. [ 3.263700] TCP connect end. DIFF: tick: 1, 0ms. [ 4.263800] TCP connect start. [ 4.263800] TCP connect end. DIFF: tick: 0, 0ms. [ 5.263900] TCP connect start. [ 5.263900] TCP connect end. DIFF: tick: 0, 0ms. [ 6.264000] TCP connect start. [ 6.264000] TCP connect end. DIFF: tick: 0, 0ms. [ 7.264100] TCP connect start. [ 7.264100] TCP connect end. DIFF: tick: 0, 0ms. Signed-off-by: chao.an <anchao@xiaomi.com> |
||
---|---|---|
.. | ||
include | ||
src | ||
Kconfig |