Loop-invariant code motion

This is an old revision of this page, as edited by Spectatrix (talk | contribs) at 20:32, 11 July 2004 (wikify). The present address (URL) is a permanent link to this revision, which may differ significantly from the current revision.

Loop invariant code in an imperative programming language are statements, which could as well be placed outside of the loop: before the loop, if the loop always terminates or behind the loop, which is semantically more correct.