]> begriffs open source - freertos/commit
Only add alignment padding when needed (#650)
authorGaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
Tue, 28 Mar 2023 11:31:37 +0000 (17:01 +0530)
committerGitHub <noreply@github.com>
Tue, 28 Mar 2023 11:31:37 +0000 (17:01 +0530)
commit68f105375f65ffd347e3e322d46200cb389d8886
tree5d3cd82537c807d3a019def65db3caa9687c6ae6
parent97e58da31362f180642a381f9ea55aee04546c83
Only add alignment padding when needed (#650)

Heap 4 and Heap 5 add some padding to ensure that the allocated blocks
are always aligned to portBYTE_ALIGNMENT bytes. The code until now was
adding padding always even if the resulting block was already aligned.
This commits updates the code to only add padding if the resulting block
is not aligned.

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
portable/MemMang/heap_4.c
portable/MemMang/heap_5.c