Notes on MLIR
Glossary
Speculative operations
Means that an operation is allowed to be speculatively executed, i.e. computed early, so the compiler can move th op to another location. An operation can be maked with the AlwaysSPeculatable
trait.
Passes
Represent basic infracstructure for transformation and optimization. Passes are enabled by adding traits to operations.
Control Flow Sync (-control-flow-sink)
Moves ops that are only used in one branch of a conditional into the relevant branch. Requires op to be memory-effect free.
Control Subexpression Elimination (-cse)
Removes unnecessarily repeated computations. Requires op to be memory-effect free.
Sparse Conditional Constant Propagation (-sccp)
Attempts to infer when an operation has a constant output and then replaces the operation with the constant value, propagating the constant value as far as possible.
Traits
Used to specify special properties and constraints of an object. They are a mechanism which abstracts implementation details and properties that are common across many different attributes/operations/types/etc.