lwip-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [lwip-users] pbuf / memory leak on ADI blackfin implementation


From: Christiaan Simons
Subject: Re: [lwip-users] pbuf / memory leak on ADI blackfin implementation
Date: Thu, 13 Jul 2006 09:22:38 +0200

Hi Larry,

> Apparently there is some sort of memory leak. As an experiment, we
> increased MEM_SIZE by a factor of 2 and the system then stalled
> after approximately 2x the original message count.

Yes, this must be a leak.

> After some exploration of the mailing list archives, we tried
> changing PBUF_LINK_HLEN from 14 to 16. No change was seem
>
> One recurring theme in the archives was to replace mem_malloc() with
> malloc(), assuming that it’s available in your environment (it is in
> ours). But if I do that, I’m worried about disguising the problem
> rather than solving it; as our system has lots of RAM – I’d just be
> pushing the failure point out further in time.

Hmm, yes that would be a "not so clean" workaround.
mem_malloc() and mem_free() should work just fine,
if not, we'll need to fix these.

> Can anyone offer any suggestions as to how we might chase this, i.e.
> places to look, things to try, etc.

Maybe you can create a small test app
calling mem_malloc() and mem_free() with various sizes,
and check if it fails in any unexpected way.

Just to rule things out before making an invasive change.
(makes it more difficult to keep in sync with new releases)

I did make such test a few weeks ago,
but I think I've lost this snippet.
(deleted it as it seemed mem_malloc()
behaved just fine )

I do know there were some obscure alignment
issues with some DSP ports before, but I can't
tell if this is true in your case.

Bye,

Christiaan Simons

Hardware Designer
Axon Digital Design

http://www.axon.tv

reply via email to

[Prev in Thread] Current Thread [Next in Thread]