From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 2793 invoked by alias); 27 Aug 2009 14:11:37 -0000 Received: (qmail 2596 invoked by uid 22791); 27 Aug 2009 14:11:36 -0000 X-SWARE-Spam-Status: No, hits=-2.3 required=5.0 tests=AWL,BAYES_00 X-Spam-Check-By: sourceware.org Received: from mail01.solnet.ch (HELO mail01.solnet.ch) (212.101.4.135) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Thu, 27 Aug 2009 14:11:31 +0000 Received: from mail01.solnet.ch ([127.0.0.1]) by localhost (mail01.solnet.ch [127.0.0.1]) (SolNet-Check, port 10024) with LMTP id nR-fRmADfNY4; Thu, 27 Aug 2009 14:11:28 +0000 (UTC) Received: from beta.intefo.ch (static-212-101-18-64.adsl.solnet.ch [212.101.18.64]) by mail01.solnet.ch (Postfix) with ESMTP id B5C494C4ED; Thu, 27 Aug 2009 14:11:28 +0000 (UTC) Received: from beta.intefo.ch ([127.0.0.1]) by localhost (beta.intefo.ch [127.0.0.1]) (amavisd-new, port 10024) with LMTP id PhmR3E4Lmt9w; Thu, 27 Aug 2009 16:11:28 +0200 (CEST) Received: from [192.168.1.20] (simon.intefo.ch [192.168.1.20]) by beta.intefo.ch (Postfix) with ESMTP id 3D6557700F7; Thu, 27 Aug 2009 16:11:28 +0200 (CEST) Message-ID: <4A969535.3060400@intefo.ch> Date: Thu, 27 Aug 2009 14:11:00 -0000 From: Simon Kallweit User-Agent: Thunderbird 2.0.0.23 (X11/20090817) MIME-Version: 1.0 To: agfa prayoga s CC: Sergei Gavrikov , Mandeep Sandhu , ecos-discuss References: <144735.17263.qm@web65404.mail.ac4.yahoo.com> In-Reply-To: <144735.17263.qm@web65404.mail.ac4.yahoo.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-IsSubscribed: yes Mailing-List: contact ecos-discuss-help@ecos.sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: ecos-discuss-owner@ecos.sourceware.org Subject: Re: [ECOS] ecos + lwip X-SW-Source: 2009-08/txt/msg00095.txt.bz2 agfa prayoga s wrote: > Hi all,,, > > did lwIP 1.3.0 port that Simon's patched for eCos 3.0 has improvement in > memory footprint? > > i am trying to run httpd example under lwip package on AT91SAM7X-EK board > filled with AT91SAM7X256. that microcontroller only have 256KB ROM and > 64KB RAM. > > i have compiled the example successfully only with PBUF value 10, disable DHCP, > SLIP, PPP, raw socket support, IP forwarding. > > using arm-eabi-size, httpd binary has size: > .text : 82740 > .data: 5428 > .bss: 50792 > > notice that the sum of .data and .bss is almost 56KB, near 64KB. > > if i increase the PBUF value over 10(default value is 60), compilation process will failed with error that > is no longer room in .bss because the limitation in 64KB. > > maybe this is out of topic, but i appreciate your assistance... Well that's hard to say. You would need to ask that question on the lwip list. I don't know if there are major differences in memory consumption between lwip 1.1.0 and 1.3.1. One advantage of my port is that it can be run in a completely polled mode (I call it simple mode), so you can run all your network code in a single thread, instead of multiple threads (at least 3). The old port did not directly offer that option. This can spare you quite a bit of memory (stacks). Notice that when using the simple mode, you will have to use the raw APIs (see httpd_simple example) and cannot use the netconn and socket APIs. In my project, I use the polled mode for the exact same reason (memory) with good results. Simon -- Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss