Class WhileRewriter
- java.lang.Object
-
- org.benf.cfr.reader.bytecode.analysis.opgraph.op3rewriters.WhileRewriter
-
class WhileRewriter extends java.lang.Object
-
-
Constructor Summary
Constructors Constructor Description WhileRewriter()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description private static java.util.Set<LValue>findForInvariants(Op03SimpleStatement start, BlockIdentifier whileLoop)private static Op03SimpleStatementfindMovableAssignment(Op03SimpleStatement start, LValue lValue)private static Op03SimpleStatementgetForInvariant(Op03SimpleStatement start, LValue invariant, BlockIdentifier whileLoop)private static java.util.List<Op03SimpleStatement>getMutations(java.util.List<Op03SimpleStatement> backSources, LValue loopVariable, BlockIdentifier whileBlockIdentifier)(package private) static voidrewriteDoWhileTruePredAsWhile(java.util.List<Op03SimpleStatement> statements)private static voidrewriteDoWhileTruePredAsWhile(Op03SimpleStatement end, java.util.List<Op03SimpleStatement> statements)private static voidrewriteWhileAsFor(Op03SimpleStatement statement, boolean aggcapture)(package private) static voidrewriteWhilesAsFors(Options options, java.util.List<Op03SimpleStatement> statements)
-
-
-
Method Detail
-
rewriteDoWhileTruePredAsWhile
private static void rewriteDoWhileTruePredAsWhile(Op03SimpleStatement end, java.util.List<Op03SimpleStatement> statements)
-
rewriteDoWhileTruePredAsWhile
static void rewriteDoWhileTruePredAsWhile(java.util.List<Op03SimpleStatement> statements)
-
findForInvariants
private static java.util.Set<LValue> findForInvariants(Op03SimpleStatement start, BlockIdentifier whileLoop)
-
rewriteWhileAsFor
private static void rewriteWhileAsFor(Op03SimpleStatement statement, boolean aggcapture)
-
findMovableAssignment
private static Op03SimpleStatement findMovableAssignment(Op03SimpleStatement start, LValue lValue)
-
getForInvariant
private static Op03SimpleStatement getForInvariant(Op03SimpleStatement start, LValue invariant, BlockIdentifier whileLoop)
-
getMutations
private static java.util.List<Op03SimpleStatement> getMutations(java.util.List<Op03SimpleStatement> backSources, LValue loopVariable, BlockIdentifier whileBlockIdentifier)
-
rewriteWhilesAsFors
static void rewriteWhilesAsFors(Options options, java.util.List<Op03SimpleStatement> statements)
-
-