[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [avr-gcc-list] Re: [avr-libc-dev] [bug #29774] prologue/epilogue sta
From: |
Ruud Vlaming |
Subject: |
Re: [avr-gcc-list] Re: [avr-libc-dev] [bug #29774] prologue/epilogue stack pointer manipulation not interrupt safe in XMega |
Date: |
Sat, 12 Feb 2011 16:44:06 +0000 |
User-agent: |
KMail/1.9.10 |
On Tuesday 08 June 2010, Matthew wrote:
> So here's what I have found so far. When executing SEI, one more
> instruction can execute before the first interrupt is serviced. When
> enabling interrupts by restoring the status register, interrupts can
> occur immediately. When writing to SPL, interrupts are automatically
> disabled until the next memory write (up to 4 cycles).
Interesting info!
Can you provide the sources for that or did you test it yourself?
And do these statements hold for xmega en mega alike?
> Therefore, the prologue and epilogue do not need to disable interrupts
> at all. A write to SPL followed by a write to SPH should be interrupt
> safe. I have not tested this yet.
This seems hard to test, but is also very interesting.
Ruud
- Re: [avr-gcc-list] Re: [avr-libc-dev] [bug #29774] prologue/epilogue stack pointer manipulation not interrupt safe in XMega,
Ruud Vlaming <=