Package org.apache.sysds.hops.rewrite
package org.apache.sysds.hops.rewrite
-
ClassesClassDescriptionThis class allows to check hop dags for validity, e.g., parent-child linking.Base class for all hop rewrites in order to enable generic application of all rules.This program rewriter applies a variety of rule-based rewrites on all hop dags of the given program in one pass over the entire program.Rule: Algebraic Simplifications.Rule: Algebraic Simplifications.Rule: BlockSizeAndReblock.Rule: CommonSubexpressionElimination.Rule: Compressed Re block if config compressed.linalg is enabled, we inject compression directions after read of matrices if number of rows is above 1000 and cols at least 1.Rule: Constant Folding.Prerequisite: RewriteCommonSubexpressionElimination must run before this rule.Rule: Simplify program structure by pulling if or else statement body out (removing the if statement block ifself) in order to allow intra-procedure analysis to propagate exact statistics.Rule: Simplify program structure by hoisting loop-invariant operations out of while, for, or parfor loops.Rule: Indexing vectorization.This Rewrite rule injects a Tee Operator for specific Out-Of-Core (OOC) patterns where a value or an intermediate result is shared twice.Rule: Insert checkpointing operations for caching purposes.Rule: Inject checkpointing on reading in data in all cases where the operand is used in more than one operation.Rule: Mark loop variables that are only read/updated through cp left indexing for update in-place.Rule: Determine the optimal order of execution for a chain of matrix multiplications Solution: Classic Dynamic Programming Approach: Currently, the approach based only on matrix dimensions Goal: To reduce the number of computations in the run-time (map-reduce) layerRule: Determine the optimal order of execution for a chain of matrix multiplications Solution: Classic Dynamic Programming Approach: Currently, the approach based only on matrix dimensions and sparsity estimates using the MNC sketch Goal: To reduce the number of computations in the run-time (map-reduce) layerRule: Determine the optimal order of execution for a chain of matrix multiplications
Solution: Classic Dynamic Programming
Approach: Currently, the approach based only on matrix dimensions
Goal: To reduce the number of computations in the run-time (map-reduce) layerAdvanced Matrix Multiplication Chain Optimizer using Dynamic Programming.Rule: Simplify program structure by merging sequences of last-level statement blocks in order to create optimization opportunities.Rule: RewriteFloorCompress.Rule: Simplify program structure by rewriting relational expressions, implemented here: Pushdown of Selections before Join.Rule: Simplify program structure by removing empty last-level blocks, which may originate from the original program or due to a sequence of rewrites (e.g., checkpoint injection and subsequent IPA).Rule: Simplify program structure by removing empty for loops, which may originate from the sequence of other rewrites like dead-code-elimination.Rule: Simplify program structure by removing (par)for statements iterating over an empty sequence, i.e., (par)for-loops without a single iteration.This rewrite is a custom rewrite for JMLC in order to replace all persistent reads and writes with transient reads and writes from the symbol table.Rule: RemoveReadAfterWrite.Rule: If transformencode procudes a meta data frame which is never used, flag transformencode to never allocate an serialize this frame.Rule: Simplify program structure by pulling if or else statement body out (removing the if statement block ifself) in order to allow intra-procedure analysis to propagate exact statistics.Rule: RemoveUnnecessaryCasts.Rule: Split Hop DAG after specific data-dependent operators.Rule: Split Hop DAG after CSV reads with unknown size.Base class for all hop rewrites in order to enable generic application of all rules.