This is the mail archive of the gcc-patches@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]
Other format: [Raw text]

Re: [doc] empty loops


Nathan Sidwell <nathan@codesourcery.com> wrote:

>>> It's certainly ok to document that we intend to remove such loops,
>>> even if we don't actually do it now.
>>
>> I confused myself with the example.  I meant it to point out that
>> even non-empty C loops can be optimized to empty ones.  How about
>> this adjusted wording that leaves it open to when such loops
>> actually get deleted.

Can we document this into gcc-4.0/changes.html as a heads-up for future
versions? I am sure there is bazillion of code out there which relies on this
to do small delay (I know I saw this many times in embedded code I had to put
my hands on), so it might be good to warn our users. BTW, an entry in
changes.html should also contain at least an obvious workaround (make the
counter volatile, or add an empty asm statement in the loop, or whatever).

Giovanni Bajo


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