Class SSAPRE

java.lang.Object
EDU.purdue.cs.bloat.trans.SSAPRE

public class SSAPRE extends Object
Perform partial redundancy elimination of a CFG in SSA form using the SSA-based algorithm described in:
    Fred Chow, Sun Chan, Robert Kennedy, Shin-Ming Liu, Raymond Lo,
    and Peng Tu, "A New Algorithm for Partial Redundancy Elimination
    based on SSA Form", Proc. PLDI '97: 273-286, 1997.
NOTE: The type for all occurrences of an inserted variable is the same as the type of the first occurrence of the expression the variable replaces. This type is guaranteed since we only group expression with equal types.
  • Field Details

    • DEBUG

      public static boolean DEBUG
    • NO_THREAD

      public static boolean NO_THREAD
    • NO_PRECISE

      public static boolean NO_PRECISE
    • NO_ACCESS_PATHS

      public static boolean NO_ACCESS_PATHS
    • cfg

      protected FlowGraph cfg
    • nextValueNumber

      protected int nextValueNumber
    • context

      protected EditorContext context
    • kills

      protected ResizeableArrayList[] kills
    • killsSorted

      protected boolean[] killsSorted
    • sideEffects

      protected SideEffectChecker sideEffects
    • worklist

      protected EDU.purdue.cs.bloat.trans.SSAPRE.ExprWorklist worklist
    • phiRelated

      protected HashMap phiRelated
  • Constructor Details

    • SSAPRE

      public SSAPRE(FlowGraph cfg, EditorContext context)
      Constructor.
      Parameters:
      cfg - Control flow graph on which to perform SSA-based PRE.
      context - The EditorContext containing all the classes that BLOAT knows about.
  • Method Details

    • transform

      public void transform()
      Performs SSA-based partial redundency elimination (PRE) on a control flow graph.