This is the mail archive of the
ecos-discuss@sources.redhat.com
mailing list for the eCos project.
Re: malloc initialization problem
- From: Jonathan Larmour <jifl at eCosCentric dot com>
- To: sensitron medical <sensitronnet at yahoo dot com>
- Cc: ecos <ecos-discuss at sources dot redhat dot com>
- Date: Tue, 01 Apr 2003 23:38:50 +0100
- Subject: Re: [ECOS] malloc initialization problem
- References: <20030401215502.16440.qmail@web14801.mail.yahoo.com>
sensitron medical wrote:
Forgot to mention that I am using ecos2.0. I am in the
process of testing 1.3.1.
My malloc does not fail if the size of the heap is
exceeded; I can malloc indefinitely. I traced this to
the constructor (see below), which is where I believe
the heap size is set (is this true?). Here's the
constructor for memvar.cxx instrumented with two
globals (caSize and caBase) that I can examine with an
emulator after the construtor executes:
Not necessarily. CYGNUM_MEMALLOC_FALLBACK_MALLOC_POOL_SIZE is only used
when there is no "heap1" section defined in the platform's linker script.
If heap1 is defined, that will be used and the fallback value ignored
because it is exactly that - a fallback.
So my guess is that that is where the value is coming from. If the value
is incorrect you have to fix your platform's memory layout.
Jifl
--
eCosCentric http://www.eCosCentric.com/ The eCos and RedBoot experts
--[ "You can complain because roses have thorns, or you ]--
--[ can rejoice because thorns have roses." -Lincoln ]-- Opinions==mine
--
Before posting, please read the FAQ: http://sources.redhat.com/fom/ecos
and search the list archive: http://sources.redhat.com/ml/ecos-discuss