Skip to content

Commit 3b80fca

Browse files
author
deepikabhavnani
committed
Add Dynamic heap support to IAR
Two new block properties available in linker configuration files: "expanding size" and "minimum size" for IAR 8.11.2 and above Sample: define block HEAP with expanding size, minimum size = 16K, alignment = 8 {}; This block will expand to consume all remaining available space in the range where it is placed. If several such blocks end up in the same range, they will share the remaining space. Cannot place a block with expanding size inside another block with expanding size, inside a block with maximum size, or inside an overlay.
1 parent 1566395 commit 3b80fca

File tree

112 files changed

+113
-115
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

112 files changed

+113
-115
lines changed

targets/TARGET_ARM_SSG/TARGET_BEETLE/device/TOOLCHAIN_IAR/BEETLE.icf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ initialize by copy { readwrite };
4242
do not initialize { section .noinit };
4343

4444
define block CSTACK with alignment = 8, size = __ICFEDIT_size_cstack__ { };
45-
define block HEAP with alignment = 8, size = __ICFEDIT_size_heap__ { };
45+
define block HEAP with expanding size, minimum size = __ICFEDIT_size_heap__, alignment = 8 { };
4646

4747
place at address mem:__ICFEDIT_intvec_start__ { readonly section .intvec };
4848
place in ROM_region { readonly };

targets/TARGET_ARM_SSG/TARGET_CM3DS_MPS2/device/TOOLCHAIN_IAR/MPS2.icf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ initialize by copy { readwrite };
4848
do not initialize { section .noinit };
4949

5050
define block CSTACK with alignment = 8, size = __ICFEDIT_size_cstack__ { };
51-
define block HEAP with alignment = 8, size = __ICFEDIT_size_heap__ { };
51+
define block HEAP with expanding size, minimum size = __ICFEDIT_size_heap__, alignment = 8 { };
5252

5353
place at address mem:__ICFEDIT_intvec_start__ { readonly section .intvec };
5454
place in ROM_region { readonly };

targets/TARGET_Freescale/TARGET_K20XX/TARGET_K20D50M/device/TOOLCHAIN_IAR/MK20D5.icf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ define region RAM_region = mem:[from __ICFEDIT_region_RAM_start__ to __ICFEDIT_r
3434
define region FlexRAM_region = mem:[from __region_FlexRAM_start__ to __region_FlexRAM_end__];
3535

3636
define block CSTACK with alignment = 8, size = __ICFEDIT_size_cstack__ { };
37-
define block HEAP with alignment = 8, size = __ICFEDIT_size_heap__ { };
37+
define block HEAP with expanding size, minimum size = __ICFEDIT_size_heap__, alignment = 8 { };
3838

3939
define region FlashConfig_region = mem:[from __FlashConfig_start__ to __FlashConfig_end__];
4040

targets/TARGET_Freescale/TARGET_KLXX/TARGET_KL05Z/device/TOOLCHAIN_IAR/MKL05Z4.icf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ define region ROM_region = mem:[from __ICFEDIT_region_ROM_start__ to (__FlashCon
2727
define region RAM_region = mem:[from __ICFEDIT_region_RAM_start__ to __ICFEDIT_region_RAM_end__] | mem:[from __region_RAM2_start__ to __region_RAM2_end__];
2828

2929
define block CSTACK with alignment = 8, size = __ICFEDIT_size_cstack__ { };
30-
define block HEAP with alignment = 8, size = __ICFEDIT_size_heap__ { };
30+
define block HEAP with expanding size, minimum size = __ICFEDIT_size_heap__, alignment = 8 { };
3131

3232
define region FlashConfig_region = mem:[from __FlashConfig_start__ to __FlashConfig_end__];
3333

targets/TARGET_Freescale/TARGET_KLXX/TARGET_KL25Z/device/TOOLCHAIN_IAR/MKL25Z4.icf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ define region ROM_region = mem:[from __ICFEDIT_region_ROM_start__ to (__FlashCon
2727
define region RAM_region = mem:[from __ICFEDIT_region_RAM_start__ to __ICFEDIT_region_RAM_end__] | mem:[from __region_RAM2_start__ to __region_RAM2_end__];
2828

2929
define block CSTACK with alignment = 8, size = __ICFEDIT_size_cstack__ { };
30-
define block HEAP with alignment = 8, size = __ICFEDIT_size_heap__ { };
30+
define block HEAP with expanding size, minimum size = __ICFEDIT_size_heap__, alignment = 8 { };
3131

3232
define region FlashConfig_region = mem:[from __FlashConfig_start__ to __FlashConfig_end__];
3333

targets/TARGET_Freescale/TARGET_KLXX/TARGET_KL26Z/device/TOOLCHAIN_IAR/MKL26Z4.icf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ define region ROM_region = mem:[from __ICFEDIT_region_ROM_start__ to (__FlashCon
2727
define region RAM_region = mem:[from __ICFEDIT_region_RAM_start__ to __ICFEDIT_region_RAM_end__] | mem:[from __region_RAM2_start__ to __region_RAM2_end__];
2828

2929
define block CSTACK with alignment = 8, size = __ICFEDIT_size_cstack__ { };
30-
define block HEAP with alignment = 8, size = __ICFEDIT_size_heap__ { };
30+
define block HEAP with expanding size, minimum size = __ICFEDIT_size_heap__, alignment = 8 { };
3131

3232
define region FlashConfig_region = mem:[from __FlashConfig_start__ to __FlashConfig_end__];
3333

targets/TARGET_Freescale/TARGET_KLXX/TARGET_KL46Z/device/TOOLCHAIN_IAR/MKL46Z4.icf

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,7 @@ define region ROM_region = mem:[from __ICFEDIT_region_ROM_start__ to (__FlashCon
2727
define region RAM_region = mem:[from __ICFEDIT_region_RAM_start__ to __ICFEDIT_region_RAM_end__] | mem:[from __region_RAM2_start__ to __region_RAM2_end__];
2828

2929
define block CSTACK with alignment = 8, size = __ICFEDIT_size_cstack__ { };
30-
define block HEAP with alignment = 8, size = __ICFEDIT_size_heap__ { };
31-
30+
define block HEAP with expanding size, minimum size = __ICFEDIT_size_heap__, alignment = 8 { };
3231
define region FlashConfig_region = mem:[from __FlashConfig_start__ to __FlashConfig_end__];
3332

3433
initialize by copy { readwrite };

targets/TARGET_Freescale/TARGET_MCUXpresso_MCUS/TARGET_K66F/device/TOOLCHAIN_IAR/MK66FN2M0xxx18.icf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ define region CSTACK_region = mem:[from m_data_2_end-__size_cstack__+1 to m_data
105105
define region m_interrupts_ram_region = mem:[from m_interrupts_ram_start to m_interrupts_ram_end];
106106

107107
define block CSTACK with alignment = 8, size = __size_cstack__ { };
108-
define block HEAP with alignment = 8, size = __size_heap__ { };
108+
define block HEAP with expanding size, minimum size = __size_heap__, alignment = 8 { };
109109
define block RW { readwrite };
110110
define block ZI { zi };
111111

targets/TARGET_Freescale/TARGET_MCUXpresso_MCUS/TARGET_K82F/device/TOOLCHAIN_IAR/MK82FN256xxx15.icf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ define region CSTACK_region = mem:[from m_data_2_end-__size_cstack__+1 to m_data
105105
define region m_interrupts_ram_region = mem:[from m_interrupts_ram_start to m_interrupts_ram_end];
106106

107107
define block CSTACK with alignment = 8, size = __size_cstack__ { };
108-
define block HEAP with alignment = 8, size = __size_heap__ { };
108+
define block HEAP with expanding size, minimum size = __size_heap__, alignment = 8 { };
109109
define block RW { readwrite };
110110
define block ZI { zi };
111111

targets/TARGET_Freescale/TARGET_MCUXpresso_MCUS/TARGET_KL27Z/device/TOOLCHAIN_IAR/MKL27Z64xxx4.icf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ define region CSTACK_region = mem:[from m_data_end-__size_cstack__+1 to m_data_e
9797
define region m_interrupts_ram_region = mem:[from m_interrupts_ram_start to m_interrupts_ram_end];
9898

9999
define block CSTACK with alignment = 8, size = __size_cstack__ { };
100-
define block HEAP with alignment = 8, size = __size_heap__ { };
100+
define block HEAP with expanding size, minimum size = __size_heap__, alignment = 8 { };
101101
define block RW { readwrite };
102102
define block ZI { zi };
103103

0 commit comments

Comments
 (0)