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

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

Re: [avr-gcc-list] Using avr-gcc with AVRStudio's simulator


From: Julius Luukko
Subject: Re: [avr-gcc-list] Using avr-gcc with AVRStudio's simulator
Date: Wed, 21 Jan 2004 22:40:27 +0200
User-agent: KMail/1.4.3

On Wednesday 21 January 2004 22:32, Paul Shaffer wrote:
> This code, when compiled with avr-gcc 3.3.1 (and using the
> patched elf-to-extended coff converter), executes fine, but
> the AVRStudio simulator version 4.08 reports an  "Invalid location"
> for the variable "unit" in the watch view, stating that the location
> is at 0xFFFFFFE0 [SRAM].  Of course, the value of the variable
> can not be viewed.
>
> void main(void)
> {
>     int unit;
>     unit = 5;
> }

Hello Paul and all,

Does the question really concern this simple program? If so, I suspect that 
the compiler optimizes the variable "unit" out since it is not really used to 
anything. What happens if you define it volatile (or turn optimization off)?

-- 
D.Sc. Julius Luukko
Laboratory of Control Engineering/Department of Electrical Engineering
Lappeenranta University of Technology, FINLAND
phone:+358-5-621 6713, fax:+358-5-621 6799, www: http://www.ee.lut.fi



reply via email to

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