debug enabled.. wkspace under reserved Re: change log for rtems (2011-08-21)

Sebastian Huber sebastian.huber at embedded-brains.de
Tue Aug 23 07:47:09 UTC 2011


On 08/22/2011 03:28 PM, Joel Sherrill wrote:
> On 08/22/2011 02:17 AM, Sebastian Huber wrote:
>> On 08/21/2011 10:10 PM, rtems-vc at rtems.org wrote:
>>> diff -u rtems/cpukit/score/include/rtems/score/heap.h:1.45
>>> rtems/cpukit/score/include/rtems/score/heap.h:1.46
>>> --- rtems/cpukit/score/include/rtems/score/heap.h:1.45 Thu Feb 17 08:17:09 2011
>>> +++ rtems/cpukit/score/include/rtems/score/heap.h Sun Aug 21 14:51:41 2011
>>> @@ -177,7 +177,9 @@
>>> } Heap_Protection_block_end;
>>>
>>> #define HEAP_PROTECTION_HEADER_SIZE \
>>> - (sizeof(Heap_Protection_block_begin) + sizeof(Heap_Protection_block_end))
>>> + (sizeof(Heap_Protection_block_begin) + \
>>> + CPU_ALIGNMENT + \
>>> + sizeof(Heap_Protection_block_end))
>>> #endif
>>>
>>> /**
>> I doubt that this change is correct. What was the reason for this? This
>> changes also the HEAP_BLOCK_HEADER_SIZE which is used for very fundamental
>> calculations within the heap code. The CPU_ALIGNMENT value seems to be a bit
>> arbitrary here, since the heap uses the page size for alignment.
>>
>
> All I know is that turning on debug results in under estimating
> the amount of workspace required. This is the only factor
> that changes as best I can tell. So it appears to be wrong
> somehow.
>
> Any other ideas?
>

I put it on my TODO list.  We should log the allocations for a test case that 
is plagued with a too small work space and then check how that fits to the 
estimated figures.

I would revert that commit.

-- 
Sebastian Huber, embedded brains GmbH

Address : Obere Lagerstr. 30, D-82178 Puchheim, Germany
Phone   : +49 89 18 90 80 79-6
Fax     : +49 89 18 90 80 79-9
E-Mail  : sebastian.huber at embedded-brains.de
PGP     : Public key available on request.

Diese Nachricht ist keine geschäftliche Mitteilung im Sinne des EHUG.



More information about the vc mailing list