This is the mail archive of the
ecos-discuss@sources.redhat.com
mailing list for the eCos project.
Re: cyg_mempool problem?
- To: Fredrik Hederstierna <fredrik at wespot dot com>
- Subject: Re: [ECOS] cyg_mempool problem?
- From: Jonathan Larmour <jlarmour at redhat dot com>
- Date: Wed, 10 Oct 2001 14:29:28 +0100
- Cc: ecos-discuss at sources dot redhat dot com
- References: <3BC40D27.76A506EB@wespot.com>
Fredrik Hederstierna wrote:
>
> Hi,
>
> Question regardning cyg_mempool:
>
> When I'm creating a cyg_mempool using 4 megabytes everything works fine.
> But if I increase the size of the mempool eCos crashes in the kernel
> (scheduler, mutex etc) which seems like memory trashing in the kernels
> stack space (?). I've tried to increase LIBC-malloc stack size but it
> had no effect.
That's the fallback size when the target has no __heap1 symbol defined. If
it does have a __heap1 symbol it will use that.
This could indicate your memory map does not reflect your hardware. Try
running the heaptest test in services/memalloc/common.
> I've also tried to MMU-protect parts of the RAM to see if
> there's any trashing by my application, but without effect.
You could also enable assertions, which would include stack checking
(although you can enable another option to check all threads - have a look
at the kernel CDL). Make sure to run heaptest with this enabled as it helps
a lot.
> Is there any limit on size of cyg_mempool, or are there any special
> issues when using sizes approx. > 4 MB?
Nope.
Jilf
--
Red Hat, Rustat House, Clifton Road, Cambridge, UK. Tel: +44 (1223) 271062
Maybe this world is another planet's Hell -Aldous Huxley || Opinions==mine