A CLI tool that analyzes the memory usage of a binary via its .map file.
Project description
mapdump
Mapdump is a simple command-line tool that analyzes binaries to examine memory usage. It is built mainly for embedded C code.
installation
You can download & install mapdump
via pip
:
$ pip3 install mapdump
You can also download and use mapdump
by cloning this repo:
$ git clone https://github.com/sorjente/mapdump
$ cd mapdump/
$ python3 -m mapdump <my_binarys_map.map>
usage
Note: custom options coming soon!
Using mapdump
is very simple; you only need to provide it with the .map
file corresponding to the binary you want
to analyze. Let's say I want to analyse hello_world.map
:
$ mapdump hello_world.map
FLASH @ 0x0008000000 (524288 bytes)
****************************************
build/startup_stm32l452.o [460 bytes, 31.94% of FLASH space used]
lib_a-memcpy.o (/usr/lib/gcc/arm-none-eabi/6.3.1/../../../arm-none-eabi/lib/thumb/v7e-m/fpv4-sp/hard/libc.a) [308 bytes, 21.39% of FLASH space used]
rcc.o (./libopencm3/lib/libopencm3_stm32l4.a) [220 bytes, 15.28% of FLASH space used]
lib_a-memset.o (/usr/lib/gcc/arm-none-eabi/6.3.1/../../../arm-none-eabi/lib/thumb/v7e-m/fpv4-sp/hard/libc.a) [156 bytes, 10.83% of FLASH space used]
build/main.o [116 bytes, 8.06% of FLASH space used]
gpio_common_f0234.o (./libopencm3/lib/libopencm3_stm32l4.a) [68 bytes, 4.72% of FLASH space used]
flash_common_all.o (./libopencm3/lib/libopencm3_stm32l4.a) [36 bytes, 2.50% of FLASH space used]
flash_common_idcache.o (./libopencm3/lib/libopencm3_stm32l4.a) [32 bytes, 2.22% of FLASH space used]
rcc_common_all.o (./libopencm3/lib/libopencm3_stm32l4.a) [26 bytes, 1.81% of FLASH space used]
gpio_common_all.o (./libopencm3/lib/libopencm3_stm32l4.a) [18 bytes, 1.25% of FLASH space used]
dev notes
Tests can (and should be!) run with the following command:
$ python3 -m unittest discover -s mapdump/tests
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file mapdump-1.0.1.tar.gz
.
File metadata
- Download URL: mapdump-1.0.1.tar.gz
- Upload date:
- Size: 6.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.24.0 setuptools/50.3.2 requests-toolbelt/0.9.1 tqdm/4.51.0 CPython/3.9.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 000631dd417473860f13b3553081d7475303bfff90d429e96d0320f768b54fd1 |
|
MD5 | a2ba38718eb5040f9b4302733ac80743 |
|
BLAKE2b-256 | 24880077c93270015e959ff17158581cc97a3f12bcb92b5b5b3b7f448b34f825 |
File details
Details for the file mapdump-1.0.1-py3-none-any.whl
.
File metadata
- Download URL: mapdump-1.0.1-py3-none-any.whl
- Upload date:
- Size: 19.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.24.0 setuptools/50.3.2 requests-toolbelt/0.9.1 tqdm/4.51.0 CPython/3.9.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 54bd58cb208d9e3671e1ce027978d30f355305785383486ffe161c9091646b6e |
|
MD5 | 8c1a090ba82d3b829c14a56c8263e4b7 |
|
BLAKE2b-256 | 1e16a9e0bb36488711f53c51f856dc6ea9471c89170458fe3c5ec3523be6007c |