[PATCH] D65718: [LangRef] Document forward-progress requirement

Ralf via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sat Aug 8 01:31:58 PDT 2020


RalfJung added a comment.

> If there are no accesses to the variable, there are no calls of the function. Throwing away the loop is valid, analysis of whether it is finite is not required.

But that's exactly what the progress guarantee is about? In general, it is *not* valid for a compiler to remove an infinite loop. This could make previously dead code live, which is clearly wrong. It is only because the compiler may assume taht every program eventually makes progress, that this transformation is permitted.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D65718/new/

https://reviews.llvm.org/D65718



More information about the llvm-commits mailing list