On 22 Jun 2005,
(E-Mail Removed) wrote:
> In comp.protocols.tcp-ip jbl <(E-Mail Removed)> wrote:
>> I realize that the most reasonable way to answer this question may
>> in fact be "build it and do the measurements".
>
> Indeed. You may find the service demand calculations of netperf
> helpful. www.netperf.org.
I have implemented networking on several embedded processors. I think
the sad truth is that there is too much variation. Most expressed
this sentiment.
For instance, on vxWorks, the NE2000 driver versus an MPC860 and zbufs
will provide totally different results. The MPC860 allows DMA of
chained buffers. Most TCP/IP stack use mbuf or chained buffers to
separate memory for separate protocol layers. With an NE2000 driver,
you must iterate through the buffers and hit a register with each,
doing a memory fetch. On the MPC860, this is all done in hardware.
You could have a PPC with an NE2000 card and the MPC860 at a
significantly slower clock could still handle more traffic.
Another case, I used lwip on an 8051 (25Mhz). The pathetic 8bit data
transfers make a maximum Ethernet transmission (large ping packets) of
about 5 kBps. By coding in assembler, I was able to raise this to 50
kBbps. However, the lwip stack has optimized the icmp response to
just turn the buffer around. So this was simply to transmit and
receive data! The management at this company were a bunch of idiots
(perhaps stupider than most), so I had to do this exercise to make
them realize this was impossible [hint: Ethernet is 10Mbps]. Merging
checksums with copies can some time and on dumb CISC archs asm can pay
off huge. In the 8051, you have something like x86 real mode segment
registers.
Small packet versus large packet protocols will affect figures. The
stack itself will have trade offs. Code size, memory foot print,
flexibility, RFC conformance, etc.
I have heard one megahertz per mega bit as a rule of thumb. Ie, you
need a GHz PC to handle Gbps ethernet. This is more an IT rule that
something that should be applied to a control system.
fwiw,
Bill Pringlemeir.
--
Having sex is like playing bridge. If you don't have a good
partner,you'd better have a good hand. - Unknown
vxWorks FAQ, "http://www.xs4all.nl/~borkhuis/vxworks/vxworks.html"