Re: r6796 introduced possible memory leak in os/timer.c

Philipp Burch <[email protected]> Sun, 17 Jan 2021 09:37:03 +0100
Newsgroups gmane.comp.hardware.microcontrollers.ethernut
Message-ID <[email protected]>
Hi Uwe!

On 16.01.21 19:54, Uwe Bonnes wrote:
> 
> Just a short comment: I feel uneager at all that  run-time allocation/ deallocation  happens at all.
>   
> 

Indeed. Especially that timers need heap memory in all kinds of OS 
sleeps is not really nice. With the implemented NutTimerHandleStart(), 
it would probably be possible to use a single pre-allocated timer 
structure per thread. But I don't really feel comfortable with hacking 
in the innermost parts of Ethernut.

Considering the change done in r6796: Do you know why tn_flags was 
implemented as a uint32_t? Since Ethernut also targets 8-bit platforms, 
it seems somewhat inefficient to add a 32-bit value for a single bit to 
one of the core OS structures.

Regards,
Philipp
_______________________________________________
http://lists.egnite.de/mailman/listinfo/en-nut-discussion