Skip to content

Commit f66fcdd

Browse files
eliwss0JF002
authored andcommitted
Improved documentation readability
Removed extra space in contribute.md and cleaned up MemoryAnalysis.md phrasing and confusing punctuation.
1 parent 1832a6c commit f66fcdd

2 files changed

Lines changed: 10 additions & 10 deletions

File tree

doc/MemoryAnalysis.md

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -32,22 +32,22 @@ In this analysis, I used [Linkermapviz](https://github.com/PromyLOPh/linkermapvi
3232

3333
### Linkermapviz
3434

35-
[Linkermapviz](https://github.com/PromyLOPh/linkermapviz) parses the MAP file and displays its content in a graphical way into an HTML page:
35+
[Linkermapviz](https://github.com/PromyLOPh/linkermapviz) parses the MAP file and displays its content on an HTML page as a graphic:
3636

3737
![linkermapviz](./memoryAnalysis/linkermapviz.png)
3838

39-
Using this tool, you can easily see the size of each symbol relative to the other one, and check what is using most of the space,...
39+
Using this tool, you can compare the relative size of symbols. This can be helpful for checking memory usage at a glance.
4040

41-
Also, as Linkermapviz is written in Python, you can easily modify it to adapt it to your firmware, export data in another format,... For example, [I modified it to parse the contents of the MAP file and export it in a CSV file](https://github.com/InfiniTimeOrg/InfiniTime/issues/313#issuecomment-842338620). I could later on open this file in LibreOffice Calc and use sort/filter functionality to search for specific symbols in specific files...
41+
Also, as Linkermapviz is written in Python, you can easily modify and adapt it to your firmware or export data in another format. For example, [here it is modified to parse the contents of the MAP file and export it in a CSV file](https://github.com/InfiniTimeOrg/InfiniTime/issues/313#issuecomment-842338620). This file could later be opened in LibreOffice Calc where sort/filter functionality could be used to search for specific symbols in specific files...
4242

4343
### Puncover
4444
[Puncover](https://github.com/HBehrens/puncover) is another useful tools that analyses the binary file generated by the compiler (the .out file that contains all debug information). It provides valuable information about the symbols (data and code): name, position, size, max stack of each functions, callers, callees...
4545
![Puncover](./memoryAnalysis/puncover.png)
4646

4747
Puncover is really easy to install:
4848

49-
- clone the repo and cd into the cloned directory
50-
- setup a venv
49+
- Clone the repo and cd into the cloned directory
50+
- Setup a venv
5151
- `python -m virtualenv venv`
5252
- `source venv/bin/activate`
5353
- Install : `pip install .`
@@ -60,13 +60,13 @@ Puncover is really easy to install:
6060
- Launch a browser at http://localhost:5000/
6161

6262
### Analysis
63-
Using the MAP file and tools, we can easily see what symbols are using most of the FLASH memory space. In this case, with no surprise, fonts and graphics are the biggest flash space consumer.
63+
Using the MAP file and tools, we can easily see what symbols are using most of the flash memory. In this case, with no surprise, fonts and graphics are the largest use of flash memory.
6464

6565
![Puncover](./memoryAnalysis/puncover-all-symbols.png)
6666

67-
This way, you can easily check what needs to be optimized : we should find a way to store big static data (like fonts and graphics) in the external flash memory, for example.
67+
This way, you can easily check what needs to be optimized. We should find a way to store big static data (like fonts and graphics) in the external flash memory, for example.
6868

69-
It's always a good idea to check the flash memory space when working on the project : this way, you can easily check that your developments are using a reasonable amount of space.
69+
It's always a good idea to check the flash memory space when working on the project. This way, you can easily check that your developments are using a reasonable amount of space.
7070

7171
### Links
7272
- Analysis with linkermapviz : https://github.com/InfiniTimeOrg/InfiniTime/issues/313#issuecomment-842338620
@@ -210,7 +210,7 @@ NRF_LOG_INFO("heap : %d", m.uordblks);
210210
```
211211

212212
#### Analysis
213-
According to my experimentation, InfiniTime uses ~6000bytes of heap most of the time. Except when the Navigation app is launched, where the heap usage increases to... more than 9500 bytes (meaning that the heap overflows and could potentially corrupt the stack!!!). This is a bug that should be fixed in #362.
213+
According to my experimentation, InfiniTime uses ~6000bytes of heap most of the time. Except when the Navigation app is launched, where the heap usage exceeds 9500 bytes (meaning that the heap overflows and could potentially corrupt the stack). This is a bug that should be fixed in #362.
214214

215215
To know exactly what's consuming heap memory, you can `wrap` functions like `malloc()` into your own functions. In this wrapper, you can add logging code or put breakpoints:
216216

doc/contribute.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ Other contributors can post comments about the pull request, maybe ask for more
4646

4747
Once the pull request is reviewed and accepted, it'll be merged into **develop** and will be released in the next version of the firmware.
4848

49-
## Why all these rules?
49+
## Why all these rules?
5050

5151
Reviewing pull requests is a **very time consuming task**. Everything you do to make reviewing easier will **get your PR merged faster**.
5252

0 commit comments

Comments
 (0)