OnSemi RAM usage fix

Previous code base had been wasting almost 4K of precious RAM.

* Main stack allocation reduced from 4K to 1K
* Un-necessary breakdown of RAM regions is removed. This gives us back 2K of RAM.
pull/3022/head
Hasnain Virk 2016-10-14 13:51:15 +03:00
parent 08ff689afa
commit 1b6f3cdbf6
2 changed files with 3 additions and 10 deletions

View File

@ -1,7 +1,5 @@
#! armcc -E
#define Heap_Size 0x0400
LR_IROM1 0x00003000 0x0004F000 { ; load region size_region
ER_IROM1 0x00003000 0x0004F000 { ; load address = execution address
*.o (RESET, +First)
@ -11,13 +9,8 @@ LR_IROM1 0x00003000 0x0004F000 { ; load region size_region
; no uvisor support at this time
;ARM_LIB_STACK AlignExpr(+0, 8) EMPTY 0x1000 {}
ARM_LIB_STACK 0x3FFF4000 EMPTY 0x1000 {}
RW_IRAM0 +0 {
RW_IRAM1 0x3FFF4000 {
.ANY(+RW +ZI)
}
RW_IRAM1 ImageLimit(RW_IRAM0) EMPTY Heap_Size { ; Heap region growing up
}
ARM_LIB_HEAP AlignExpr(+0, 8) ALIGN 8 EMPTY (0x3FFF4000 + 0xC000 - AlignExpr(ImageLimit(RW_IRAM1),8) ) {}
}

View File

@ -43,9 +43,9 @@
EXPORT __Vectors
EXPORT __Vectors_End
EXPORT __Vectors_Size
IMPORT |Image$$ARM_LIB_STACK$$ZI$$Limit|
IMPORT |Image$$ARM_LIB_HEAP$$ZI$$Limit|
__Vectors DCD |Image$$ARM_LIB_STACK$$ZI$$Limit| ; Top of Stack
__Vectors DCD |Image$$ARM_LIB_HEAP$$ZI$$Limit| ; Top of RAM
DCD Reset_Handler ; Reset Handler
DCD NMI_Handler ; NMI Handler
DCD HardFault_Handler ; Hard Fault Handler