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, Optimizer.PlanInputType type, ParForStatementBlock pfsb, ParForProgramBlock pfpb, ExecutionContext ec)
-
createAbstractOptTree
public static OptTree createAbstractOptTree(int ck, double cm, ParForStatementBlock pfsb, ParForProgramBlock pfpb, OptTreePlanMappingAbstract hlMap, Set<String> memo, ExecutionContext ec)
-
rCreateOptNode
public static OptNode rCreateOptNode(ProgramBlock pb, LocalVariableMap vars, boolean topLevel, OptTreePlanMappingRuntime rtMap, boolean storeObjs)
-
createOptNodes
public static ArrayList<OptNode> createOptNodes(ArrayList<Instruction> instset, LocalVariableMap vars, OptTreePlanMappingRuntime rtMap, boolean storeObjs)
-
createOptNode
public static OptNode createOptNode(Instruction inst, LocalVariableMap vars, OptTreePlanMappingRuntime rtMap, boolean storeObjs)
-
rCreateAbstractOptNode
public static OptNode rCreateAbstractOptNode(StatementBlock sb, ProgramBlock pb, LocalVariableMap vars, boolean topLevel, OptTreePlanMappingAbstract hlMap, Set<String> memo)
-
createAbstractOptNodes
public static ArrayList<OptNode> createAbstractOptNodes(ArrayList<Hop> hops, LocalVariableMap vars, OptTreePlanMappingAbstract hlMap, Set<String> memo)
-
rCreateAbstractOptNodes
public static ArrayList<OptNode> rCreateAbstractOptNodes(Hop hop, LocalVariableMap vars, OptTreePlanMappingAbstract hlMap, Set<String> memo)
-
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, OptTreePlanMappingAbstract hlMap)
-
replaceProgramBlock
public static void replaceProgramBlock(OptNode parent, OptNode n, ProgramBlock pbOld, ProgramBlock pbNew, OptTreePlanMappingRuntime rtMap)
-
replaceProgramBlock
public static void replaceProgramBlock(List<ProgramBlock> pbs, ProgramBlock pbOld, ProgramBlock pbNew)
-
-