[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
RE: [avr-gcc-list] Problem with delay loop
From: |
Eric Weddington |
Subject: |
RE: [avr-gcc-list] Problem with delay loop |
Date: |
Tue, 02 Oct 2007 06:57:35 -0600 |
> -----Original Message-----
> From: John Regehr [mailto:address@hidden
> Sent: Monday, October 01, 2007 10:59 PM
> To: Eric Weddington
> Cc: 'Paulo Marques'; 'David Brown'; 'AVR-GCC'
> Subject: RE: [avr-gcc-list] Problem with delay loop
>
> > However, David brings up a good point. A local variable is
> put on the stack,
> > generally not the place for hardware to modify the
> variable. And generally,
> > other parts of the program (such as ISRs) don't have access
> to the specific
> > location of the variable on the stack. Both hardware and
> ISRs work with
> > global variables. So *could* a compiler reason that local
> variables could
> > never be volatile? Or are there truly situations where
> hardware or ISRs
> > could modify local variables on the stack?
>
> The common use of volatile automatic variables is in conjunction with
> setjmp/longjmp. This idiom would break if volatile locals went into
> registers.
Ah, ok then. In practice, I have never needed to use setjmp/longjmp, so I
have a tendency to forget about these routines.
Thanks,
Eric
- Re: [avr-gcc-list] Problem with delay loop, (continued)
- Re: [avr-gcc-list] Problem with delay loop, Paulo Marques, 2007/10/01
- RE: [avr-gcc-list] Problem with delay loop, Eric Weddington, 2007/10/01
- Re: [avr-gcc-list] Problem with delay loop, Preston Wilson, 2007/10/01
- RE: [avr-gcc-list] Problem with delay loop, Eric Weddington, 2007/10/01
- Re: [avr-gcc-list] Problem with delay loop, Graham Davies, 2007/10/01
- Re: [avr-gcc-list] Problem with delay loop, David Brown, 2007/10/02
- RE: [avr-gcc-list] Problem with delay loop, Eric Weddington, 2007/10/02
- RE: [avr-gcc-list] Problem with delay loop, Eric Weddington, 2007/10/02
- Re: [avr-gcc-list] Problem with delay loop, Bob Paddock, 2007/10/01
- RE: [avr-gcc-list] Problem with delay loop, John Regehr, 2007/10/02
- RE: [avr-gcc-list] Problem with delay loop,
Eric Weddington <=
- RE: [avr-gcc-list] Problem with delay loop, John Regehr, 2007/10/02
- Re: [avr-gcc-list] Problem with delay loop, David Brown, 2007/10/01
- Re: [avr-gcc-list] Problem with delay loop, Paulo Marques, 2007/10/01
- Re: [avr-gcc-list] Problem with delay loop, David Brown, 2007/10/02
Re: [avr-gcc-list] Problem with delay loop, Royce Pereira, 2007/10/02