lwip-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [lwip-users] Help in getting maximum throughput with LWIP.


From: Simon Goldschmidt
Subject: Re: [lwip-users] Help in getting maximum throughput with LWIP.
Date: Wed, 31 Mar 2010 08:15:42 +0200

Dany Thiffeault wrote:
> oh and Simon, another question. I haven't seen anything about this in your
> wiki, but are PBUF_POOL_SIZE and PBUF_POOL_BUFSIZE important too?

Oh, then it seems like I forgot those two: PBUF_POOL_SIZE is the number of 
PBUF_POOL pbufs, each with a size of PBUF_POOL_BUFSIZE bytes.

> I'm trying to put everything as high as possible, but I have linking
> problems because I need to much memory. Could you give me some suggestions
> on the parameters to choose if I want to send packets of 8k size, or more,

Maximum packet size over ethernet will be 1514 bytes, so a PBUF_POOL_BUFSIZE of 
1516 will be enough. However, if you are low on memory, setting this smaller 
(e.g. 512 or 256) help to save memory: smaller packets waste less RAM and 
larger packets will use a chain of PBUF_POOLs (e.g. eith 512, a full-sized 
packet of 1514 bytes will use 3 pbufs) (- this is what Chris just wrote about). 
Although the chaining works quite well, there's still a small performance gain 
of having the packet in one piece, so maximum throughput will be achieved with 
1516. 

However, there are other places in the stack that have more impact on 
throughput, mainly checksum generation/checking and memcpy. These should  be 
optimized for your architecture.

Simon
-- 
GMX DSL: Internet, Telefon und Entertainment für nur 19,99 EUR/mtl.!
http://portal.gmx.net/de/go/dsl02




reply via email to

[Prev in Thread] Current Thread [Next in Thread]