[Top][All Lists]

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

Re: [avr-gcc-list] 'clobber list' in ASM (was Simulation / Hex File mism

From: Colin O'Flynn
Subject: Re: [avr-gcc-list] 'clobber list' in ASM (was Simulation / Hex File mismatch)
Date: Tue, 24 Jun 2003 07:18:28 -0700 (PDT)

Hello All,

I found my problem I think. When the code is
optimized, the compiler stores a variable in some
registers... but I later clobber those registers in
the ASM file.

So I have a question: how do you have a 'clobber' list
in a ASM function (not inline ASM)? I want to tell the
compiler I'll be messing around with those registers
so don't use them...

I can store and retrieve the registers as well, but I
was wondering if I can just tell the compiler I'll be
using them....



--- Colin O'Flynn <address@hidden> wrote:
> Hello,
> I seem to have encountered a problem, possibly a
> bug.
> I have this fairly complex program (RTOS), which
> doesn't work properly in hardware (at90s8515 +
> stk500)
> using the -Os setting (works OK with the -O0
> setting).
> It does modify some stack and stuff so I'm prepared
> to
> accept that optimizations might break stuff, so i've
> got to fix it. But thats not the thing, the thing is
> that it works fine on other chips (Mega16 and
> mega169)
> in hardware with the -Os setting. OK, so its just an
> issue with that type of avr. But when I load the
> .cof
> file generated by running make extcoff or make coff
> into AVR Studio 4, it simulates just fine. AVR
> Studio's simulator is telling me the program works
> like it should.
> Luckily however my trusty ICE200, again with AVR
> Studio 4 and the .cof file, tell me the program
> doesn't work (which is the actual case). 
> I've moved project directories around and stuff so I
> know i'm getting a fresh cof file, any ideas?
>   -Colin
> _______________________________________________
> avr-gcc-list mailing list
> address@hidden
> http://www.avr1.org/mailman/listinfo/avr-gcc-list

reply via email to

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