From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 27692 invoked by alias); 10 Mar 2011 19:56:52 -0000 Received: (qmail 27684 invoked by uid 22791); 10 Mar 2011 19:56:51 -0000 X-SWARE-Spam-Status: No, hits=-1.7 required=5.0 tests=AWL,BAYES_00,T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from hermes.mlbassoc.com (HELO mail.chez-thomas.org) (64.234.241.98) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Thu, 10 Mar 2011 19:56:47 +0000 Received: by mail.chez-thomas.org (Postfix, from userid 999) id C4AD51660594; Thu, 10 Mar 2011 12:56:44 -0700 (MST) Received: from [127.0.0.1] (localhost.localdomain [127.0.0.1]) by mail.chez-thomas.org (Postfix) with ESMTP id 5830016603B6; Thu, 10 Mar 2011 12:56:07 -0700 (MST) Message-ID: <4D792CD7.3040209@mlbassoc.com> Date: Thu, 10 Mar 2011 19:56:00 -0000 From: Gary Thomas User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.2.13) Gecko/20101209 Fedora/3.1.7-0.35.b3pre.fc13 Thunderbird/3.1.7 MIME-Version: 1.0 To: Michael Bergandi CC: eCos Developer List Subject: Re: Set stack size for main References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-IsSubscribed: yes Mailing-List: contact ecos-devel-help@ecos.sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Post: List-Help: , Sender: ecos-devel-owner@ecos.sourceware.org X-SW-Source: 2011-03/txt/msg00002.txt.bz2 On 03/10/2011 12:47 PM, Michael Bergandi wrote: > Hi all, > > I have a test app that seems to crash in random locations. After > probing with gdb for a bit, it appears that an interupt occurs at some > point and then the app crashes with: > > ASSERT FAIL:<3240>sched.cxx[160]static void > Cyg_Scheduler::unlock_inner() Bad current thread > > I am thinking that this is probably a corrupt stack problem, but I am > not sure how to know for sure. Assuming it is a stack problem and it > is just too small, can someone explain how I can set/check the stack > size of main()? Set this variable: cdl_option CYGNUM_LIBC_MAIN_DEFAULT_STACK_SIZE { user_value 65536 }; -- ------------------------------------------------------------ Gary Thomas | Consulting for the MLB Associates | Embedded world ------------------------------------------------------------