PropGCC: Fundamental misunderstanding of program size?
SRLM
Posts: 5,045
I think I've been misleading myself, so I ask this clarifying question:
What is the actual program size?
I've been happily developing away, and keeping a careful eye on the memory usage. 24232 bytes sent as indicated by propeller-load.
But, if I increase one of my arrays by 1 then I get hub memory overflow!
If I use propeller-elf-size on the original elf I get
Which would seem to indicate that I'm right at the border (32KB - 32760 = 8 bytes) of a program that fits. My guess is that propeller-load only loads the text and data sections, and doesn't count the bss section.
Hmmm. I think I'll have to make another pass through my code and optimize for size again.
What is the actual program size?
I've been happily developing away, and keeping a careful eye on the memory usage. 24232 bytes sent as indicated by propeller-load.
But, if I increase one of my arrays by 1 then I get hub memory overflow!
If I use propeller-elf-size on the original elf I get
$ propeller-elf-size main.gamma.elf text data bss dec hex filename 20148 4084 8528 32760 7ff8 main.gamma.elf[/code]
Which would seem to indicate that I'm right at the border (32KB - 32760 = 8 bytes) of a program that fits. My guess is that propeller-load only loads the text and data sections, and doesn't count the bss section.
Hmmm. I think I'll have to make another pass through my code and optimize for size again.
Comments
Also note that you'll need a little bit of space for stack (depending on your application you may want anywhere from 64 bytes to 2K of stack).