public class ProgramRecompiler extends Object
Constructor and Description |
---|
ProgramRecompiler() |
Modifier and Type | Method and Description |
---|---|
static boolean |
containsAtLeastOneFunction(ProgramBlock pb) |
static ArrayList<ProgramBlock> |
generatePartitialRuntimeProgram(Program rtprog,
ArrayList<StatementBlock> sbs) |
static LocalVariableMap |
getReusableScalarVariables(DMLProgram prog,
StatementBlock parforSB,
LocalVariableMap vars) |
static boolean |
isApplicableForReuseVariable(DMLProgram prog,
StatementBlock parforSB,
String var)
This function determines if an parfor input variable is guaranteed to be read-only
across multiple invocations of parfor optimization (e.g., in a surrounding while loop).
|
static void |
replaceConstantScalarVariables(StatementBlock sb,
LocalVariableMap vars) |
static void |
rFindAndRecompileIndexingHOP(StatementBlock sb,
ProgramBlock pb,
String var,
ExecutionContext ec,
boolean force)
NOTE: if force is set, we set and recompile the respective indexing hops;
otherwise, we release the forced exec type and recompile again.
|
public static ArrayList<ProgramBlock> generatePartitialRuntimeProgram(Program rtprog, ArrayList<StatementBlock> sbs)
public static void rFindAndRecompileIndexingHOP(StatementBlock sb, ProgramBlock pb, String var, ExecutionContext ec, boolean force)
sb
- statement blockpb
- program blockvar
- variableec
- execution contextforce
- if true, set and recompile the respective indexing hopspublic static LocalVariableMap getReusableScalarVariables(DMLProgram prog, StatementBlock parforSB, LocalVariableMap vars)
public static void replaceConstantScalarVariables(StatementBlock sb, LocalVariableMap vars)
public static boolean isApplicableForReuseVariable(DMLProgram prog, StatementBlock parforSB, String var)
prog
- dml programparforSB
- parfor statement blockvar
- variablepublic static boolean containsAtLeastOneFunction(ProgramBlock pb)
Copyright © 2020 The Apache Software Foundation. All rights reserved.