lwip-users
[Top][All Lists]
Advanced

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

Re: [lwip-users] TCP_SND_QUEUELEN vs TCP_SNDQUEUELEN_OVERFLOW


From: Art R.
Subject: Re: [lwip-users] TCP_SND_QUEUELEN vs TCP_SNDQUEUELEN_OVERFLOW
Date: Mon, 31 Mar 2008 13:03:42 -0700 (PDT)



address@hidden wrote:
> 
> Jonathan Larmour wrote:
>> Art R. wrote:
>>   
>>> Just trying to make lwIP as good as it can be.
>>>
>>> Don't know if you would consider this, but ...
>>>
>>> tcp.c (current 1.3.0)
>>> line 315:   pcb->mss = (TCP_MSS > 536) ? 536 : TCP_MSS;
>>> line 995:   pcb->mss = (TCP_MSS > 536) ? 536 : TCP_MSS;
>>>     
> The thing I considered here was a check (in init.c?) that TCP_MSS != 0.
>>> Both TCP_MSS and 536 are constants. The compare could be done at compile
>>> time in a #if rather than in compiled code at runtime.
>>>     
>>
>> Every compiler would optimise away that expression.
>>   
> Indeed!
> 
> Simon
> 
> 
> _______________________________________________
> lwip-users mailing list
> address@hidden
> http://lists.nongnu.org/mailman/listinfo/lwip-users
> 
> 


I suggest it for the reader, not the compiler.


-- 
View this message in context: 
http://www.nabble.com/TCP_SND_QUEUELEN-vs-TCP_SNDQUEUELEN_OVERFLOW-tp16291544p16399056.html
Sent from the lwip-users mailing list archive at Nabble.com.





reply via email to

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