[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
RE: [avr-gcc-list] strange behaviour of avr-ld, maybe a bug?
From: |
Boyapati, Anitha |
Subject: |
RE: [avr-gcc-list] strange behaviour of avr-ld, maybe a bug? |
Date: |
Mon, 14 Feb 2011 18:49:47 +0800 |
Hello Max,
>
>In the linker script be sure the MEMORY command is:
>MEMORY
>{
> text (rx) : ORIGIN = 0, LENGTH = 32K
> data (rw!x) : ORIGIN = 0x800060, LENGTH = 2K
> eeprom (rw!x) : ORIGIN = 0x810000, LENGTH = 1K
>}
>
>text region is as long as 32KB, as atmega32's flash.
>
>If you compile you will obtain a binary bigger than 32KB
>I would expect a linker error like:
>region `text' overflowed by xx bytes
>
I don't think so. If .text section alone is more than 32KB, linker will
complain. I don't think that is the case here.
>if you run avr-size, you get:
>
>AVR Memory Usage
>----------------
>Device: atmega32
>
>Program: 33408 bytes (102.0% Full)
>(.text + .data + .bootloader)
>
>Data: 1500 bytes (73.2% Full)
>(.data + .bss + .noinit)
>
>
>
>flash is 102.0% Full... but linker doesn't warn
It is the program section which is 102.0% full not .text section. AFAIK linker
script is not handling the size of PROGRAM segment.
HTH
Anitha
- [avr-gcc-list] strange behaviour of avr-ld, maybe a bug?, Massimiliano Cialdi, 2011/02/14
- RE: [avr-gcc-list] strange behaviour of avr-ld, maybe a bug?,
Boyapati, Anitha <=
- RE: [avr-gcc-list] strange behaviour of avr-ld, maybe a bug?, Massimiliano Cialdi, 2011/02/14
- Re: [avr-gcc-list] strange behaviour of avr-ld, maybe a bug?, Erik Christiansen, 2011/02/14
- RE: [avr-gcc-list] strange behaviour of avr-ld, maybe a bug?, Boyapati, Anitha, 2011/02/17
- A work-around Re: [avr-gcc-list] strange behaviour of avr-ld, maybe a bug?, Erik Christiansen, 2011/02/17
- RE: A work-around Re: [avr-gcc-list] strange behaviour of avr-ld, maybe a bug?, Boyapati, Anitha, 2011/02/20
- Re: A work-around Re: [avr-gcc-list] strange behaviour of avr-ld,maybe a bug?, Erik Christiansen, 2011/02/21