Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.Sign up
Master save mem wd #6920
couple successful flights on this PR
By bitten are you referring to another example of a silent resource failure?
There are several of this type of silent resource fail. Upstream assumes less of a dynamic runtime environment and that the DEBUGASSERT are adequate and has rejected any more debug instrumentations.
We can add a set of patches to keep track of the min free resources and display them in top.
We can also look at the soak test setup again and run a patch to change selective DEBUGASSERT to ASSERT on that test build.
In the case of this set of this settings. The code has 2 configuration parameters. One represents the total fixed allocation and the other the number of those allocations reserved for calls off of ISR.
If on an interrupt handler thread OR if the number of pre-allocated timer structures exceeds the reserve, then take the the next timer from the head of the free list. If the above is false the an allocation will occur in the non ISR case.
So if allocation = total used + total reserved for IRQ + 1 we should never allocate any timers off the heap.
We maxed out at peek of 18-20 used, we have 4 reserved for ISR so I set the value at 25.