Hi Ian,

> Thanks guys I knew that I could count on you all for help. volatile,
> that's new to me I'll look it up.  Kernighan and Ritchie say what you
> all say but ANSI C says it's implementation dependent, as long as it
> works.

FYI: ANSI C is also out of date.  These days it is the ISO C99 standard 
that you need to check.  In there you will find:

  6.7.3 Type qualifiers
  [...]
  6 An object that has volatile-qualified type may be modified in ways
    unknown to the implementation or have other unknown side effects.
    Therefore any expression referring to such an object shall be
    evaluated strictly according to the rules of the abstract machine,
    as described in 5.1.2.3. Furthermore, at every sequence point the
    value last stored in the object shall agree with that prescribed by
    the abstract machine, except as modified by the unknown factors
    mentioned previously. (114)  What constitutes an access to an object
    that has volatile-qualified type is implementation-defined.
  [...]
  114) A volatile declaration may be used to describe an object
    corresponding to a memory-mapped input/output port or an object
    accessed by an asynchronously interrupting function. Actions on
    objects so declared shall not be ‘‘optimized out’’ by an
    implementation or reordered except as permitted by the rules for
    evaluating expressions.

Cheers
   Nick


------------------------------------------------------------------------------
Presto, an open source distributed SQL query engine for big data, initially
developed by Facebook, enables you to easily query your data on Hadoop in a 
more interactive manner. Teradata is also now providing full enterprise
support for Presto. Download a free open source copy now.
http://pubads.g.doubleclick.net/gampad/clk?id=250295911&iu=/4140
_______________________________________________
Mspgcc-users mailing list
Mspgcc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mspgcc-users

Reply via email to