Hi,
When using heap profiling with OSAL_MEMMTRICS=TRUE, intermittently, the values memMax and memVal appear
to be having their MSB set resulting in a larger value than what is set using INT_HEAP_LEN. However, if we discard
the MSB and consider the remaining bits, the values of memMax and memAlo remain within INT_HEAP_LEN. This is
happening with TI CC2540 BLE 1.4.0 SDK. With respect to this, I notice that there some house-keeping information
in the form of "memory in use" wherein OSALMEM_IN_USE(0x8000) is being used for toggling certain values in
OSAL_Memory.c. Based on these, here are my questions :
- Is it an expected behavior to have memMax and memAlo their MSB set under certain circumstances?
- If the answer is "yes" for (1), do we need to simply discard the MSB and consider only the applicable lower bits of memMax and memAlo(by masking depending on their maximum possible value - INT_HEAP_LEN)?
Thanks,
Raghavan