[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [avr-gcc-list] volatile...
From: |
Colin Paul Gloster |
Subject: |
Re: [avr-gcc-list] volatile... |
Date: |
Thu, 14 Dec 2006 13:16:35 +0100 (CET) |
On Thu, 14 Dec 2006, Javier Almansa Sobrino wrote:
"Hi everybody. I've a little stupid question...."
It seems as if you should consult a book about C or not use a language
you do not have documentation for.
"What's the differece between a volatile variable in a funcion and the
same variable not volatile?"
The volatile keyword is a hint to the compiler that it is unsafe to make
typically sane assumptions about a variable. E.g., the memory address for
that variable might be memory mapped as the input of a thermistor.
"I've noted a non volatile variable is like don't exists (I think)."
The compiler might optimize away for example a variable which is not
volatile which is never assigned a value in the C code.
- [avr-gcc-list] PPP protocol, andi suhandi, 2006/12/11
- RE: [avr-gcc-list] PPP protocol, Eric Weddington, 2006/12/11
- Re: [avr-gcc-list] volatile..., Clemens Koller, 2006/12/14
- Re: [avr-gcc-list] volatile..., MWare, 2006/12/14
- RE: [avr-gcc-list] volatile..., Larry Barello, 2006/12/14
- RE: [avr-gcc-list] volatile..., Eric Weddington, 2006/12/14
- Re: [avr-gcc-list] volatile..., Roger Furer, 2006/12/14
- Re: [avr-gcc-list] volatile..., Graham Davies, 2006/12/14
- Re: [avr-gcc-list] volatile..., David Brown, 2006/12/15
- Re: [avr-gcc-list] volatile..., Graham Davies, 2006/12/15
- Re: [avr-gcc-list] volatile..., Paulo Marques, 2006/12/15