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

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

Re: [avr-gcc-list] SREG save?


From: David Kelly
Subject: Re: [avr-gcc-list] SREG save?
Date: Tue, 14 Dec 2004 07:43:23 -0600


On Dec 14, 2004, at 7:09 AM, Mattias Svensson wrote:

As i recall:
INTERRUPT() runs with global interrupts enabled.
SIGNAL() runs with global interrupts disabled.

Am away from my .pdf's at the moment but I'm quite sure Mattias is correct. That the usage is opposite of Codevision.

What I'd research is how the AVR prepares itself for an IRQ and then recovers with RTI. I would expect the I bit is disabled automatically and restored on RTI. Many CPUs stack the status register and many other things automatically on IRQ but "high performance RISC" usually do not as it takes about the same amount of time to do it in code and if one is in a big hurry its not always necessary. But having said that I recall avr-gcc 3.4.1 stacks 0x3f in SIGNAL().

Have found "avr-objdump -S" to be extremely useful.

--
David Kelly N4HHE, address@hidden
========================================================================
Whom computers would destroy, they must first drive mad.



reply via email to

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