This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Loop unrolling



  In message <199806042119.OAA03778@atrus.synopsys.com>you write:
  > > Why can't GCC go a step farther and honor the volatile attribute for
  > > any auto object?  
  > 
  > Yes, if someone writes an automatic volatile variable, they've presumably d one
  > so for a reason, so we should give them what they expect (don't optimize
  > redundant reads and writes).
Right.  Principle of least suprise.

IMHO, if I've stuck "volatile" on something, the optimizers should
treat it as potentially changing at any time, regardless of the
storage class of the object.


jeff


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]