Re: Winsock Calls Overhead

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance



You haven't told us how you're doing it. We have no way of knowing if
you've done it wrong.

There's no such thing as overlapped I/O in Windows CE, so that eliminates
that. My guess would be that non-blocking sockets will increase the CPU
load, since you'll be polling the socket for data, rather than just sleeping
until the data arrives. What's the problem with what you see there? You're
not using the entire processor. You seem to be able to send/receive at the
rate you want. What's the big deal?

Sending to the local socket should take more CPU. You're both sending and
receiving on the same machine, so you have to do twice as much work per
packet: send and receive. It appears that you are only sending in the other
case.

Paul T.

"Ravish" <Ravish@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:61300BB5-14A7-4730-BD0D-EF42D8A68893@xxxxxxxxxxxxxxxx
I am using a simple application that creates a scoket and sends UDP data on
a
WinCE 6.0 BSP on 250 MHz ARM. What was observed that for different data
rates, the measured CPU load turned out to be pretty much high as
mentioned
in the table below:

Desired | CPU load | CPU load
Throughput | (Stack Loopback) | (Send to a particular IP Address)
(Kbps) | (127.0.0.1) |
---------------------------------------------------------
10 | 10 % | 7 %
100 | 11 % | 7 %
400 | 18 % | 14 %
800 | 27 % | 23 %
1000 | 31 % | 27 %

I doubted the NDIS miniport implementation for taking so much of a CPU
load
in a send call but the Stack level loopback using IP address 127.0.0.1
(when
my NDIS Miniport send functions are not called) take much more CPU load.
In
there something wrong in the way I am sending and receiving packets in my
application or the miniport NDIS. We are targetting an applciaiton that
sends
A/V streams at constant bitrate (varying from 100Kbps - 1Mbps) UDP
packets.
We are using blocking socket calls and our concern is the CPU loading. The
Winsock stress tests also showed a 100 % CPU load all the time.

Will Overlapped IO, non blocking sockets will aid in lowering the CPU
utilization?
Why should a sendto() call for 127.0.0.1 should take so much of a CPU
load.

Thanks.


.



Relevant Pages

  • Re: What do you use?
    ... >> RAID server, though. ... Swap: 4081M Total, 240K Used, 4081M Free ... The CPU usage is lower on the ICP system (remember that it has a slower CPU ... I noticed a drastic reduction of CPU load on the 3ware system when we went ...
    (freebsd-questions)
  • Re: [PATCH] limit CPU time spent in kipmid (PREVIOUS WAS BROKEN)
    ... The attached patch should work better. ... It is important to distinguish cases with and without CPU load. ... To offer this tunable to make a balance between max. CPU load of kipmid and performance appears to be worthwhile for many users. ...
    (Linux-Kernel)
  • Re: [PATCH] limit CPU time spent in kipmid (PREVIOUS WAS BROKEN)
    ... For a message that requires almost no CPU from the management controller, it takes around 5ms per message round-trip and uses about 10% of a CPU. ... With your patch, this puts the driver to sleep for a tick when this happens. ... To offer this tunable to make a balance between max. CPU load of kipmid and performance appears to be worthwhile for many users. ...
    (Linux-Kernel)
  • Re: Winsock calls overhead
    ... the measured CPU load turned out to be pretty much high as ... I doubted the NDIS miniport implementation for taking so much of a CPU ... We are using blocking socket calls and our concern is the CPU loading. ...
    (microsoft.public.windowsce.platbuilder)
  • Re: Computer hardware questions. Couldnt find newsgroup on microsoft
    ... CPU fit into sockets on the motherboard. ... A 939 socket will only hold CPU made for that socket. ... Most cases have at least 2 cooling fans, not counting the fan on the Heatsink,in the power supply ... A good example is video card ..maybe yours has a video chip on the ...
    (microsoft.public.windowsxp.hardware)