apache / apache/mynewt-core

heap usage report

Open
#2,078 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
C
Stars
891
Forks
381
Avg merge
2d 7h
Merged PRs (30d)
14

Description

We should have a console command/newtmgr operation to query heap use. I'd want minimally to see a) how much space was in the heap initially and b) how much was the max allocated amount.

Code should live next to _sbrk() implementation for the MCU, and the API could be optional to implement (presence of the implementation would be advertised with syscfg).

Optionally add a interface to baselibc which reports amount of memory in freelist. Not all use targets use baselibc (native targets, specifically), so including that data within the heap report could depend on whether baselibc is used or not.

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by locating the MCU _sbrk() implementation and the existing console/newtmgr operation patterns. Check how optional APIs are advertised with syscfg and whether baselibc exposes freelist information. Done means a heap report can provide initial heap space and maximum allocated amount, with baselibc data included only where applicable.

Written by the indexing model from the issue text.

Assessment

Tech stack
c
Domain
cli, embedded-iot, operating-systems
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.