This is the mail archive of the ecos-patches@sourceware.org mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug 1001344] Allow nc_test_slave for lwIP to compile for targets with 128KiB RAM.


Please do not reply to this email. Use the web interface provided at:
http://bugs.ecos.sourceware.org/show_bug.cgi?id=1001344

--- Comment #5 from Sergei Gavrikov <sergei.gavrikov@gmail.com> 2011-09-27 10:05:53 BST ---
(In reply to comment #4)
> (In reply to comment #3)
> > (In reply to comment #2)
> > > (In reply to comment #1)
> > > > (In reply to comment #0)
> > > > > Created an attachment (id=1377)
 --> (http://bugs.ecos.sourceware.org/attachment.cgi?id=1377) [details]
[details] Reduce stack usage
> of
> > > > > nc_test_slave
> > > 
> > > > 
> > > > Hi Ilija,
> > > > 
> > > > I have one **minor** remark regarding attachment 1377 [details] [details].
> I
> > > > would use ECHO_STACK_SIZE in the patch instead proposed name
> > > > (TMAIN_STACK_SIZE), IMO, such "adjusted" names would look nicer
> > > 
> > > Thanks for comment Sergei.
> > > 
> > > I selected stack names to reflect thread names. Regarding your
> > > proposal I assume that you mean MAIN_STACK_SIZE => ECHO_STACK_SIZE
> > > rather than TMAIN..., aren't you?
> > 
> > Hmm. I see
> > 
> > @@ -748,7 +750,7 @@
> >                        0,                        // entry parameter
> >                        "socket echo test",       // Name
> >                        &stack[0],                // Stack
> > -                      STACK_SIZE,               // Size
> > +                      TMAIN_STACK_SIZE,         // Size
> >                        &thread_handle,           // Handle
> >                        &thread_data              // Thread data structure
> >              );
> > 
> > So, I've meant s/TMAIN/ECHO/.
> 
> OK. I see, diff doesn't show complete entry. The thread entry function is named
> tmain. Here it is:
> 
>     // Create a main thread, so we can run the scheduler and have time 'pass'
>     cyg_thread_create(10,                       // Priority
>                       tmain,                    // entry
>                       0,                        // entry parameter
>                       "socket echo test",       // Name
>                       &stack[0],                // Stack
>                       TMAIN_STACK_SIZE,         // Size
>                       &thread_handle,           // Handle
>                       &thread_data              // Thread data structure
>             );
>     cyg_thread_resume(thread_handle);           // Start it
> 
> And tmain() doesn't do any echoing, it merely inits lwIP and starts thread
> "main" - entry point net_test(). "main" performs echoing and that's why I
> thought you were refering to MAIN_STACK_SIZE.
> Anyway, now I see that I was not fully consistent. Maybe I should put
> TEST_STACK_SIZE instead of MAIN_STACK_SIZE. Then we shall have:
> 
>   TEST_STACK_SIZE
>   LOAD_STACK_SIZE
>   IDLE_STACK_SIZE
>   TMAIN_STACK_SIZE
> 
> What do you mean?

Stupid me. Of course diff -u5 would avoid my "renaming" as I did not look on
the test's source (it's bad thing from my side). I take aside my request.

I'm sorry that I waste your time. Now all clear fo me.

Sergei

-- 
Configure bugmail: http://bugs.ecos.sourceware.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]