avr-gcc-list
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [avr-gcc-list] Linker options to report RAM overflow


From: Joerg Wunsch
Subject: Re: [avr-gcc-list] Linker options to report RAM overflow
Date: Tue, 15 Sep 2009 06:20:43 +0200 (MET DST)

=?us-ascii?Q?Vaclav=20Peroutka?= <address@hidden> wrote:

> Can I force linker to shout in such situation ?

In addition to the problem Eric mentioned, all AVR linker scripts
generally set the length of the data segment to 0xffa0 (starting at
0x60 by default, which can be overridden by the compiler), so even a
static RAM allocation overflow would only be detected once the
allocation exceeds that value.

This has been done since the linker has no notion about which AVR
device could possibly access external SRAM and which cannot.  Thus,
all AVRs are assumed to offer this capability.  Without that
generalization, we would need one linker script per AVR device
(actually even five of them, because the linker needs five files per
device/architecture).

Just use the avr-size command to monitor the static RAM and ROM
consumption.

-- 
cheers, J"org               .-.-.   --... ...--   -.. .  DL8DTL

http://www.sax.de/~joerg/                        NIC: JW11-RIPE
Never trust an operating system you don't have sources for. ;-)




reply via email to

[Prev in Thread] Current Thread [Next in Thread]