Class SSAPRE


  • public class SSAPRE
    extends java.lang.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 Detail

      • 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
      • nextValueNumber

        protected int nextValueNumber
      • killsSorted

        protected boolean[] killsSorted
      • worklist

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

        protected java.util.HashMap phiRelated
    • Constructor Detail

      • 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 Detail

      • transform

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