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

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

Re: [avr-gcc-list] Migration from AVR GCC to WinAVR or new Linux avr-gcc


From: Jamie Lawson
Subject: Re: [avr-gcc-list] Migration from AVR GCC to WinAVR or new Linux avr-gcc
Date: Tue, 16 Sep 2003 10:11:52 -0400 (EDT)

Hi,

I just came across a similar sounding problem. By comparing the listings
from both compiler versions; I have found, at least in my case, that the
newer compiler has optimized out some of the assembler routines I use
for accurate timing (Dallas 1-wire stuff).

For example: I have used several contiguous "rjmp +2" instructions just to
waste a few uS and they have been "optimized" to rjmp somewhere else.
I fixed this by using local labels in the assembler routine.

In another section; several contiguous "nop" instructions are optimized
out.

Is there a method of turning off optimization for a single section of
code?

Jamie

On Mon, 15 Sep 2003, Goran Pufler wrote:

> Thx,
> but unfortunatly this is not a case. Let me explain history of this problems.
>
> I have hardware which work just fine with old sw compiled with old avr gcc 
> for windows.
> The I decide to add some functionalities - store some structural data into a 
> eeprom. I miss function eeprom_write_block, so I decide to transfer to the 
> Linux version of avr-gcc. When I compile the code - it doesn't work - first I 
> was blaming isp sw, then I decide make some tests:
> I took old hex file and write it to the device using AVR studio and avrdude, 
> and everything work just fine.
> The I take new hex compiled on linux, and try on same hw with same ISP sw 
> (AVR Studio and avrdude), and nothing.
> Then I take old one - everything is fine.
>
> So it must (or should) be something with new version, or maybe I made some 
> mistake changing the makefile - but I only change SRC and ASM lines ?
>
> I will try to change all calls to the outp and we will see
>
> Thx,
>
> Goran


reply via email to

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