[RTEMS Project] #4643: wkspace "failed allocations" increase with heap protection enabled
RTEMS trac
trac at rtems.org
Wed Apr 13 19:10:00 UTC 2022
#4643: wkspace "failed allocations" increase with heap protection enabled
---------------------------------+-----------------------------
Reporter: Matthew J Fletcher | Owner: Sebastian Huber
Type: defect | Status: assigned
Priority: low | Milestone:
Component: score | Version: 5
Severity: normal | Keywords:
Blocked By: | Blocking:
---------------------------------+-----------------------------
Investigating the "Total number of failed allocations:" from the wkspace
cmd i see that;
/* Statistics */
++stats->failed_allocs;
Are incremented when _Heap_Allocate_aligned_with_boundary fails, however
it seems this will routinely fail due to;
_Heap_Protection_free_all_delayed_blocks seemingly on purpose creating an
impossibly large allocation.
uintptr_t large = 0
- (uintptr_t) HEAP_BLOCK_HEADER_SIZE
- (uintptr_t) HEAP_ALLOC_BONUS
- (uintptr_t) 1;
void *p = _Heap_Allocate( heap, large );
This makes it difficult to place a breakpoint on failed_allocs to
investigate true low memory situations with heap protection enabled.
--
Ticket URL: <http://devel.rtems.org/ticket/4643>
RTEMS Project <http://www.rtems.org/>
RTEMS Project
More information about the bugs
mailing list