Class OptTreeConverter
- java.lang.Object
-
- org.apache.sysds.runtime.controlprogram.parfor.opt.OptTreeConverter
-
public class OptTreeConverter extends Object
Converter for creating an internal plan representation for a given runtime program and to modify/create the runtime program according to the optimized plan. NOTE: currently only one abstract and one runtime plan at a time. This implies that only one parfor optimization can happen at a time.
-
-
Field Summary
Fields Modifier and Type Field Description static boolean
INCLUDE_FUNCTIONS
-
Constructor Summary
Constructors Constructor Description OptTreeConverter()
-
Method Summary
-
-
-
Method Detail
-
createOptTree
public static OptTree createOptTree(int ck, double cm, ParForStatementBlock pfsb, ParForProgramBlock pfpb, ExecutionContext ec)
-
createAbstractOptTree
public static OptTree createAbstractOptTree(int ck, double cm, ParForStatementBlock pfsb, ParForProgramBlock pfpb, OptTreePlanMapping hlMap, Set<String> memo, ExecutionContext ec)
-
rCreateAbstractOptNode
public static OptNode rCreateAbstractOptNode(StatementBlock sb, ProgramBlock pb, LocalVariableMap vars, boolean topLevel, OptTreePlanMapping hlMap, Set<String> memo)
-
createAbstractOptNodes
public static ArrayList<OptNode> createAbstractOptNodes(ArrayList<Hop> hops, LocalVariableMap vars, OptTreePlanMapping hlMap, Set<String> memo)
-
rCreateAbstractOptNodes
public static List<OptNode> rCreateAbstractOptNodes(Hop hop, LocalVariableMap vars, OptTreePlanMapping hlMap, Set<String> memo)
-
rContainsSparkInstruction
public static boolean rContainsSparkInstruction(List<ProgramBlock> pbs, boolean inclFunctions)
-
rContainsSparkInstruction
public static boolean rContainsSparkInstruction(ProgramBlock pb, boolean inclFunctions)
-
containsSparkInstruction
public static boolean containsSparkInstruction(BasicProgramBlock pb, boolean inclCPFile)
-
containsSparkInstruction
public static boolean containsSparkInstruction(ArrayList<Instruction> instSet, boolean inclCPFile)
-
containsFunctionCallInstruction
public static boolean containsFunctionCallInstruction(BasicProgramBlock pb)
-
replaceProgramBlock
public static void replaceProgramBlock(OptNode parent, OptNode n, ProgramBlock pbOld, ProgramBlock pbNew, OptTreePlanMapping hlMap)
-
replaceProgramBlock
public static void replaceProgramBlock(List<ProgramBlock> pbs, ProgramBlock pbOld, ProgramBlock pbNew)
-
-