PPPoS TCP unix port terribly slow

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

PPPoS TCP unix port terribly slow

Mednyy Alexey
Hello list!

I'm trying to implement port forwarding over LWIP.

One side is Linux x86_64 machine another one is FreeRTOS ARM device.

I have LWIP stack on both sides of PPPoS channel, and data transfers ok.
tty read/write is fast and stable.

On IP level I see that ping example app works well, I can ping opposite
side with raw sockets API and it takes about 12ms over PPPoS on 115200
baudrate.

However when I start to use TCP level things goes terribly slow. Even
simple echo server takes several seconds receive an answer.

I use default lwipopts from
lwip-contrib/examples/example_app/lwipopts.h, just added PPP_SERVER and
PPP_NOTIFY_PHASE support.

Here is my log https://pastebin.com/raw/tfwY1rtV

And lwipopts.h https://pastebin.com/vd2DrxYJ

Can somebody tell me what is wrong with my log/config?

--
_________________________________
Best regards, Mednyy Alexey.



_______________________________________________
lwip-users mailing list
[hidden email]
https://lists.nongnu.org/mailman/listinfo/lwip-users
Reply | Threaded
Open this post in threaded view
|

Re: PPPoS TCP unix port terribly slow

Sylvain Rochet
Hi Mednyy,

On Thu, Aug 02, 2018 at 05:06:54PM +0300, Mednyy Alexey wrote:

> Hello list!
>
> I'm trying to implement port forwarding over LWIP.
>
> One side is Linux x86_64 machine another one is FreeRTOS ARM device.
>
> I have LWIP stack on both sides of PPPoS channel, and data transfers ok.
> tty read/write is fast and stable.
>
> On IP level I see that ping example app works well, I can ping opposite
> side with raw sockets API and it takes about 12ms over PPPoS on 115200
> baudrate.
>
> However when I start to use TCP level things goes terribly slow. Even
> simple echo server takes several seconds receive an answer.
>
> I use default lwipopts from
> lwip-contrib/examples/example_app/lwipopts.h, just added PPP_SERVER and
> PPP_NOTIFY_PHASE support.
>
> Here is my log https://pastebin.com/raw/tfwY1rtV
>
> And lwipopts.h https://pastebin.com/vd2DrxYJ
>
> Can somebody tell me what is wrong with my log/config?
I think I'm able to reproduce the issue. With which optimization level
are you building the unix port ? I'm very getting good throughput with
-O0, -O1 and -Os but almost no throughput with -O2. (-O3 does not even
build, which I'm going to fix sooner or later). Disabling VJ_SUPPORT
fixed the issue with -O2 for me which might indicate the issue is just
with a combination of VJ_SUPPORT and -O2.

Could you try with all possible combinations of optimization levels and
VJ_SUPPORT enabled and disabled ?

Sylvain

_______________________________________________
lwip-users mailing list
[hidden email]
https://lists.nongnu.org/mailman/listinfo/lwip-users

signature.asc (188 bytes) Download Attachment