SandMark version 2.0


sandmark.obfuscate.boolsplitter.dtree
Class Tree

java.lang.Object
  |
  +--sandmark.obfuscate.boolsplitter.dtree.Node
        |
        +--sandmark.obfuscate.boolsplitter.dtree.Tree
All Implemented Interfaces:
EDU.purdue.cs.bloat.editor.InstructionVisitor, EDU.purdue.cs.bloat.editor.Opcode

public class Tree
extends Node
implements EDU.purdue.cs.bloat.editor.InstructionVisitor, EDU.purdue.cs.bloat.editor.Opcode

Tree represents the expression tree of a basic Block. It consists of an operand (expression) stack comprised of expressions and a list of statements contained in the block.

See Also:
Block, Expr, OperandStack, see StmtList

Nested Class Summary
(package private)  class Tree.StmtList
          StmtList is a linked list of statements.
 
Field Summary
static boolean AUPDATE_FIX_HACK
           
static boolean AUPDATE_FIX_HACK_CHANGED
           
(package private)  Block block
           
static boolean DEBUG
           
static boolean FLATTEN
           
(package private)  EDU.purdue.cs.bloat.editor.Instruction last
          The last instruction we saw.
(package private)  Block next
           
(package private)  java.util.Stack savedStack
           
(package private)  boolean saveValue
           
(package private)  OperandStack stack
           
(package private) static int stackpos
           
(package private)  Tree.StmtList stmts
           
(package private)  Subroutine sub
           
static boolean USE_PERSISTENT
           
static boolean USE_STACK
           
 
Fields inherited from class sandmark.obfuscate.boolsplitter.dtree.Node
key, parent, valueNumber
 
Fields inherited from interface EDU.purdue.cs.bloat.editor.Opcode
opc_aaload, opc_aastore, opc_aconst_null, opc_aload, opc_aload_0, opc_aload_1, opc_aload_2, opc_aload_3, opc_anewarray, opc_areturn, opc_arraylength, opc_astore, opc_astore_0, opc_astore_1, opc_astore_2, opc_astore_3, opc_aswizzle, opc_aswrange, opc_athrow, opc_aupdate, opc_baload, opc_bastore, opc_bipush, opc_breakpoint, opc_caload, opc_castore, opc_checkcast, opc_d2f, opc_d2i, opc_d2l, opc_dadd, opc_daload, opc_dastore, opc_dcmpg, opc_dcmpl, opc_dconst_0, opc_dconst_1, opc_ddiv, opc_dload, opc_dload_0, opc_dload_1, opc_dload_2, opc_dload_3, opc_dmul, opc_dneg, opc_drem, opc_dreturn, opc_dstore, opc_dstore_0, opc_dstore_1, opc_dstore_2, opc_dstore_3, opc_dsub, opc_dup, opc_dup_x1, opc_dup_x2, opc_dup2, opc_dup2_x1, opc_dup2_x2, opc_f2d, opc_f2i, opc_f2l, opc_fadd, opc_faload, opc_fastore, opc_fcmpg, opc_fcmpl, opc_fconst_0, opc_fconst_1, opc_fconst_2, opc_fdiv, opc_fload, opc_fload_0, opc_fload_1, opc_fload_2, opc_fload_3, opc_fmul, opc_fneg, opc_frem, opc_freturn, opc_fstore, opc_fstore_0, opc_fstore_1, opc_fstore_2, opc_fstore_3, opc_fsub, opc_getfield, opc_getstatic, opc_goto, opc_goto_w, opc_i2b, opc_i2c, opc_i2d, opc_i2f, opc_i2l, opc_i2s, opc_iadd, opc_iaload, opc_iand, opc_iastore, opc_iconst_0, opc_iconst_1, opc_iconst_2, opc_iconst_3, opc_iconst_4, opc_iconst_5, opc_iconst_m1, opc_idiv, opc_if_acmpeq, opc_if_acmpne, opc_if_icmpeq, opc_if_icmpge, opc_if_icmpgt, opc_if_icmple, opc_if_icmplt, opc_if_icmpne, opc_ifeq, opc_ifge, opc_ifgt, opc_ifle, opc_iflt, opc_ifne, opc_ifnonnull, opc_ifnull, opc_iinc, opc_iload, opc_iload_0, opc_iload_1, opc_iload_2, opc_iload_3, opc_imul, opc_ineg, opc_instanceof, opc_invokeinterface, opc_invokespecial, opc_invokestatic, opc_invokevirtual, opc_ior, opc_irem, opc_ireturn, opc_ishl, opc_ishr, opc_istore, opc_istore_0, opc_istore_1, opc_istore_2, opc_istore_3, opc_isub, opc_iushr, opc_ixor, opc_jsr, opc_jsr_w, opc_l2d, opc_l2f, opc_l2i, opc_ladd, opc_laload, opc_land, opc_lastore, opc_lcmp, opc_lconst_0, opc_lconst_1, opc_ldc, opc_ldc_w, opc_ldc2_w, opc_ldiv, opc_lload, opc_lload_0, opc_lload_1, opc_lload_2, opc_lload_3, opc_lmul, opc_lneg, opc_lookupswitch, opc_lor, opc_lrem, opc_lreturn, opc_lshl, opc_lshr, opc_lstore, opc_lstore_0, opc_lstore_1, opc_lstore_2, opc_lstore_3, opc_lsub, opc_lushr, opc_lxor, opc_monitorenter, opc_monitorexit, opc_multianewarray, opc_new, opc_newarray, opc_nop, opc_pop, opc_pop2, opc_putfield, opc_putfield_nowb, opc_putstatic, opc_putstatic_nowb, opc_rc, opc_ret, opc_return, opc_saload, opc_sastore, opc_sipush, opc_supdate, opc_swap, opc_tableswitch, opc_wide, opc_xxxunusedxxx, opcNames, opcSize, opcx_aaload, opcx_aastore, opcx_aload, opcx_areturn, opcx_arraylength, opcx_astore, opcx_aswizzle, opcx_aswrange, opcx_athrow, opcx_aupdate, opcx_baload, opcx_bastore, opcx_caload, opcx_castore, opcx_checkcast, opcx_d2f, opcx_d2i, opcx_d2l, opcx_dadd, opcx_daload, opcx_dastore, opcx_dcmpg, opcx_dcmpl, opcx_ddiv, opcx_dload, opcx_dmul, opcx_dneg, opcx_drem, opcx_dreturn, opcx_dstore, opcx_dsub, opcx_dup, opcx_dup_x1, opcx_dup_x2, opcx_dup2, opcx_dup2_x1, opcx_dup2_x2, opcx_f2d, opcx_f2i, opcx_f2l, opcx_fadd, opcx_faload, opcx_fastore, opcx_fcmpg, opcx_fcmpl, opcx_fdiv, opcx_fload, opcx_fmul, opcx_fneg, opcx_frem, opcx_freturn, opcx_fstore, opcx_fsub, opcx_getfield, opcx_getstatic, opcx_goto, opcx_i2b, opcx_i2c, opcx_i2d, opcx_i2f, opcx_i2l, opcx_i2s, opcx_iadd, opcx_iaload, opcx_iand, opcx_iastore, opcx_idiv, opcx_if_acmpeq, opcx_if_acmpne, opcx_if_icmpeq, opcx_if_icmpge, opcx_if_icmpgt, opcx_if_icmple, opcx_if_icmplt, opcx_if_icmpne, opcx_ifeq, opcx_ifge, opcx_ifgt, opcx_ifle, opcx_iflt, opcx_ifne, opcx_ifnonnull, opcx_ifnull, opcx_iinc, opcx_iload, opcx_imul, opcx_ineg, opcx_instanceof, opcx_invokeinterface, opcx_invokespecial, opcx_invokestatic, opcx_invokevirtual, opcx_ior, opcx_irem, opcx_ireturn, opcx_ishl, opcx_ishr, opcx_istore, opcx_isub, opcx_iushr, opcx_ixor, opcx_jsr, opcx_l2d, opcx_l2f, opcx_l2i, opcx_ladd, opcx_laload, opcx_land, opcx_lastore, opcx_lcmp, opcx_ldc, opcx_ldiv, opcx_lload, opcx_lmul, opcx_lneg, opcx_lor, opcx_lrem, opcx_lreturn, opcx_lshl, opcx_lshr, opcx_lstore, opcx_lsub, opcx_lushr, opcx_lxor, opcx_monitorenter, opcx_monitorexit, opcx_multianewarray, opcx_new, opcx_newarray, opcx_nop, opcx_pop, opcx_pop2, opcx_putfield, opcx_putfield_nowb, opcx_putstatic, opcx_putstatic_nowb, opcx_rc, opcx_ret, opcx_return, opcx_saload, opcx_sastore, opcx_supdate, opcx_swap, opcx_switch, opcXMap, VARIABLE
 
Constructor Summary
Tree(Block block, OperandStack predStack)
          Constructor.
 
Method Summary
 void addInstruction(EDU.purdue.cs.bloat.editor.Instruction inst)
          Adds an instruction that does not change the control flow (a normal instruction).
 void addInstruction(EDU.purdue.cs.bloat.editor.Instruction inst, Block next)
          Adds an instruction that jumps to another basic block.
 void addInstruction(EDU.purdue.cs.bloat.editor.Instruction inst, Subroutine sub)
          Add an instruction such as ret or astore that may involve a subroutine.
 void addLabel(EDU.purdue.cs.bloat.editor.Label label)
          Add a label to the statement list.
 void addStmt(Stmt stmt)
          Save the contents of the stack and add stmt to the statement list.
 void addStmtAfter(Stmt stmt, Stmt after)
          Inserts a statement into the statement list after another given statement.
 void addStmtBefore(Stmt stmt, Stmt before)
          Inserts a statement into the statement list before a specified statement.
 void addStmtBeforeJump(Stmt stmt)
          Adds a statement to the statement list before the last jump statement.
 Block block()
          Returns the basic block in which this Node resides.
 void cleanupOnly()
          Cleans up this node.
 void initLocals(java.util.Collection locals)
          Add a Collection of local variables to the block.
 Stmt lastStmt()
          Returns the last non-Label statement in the statement list.
 LocalExpr newLocal(int index, EDU.purdue.cs.bloat.editor.Type type)
          Returns a new LocalExpr that is not allocated on the stack.
 LocalExpr newLocal(EDU.purdue.cs.bloat.editor.Type type)
          Returns a local variable (LocalExpr) located in this method.
 StackExpr newStack(EDU.purdue.cs.bloat.editor.Type type)
          Returns a new StackExpr for the top of the operand stack.
 LocalExpr newStackLocal(int index, EDU.purdue.cs.bloat.editor.Type type)
          Returns a new LocalExpr that represents an element of the stack.
 Node parent()
           
 void prependStmt(Stmt stmt)
          Add an statement to the statement list before the first non-Label statement.
 void removeLastStmt()
          Removes the last non-Label statement from the statement list.
 void removeStmt(Stmt stmt)
          Removes a statement from the statement list.
 OperandStack stack()
          Returns the operand stack.
 java.util.List stmts()
           
 java.lang.String toString()
          Returns a String representation of this Tree.
 void visit_aaload(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_aastore(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_aload(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_areturn(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_arraylength(EDU.purdue.cs.bloat.editor.Instruction inst)
          Pushes an ArrayLengthExpr onto the operand stack.
 void visit_astore(EDU.purdue.cs.bloat.editor.Instruction inst)
          Visit an astore instruction.
 void visit_aswizzle(EDU.purdue.cs.bloat.editor.Instruction inst)
          Add a SCStmt to the statement list
 void visit_aswrange(EDU.purdue.cs.bloat.editor.Instruction inst)
          Add a SRStmt to the statement list.
 void visit_athrow(EDU.purdue.cs.bloat.editor.Instruction inst)
          Adds a ThrowStmt to the statement list.
 void visit_aupdate(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_baload(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_bastore(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_caload(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_castore(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_checkcast(EDU.purdue.cs.bloat.editor.Instruction inst)
          Pushes a CastExpr onto the operand stack.
 void visit_d2f(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_d2i(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_d2l(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_dadd(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_daload(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_dastore(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_dcmpg(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_dcmpl(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_ddiv(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_dload(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_dmul(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_dneg(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_drem(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_dreturn(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_dstore(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_dsub(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_dup_x1(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_dup_x2(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_dup(EDU.purdue.cs.bloat.editor.Instruction inst)
          When processing the dup instructions one of two situations can occur.
 void visit_dup2_x1(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_dup2_x2(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_dup2(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_f2d(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_f2i(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_f2l(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_fadd(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_faload(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_fastore(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_fcmpg(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_fcmpl(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_fdiv(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_fload(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_fmul(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_fneg(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_frem(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_freturn(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_fstore(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_fsub(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_getfield(EDU.purdue.cs.bloat.editor.Instruction inst)
          Pushes a FieldExpr onto the operand stack.
 void visit_getstatic(EDU.purdue.cs.bloat.editor.Instruction inst)
          Pushes a StaticFieldExpr onto the operand stack.
 void visit_goto(EDU.purdue.cs.bloat.editor.Instruction inst)
          Adds a GotoStmt to the statement list.
 void visit_i2b(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_i2c(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_i2d(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_i2f(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_i2l(EDU.purdue.cs.bloat.editor.Instruction inst)
          All cast visitors push a CastExpr onto the operand stack.
 void visit_i2s(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_iadd(EDU.purdue.cs.bloat.editor.Instruction inst)
          All visit_xadd, visit_xsub, visit_xmul, visit_xdiv, etc. push an ArithExpr onto the operand stack.
 void visit_iaload(EDU.purdue.cs.bloat.editor.Instruction inst)
          All visit_xaload push an ArrayRefExpr onto the operand stack.
 void visit_iand(EDU.purdue.cs.bloat.editor.Instruction inst)
          All visit_x op push an ArithExpr onto the stack.
 void visit_iastore(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_idiv(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_if_acmpeq(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_if_acmpne(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_if_icmpeq(EDU.purdue.cs.bloat.editor.Instruction inst)
          All visit_if_xcmpy add a IfCmpStmt to the statement list.
 void visit_if_icmpge(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_if_icmpgt(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_if_icmple(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_if_icmplt(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_if_icmpne(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_ifeq(EDU.purdue.cs.bloat.editor.Instruction inst)
          All visit_xeg add an IfZeroStmt to the statement list.
 void visit_ifge(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_ifgt(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_ifle(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_iflt(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_ifne(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_ifnonnull(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_ifnull(EDU.purdue.cs.bloat.editor.Instruction inst)
          Both visit_xnull add an IfZeroStmt to the statement list.
 void visit_iinc(EDU.purdue.cs.bloat.editor.Instruction inst)
          Visiting an iinc involves creating a ConstantExpr, LocalExpr, ArithExpr StoreExpr, and a ExprStmt.
 void visit_iload(EDU.purdue.cs.bloat.editor.Instruction inst)
          All visit_xload push a LocalExpr onto the operand stack.
 void visit_imul(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_ineg(EDU.purdue.cs.bloat.editor.Instruction inst)
          All visit_xneg push a NegExpr onto the stack.
 void visit_instanceof(EDU.purdue.cs.bloat.editor.Instruction inst)
          Pushes an InstanceOfExpr onto the operand stack.
 void visit_invokeinterface(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_invokespecial(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_invokestatic(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_invokevirtual(EDU.purdue.cs.bloat.editor.Instruction inst)
          All visit_invokex deal with a CallMethodExpr or a CallStaticExpr.
 void visit_ior(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_irem(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_ireturn(EDU.purdue.cs.bloat.editor.Instruction inst)
          All visit_xreturn add a ReturnExprStmt to the statement list.
 void visit_ishl(EDU.purdue.cs.bloat.editor.Instruction inst)
          All visit_xshd push a ShiftExpr onto the operand stack.
 void visit_ishr(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_istore(EDU.purdue.cs.bloat.editor.Instruction inst)
          All visit_xstore add a LocalExpr statement to the statement list.
 void visit_isub(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_iushr(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_ixor(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_jsr(EDU.purdue.cs.bloat.editor.Instruction inst)
          Adds a JsrStmt to the statement list.
 void visit_l2d(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_l2f(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_l2i(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_ladd(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_laload(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_land(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_lastore(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_lcmp(EDU.purdue.cs.bloat.editor.Instruction inst)
          All visit_xcmp push an ArithExpr onto the stack.
 void visit_ldc(EDU.purdue.cs.bloat.editor.Instruction inst)
          Pushes a ConstantExpr onto the operand stack.
 void visit_ldiv(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_lload(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_lmul(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_lneg(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_lor(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_lrem(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_lreturn(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_lshl(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_lshr(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_lstore(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_lsub(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_lushr(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_lxor(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_monitorenter(EDU.purdue.cs.bloat.editor.Instruction inst)
          Both monitor visitors add a MonitorStmt to the statement list.
 void visit_monitorexit(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_multianewarray(EDU.purdue.cs.bloat.editor.Instruction inst)
          Push a NewMultiArrayExpr onto the operand stack.
 void visit_new(EDU.purdue.cs.bloat.editor.Instruction inst)
          Pushes a NewExpr onto the operand stack.
 void visit_newarray(EDU.purdue.cs.bloat.editor.Instruction inst)
          Pushes a NewArrayExpr onto the operand stack.
 void visit_nop(EDU.purdue.cs.bloat.editor.Instruction inst)
          Adds no statements to the statement list.
 void visit_pop(EDU.purdue.cs.bloat.editor.Instruction inst)
          Pop the expression off the top of the stack and add it as an ExprStmt to the statement list.
 void visit_pop2(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_putfield_nowb(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_putfield(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_putstatic_nowb(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_putstatic(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_rc(EDU.purdue.cs.bloat.editor.Instruction inst)
          Replaces the expression on the top of the stack with an RCExpr.
 void visit_ret(EDU.purdue.cs.bloat.editor.Instruction inst)
          Adds a RetStmt to the statement list.
 void visit_return(EDU.purdue.cs.bloat.editor.Instruction inst)
          Adds a ReturnStmt to the statement list.
 void visit_saload(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_sastore(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_supdate(EDU.purdue.cs.bloat.editor.Instruction inst)
          Replace the expression at the stack depth specified in the instruction with a UCExpr.
 void visit_swap(EDU.purdue.cs.bloat.editor.Instruction inst)
           
 void visit_switch(EDU.purdue.cs.bloat.editor.Instruction inst)
          Add a SwitchStmt to the statement list.
 void visit(TreeVisitor visitor)
           
 void visitForceChildren(TreeVisitor visitor)
          Visit all the statements in the statement list.
 
Methods inherited from class sandmark.obfuscate.boolsplitter.dtree.Node
cleanup, copyInto, hasParent, key, replaceWith, replaceWith, setKey, setParent, setValueNumber, valueNumber, visitChildren, visitOnly
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface EDU.purdue.cs.bloat.editor.Opcode
 

Field Detail

DEBUG

public static boolean DEBUG

FLATTEN

public static boolean FLATTEN

USE_STACK

public static boolean USE_STACK

AUPDATE_FIX_HACK

public static boolean AUPDATE_FIX_HACK

AUPDATE_FIX_HACK_CHANGED

public static boolean AUPDATE_FIX_HACK_CHANGED

USE_PERSISTENT

public static boolean USE_PERSISTENT

block

Block block

sub

Subroutine sub

next

Block next

stack

OperandStack stack

stmts

Tree.StmtList stmts

savedStack

java.util.Stack savedStack

stackpos

static int stackpos

saveValue

boolean saveValue

last

EDU.purdue.cs.bloat.editor.Instruction last
The last instruction we saw. addInst(Instruction) needs this information.

Constructor Detail

Tree

public Tree(Block block,
            OperandStack predStack)
Constructor.

Parameters:
block - The basic Block of code represented in this Tree.
predStack - The contents of the operand stack from the previous basic Block.
Method Detail

cleanupOnly

public void cleanupOnly()
Cleans up this node. Does nothing in this case.

Specified by:
cleanupOnly in class Node

initLocals

public void initLocals(java.util.Collection locals)
Add a Collection of local variables to the block. Add an InitStmt to the statement list.

See Also:
LocalExpr, InitStmt

removeStmt

public void removeStmt(Stmt stmt)
Removes a statement from the statement list.

Parameters:
stmt - The statement to remove

removeLastStmt

public void removeLastStmt()
Removes the last non-Label statement from the statement list.


stmts

public java.util.List stmts()
Returns:
The statement list

lastStmt

public Stmt lastStmt()
Returns the last non-Label statement in the statement list.


stack

public OperandStack stack()
Returns the operand stack.


addStmtAfter

public void addStmtAfter(Stmt stmt,
                         Stmt after)
Inserts a statement into the statement list after another given statement.

Parameters:
stmt - The statement to add.
after - The statement after which to add stmt.

addStmtBefore

public void addStmtBefore(Stmt stmt,
                          Stmt before)
Inserts a statement into the statement list before a specified statement.

Parameters:
stmt - The statement to insert
before - The statement before which to add stmt.

prependStmt

public void prependStmt(Stmt stmt)
Add an statement to the statement list before the first non-Label statement.

Parameters:
stmt - The statement to add.

addStmt

public void addStmt(Stmt stmt)
Save the contents of the stack and add stmt to the statement list.

Parameters:
stmt - A statement to add to the statement list.

addStmtBeforeJump

public void addStmtBeforeJump(Stmt stmt)
Adds a statement to the statement list before the last jump statement. It is assumed that the last statement in the statement list is a jump statement.

See Also:
JumpStmt

addInstruction

public void addInstruction(EDU.purdue.cs.bloat.editor.Instruction inst,
                           Block next)
Adds an instruction that jumps to another basic block.

Parameters:
inst - The instruction to add.
next - The basic block after the jump. Remember that a jump ends a basic block.
See Also:
Instruction.isJsr(), Instruction.isConditionalJump()

addInstruction

public void addInstruction(EDU.purdue.cs.bloat.editor.Instruction inst)
Adds an instruction that does not change the control flow (a normal instruction).

Parameters:
inst - Instruction to add.

addInstruction

public void addInstruction(EDU.purdue.cs.bloat.editor.Instruction inst,
                           Subroutine sub)
Add an instruction such as ret or astore that may involve a subroutine.

Parameters:
inst - Instruction to add.
sub - Subroutine in which inst resides. The ret instruction always resides in a Subroutine. An astore may store the return address of a subroutine in a local variable.
See Also:
Instruction.isRet()

addLabel

public void addLabel(EDU.purdue.cs.bloat.editor.Label label)
Add a label to the statement list. A label is inserted before a dup statement, but after any other statement.

Parameters:
label - Label to add.

newStack

public StackExpr newStack(EDU.purdue.cs.bloat.editor.Type type)
Returns a new StackExpr for the top of the operand stack.


newStackLocal

public LocalExpr newStackLocal(int index,
                               EDU.purdue.cs.bloat.editor.Type type)
Returns a new LocalExpr that represents an element of the stack. They are created when the USE_STACK flag is not set.

Parameters:
index - Stack index of variable.
type - The type of the LocalExpr

newLocal

public LocalExpr newLocal(int index,
                          EDU.purdue.cs.bloat.editor.Type type)
Returns a new LocalExpr that is not allocated on the stack.

Parameters:
index - Stack index of variable.
type - The type of the LocalExpr

newLocal

public LocalExpr newLocal(EDU.purdue.cs.bloat.editor.Type type)
Returns a local variable (LocalExpr) located in this method.

Parameters:
type - The type of the new LocalExpr.

toString

public java.lang.String toString()
Returns a String representation of this Tree.

Overrides:
toString in class Node
Returns:
A textual representation of this Node.

visit_nop

public void visit_nop(EDU.purdue.cs.bloat.editor.Instruction inst)
Adds no statements to the statement list.

Specified by:
visit_nop in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_ldc

public void visit_ldc(EDU.purdue.cs.bloat.editor.Instruction inst)
Pushes a ConstantExpr onto the operand stack.

Specified by:
visit_ldc in interface EDU.purdue.cs.bloat.editor.InstructionVisitor
See Also:
ConstantExpr

visit_iload

public void visit_iload(EDU.purdue.cs.bloat.editor.Instruction inst)
All visit_xload push a LocalExpr onto the operand stack.

Specified by:
visit_iload in interface EDU.purdue.cs.bloat.editor.InstructionVisitor
See Also:
LocalExpr

visit_lload

public void visit_lload(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_lload in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_fload

public void visit_fload(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_fload in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_dload

public void visit_dload(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_dload in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_aload

public void visit_aload(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_aload in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_iaload

public void visit_iaload(EDU.purdue.cs.bloat.editor.Instruction inst)
All visit_xaload push an ArrayRefExpr onto the operand stack.

Specified by:
visit_iaload in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_laload

public void visit_laload(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_laload in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_faload

public void visit_faload(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_faload in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_daload

public void visit_daload(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_daload in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_aaload

public void visit_aaload(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_aaload in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_baload

public void visit_baload(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_baload in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_caload

public void visit_caload(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_caload in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_saload

public void visit_saload(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_saload in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_istore

public void visit_istore(EDU.purdue.cs.bloat.editor.Instruction inst)
All visit_xstore add a LocalExpr statement to the statement list.

Specified by:
visit_istore in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_lstore

public void visit_lstore(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_lstore in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_fstore

public void visit_fstore(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_fstore in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_dstore

public void visit_dstore(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_dstore in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_astore

public void visit_astore(EDU.purdue.cs.bloat.editor.Instruction inst)
Visit an astore instruction. If the type of the operand to the instruction is an address add an AddressStoreStmt to the tree, else add a StoreStmt to the tree consisting of a LocalExpr and the top Expr on the operand stack.

Specified by:
visit_astore in interface EDU.purdue.cs.bloat.editor.InstructionVisitor
See Also:
AddressStoreStmt, LocalExpr, StoreExpr

visit_iastore

public void visit_iastore(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_iastore in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_lastore

public void visit_lastore(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_lastore in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_fastore

public void visit_fastore(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_fastore in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_dastore

public void visit_dastore(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_dastore in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_aastore

public void visit_aastore(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_aastore in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_bastore

public void visit_bastore(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_bastore in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_castore

public void visit_castore(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_castore in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_sastore

public void visit_sastore(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_sastore in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_pop

public void visit_pop(EDU.purdue.cs.bloat.editor.Instruction inst)
Pop the expression off the top of the stack and add it as an ExprStmt to the statement list.

Specified by:
visit_pop in interface EDU.purdue.cs.bloat.editor.InstructionVisitor
See Also:
ExprStmt

visit_pop2

public void visit_pop2(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_pop2 in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_dup

public void visit_dup(EDU.purdue.cs.bloat.editor.Instruction inst)
When processing the dup instructions one of two situations can occur. If the USE_STACK flag is set, then a StackManipStmt is created to represent the transformation that the dup instruction performs on the stack. If the USE_STACK flag is not set, then the transformation is simulated by creating new local variables containing the appropriate element of the stack.

Specified by:
visit_dup in interface EDU.purdue.cs.bloat.editor.InstructionVisitor
See Also:
LocalExpr, StackExpr, StackManipStmt

visit_dup_x1

public void visit_dup_x1(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_dup_x1 in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_dup_x2

public void visit_dup_x2(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_dup_x2 in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_dup2

public void visit_dup2(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_dup2 in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_dup2_x1

public void visit_dup2_x1(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_dup2_x1 in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_dup2_x2

public void visit_dup2_x2(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_dup2_x2 in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_swap

public void visit_swap(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_swap in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_iadd

public void visit_iadd(EDU.purdue.cs.bloat.editor.Instruction inst)
All visit_xadd, visit_xsub, visit_xmul, visit_xdiv, etc. push an ArithExpr onto the operand stack.

Specified by:
visit_iadd in interface EDU.purdue.cs.bloat.editor.InstructionVisitor
See Also:
ArithExpr

visit_ladd

public void visit_ladd(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_ladd in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_fadd

public void visit_fadd(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_fadd in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_dadd

public void visit_dadd(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_dadd in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_isub

public void visit_isub(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_isub in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_lsub

public void visit_lsub(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_lsub in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_fsub

public void visit_fsub(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_fsub in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_dsub

public void visit_dsub(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_dsub in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_imul

public void visit_imul(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_imul in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_lmul

public void visit_lmul(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_lmul in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_fmul

public void visit_fmul(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_fmul in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_dmul

public void visit_dmul(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_dmul in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_idiv

public void visit_idiv(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_idiv in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_ldiv

public void visit_ldiv(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_ldiv in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_fdiv

public void visit_fdiv(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_fdiv in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_ddiv

public void visit_ddiv(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_ddiv in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_irem

public void visit_irem(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_irem in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_lrem

public void visit_lrem(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_lrem in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_frem

public void visit_frem(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_frem in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_drem

public void visit_drem(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_drem in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_ineg

public void visit_ineg(EDU.purdue.cs.bloat.editor.Instruction inst)
All visit_xneg push a NegExpr onto the stack.

Specified by:
visit_ineg in interface EDU.purdue.cs.bloat.editor.InstructionVisitor
See Also:
NegExpr

visit_lneg

public void visit_lneg(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_lneg in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_fneg

public void visit_fneg(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_fneg in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_dneg

public void visit_dneg(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_dneg in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_ishl

public void visit_ishl(EDU.purdue.cs.bloat.editor.Instruction inst)
All visit_xshd push a ShiftExpr onto the operand stack.

Specified by:
visit_ishl in interface EDU.purdue.cs.bloat.editor.InstructionVisitor
See Also:
ShiftExpr

visit_lshl

public void visit_lshl(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_lshl in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_ishr

public void visit_ishr(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_ishr in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_lshr

public void visit_lshr(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_lshr in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_iushr

public void visit_iushr(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_iushr in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_lushr

public void visit_lushr(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_lushr in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_iand

public void visit_iand(EDU.purdue.cs.bloat.editor.Instruction inst)
All visit_x op push an ArithExpr onto the stack.

Specified by:
visit_iand in interface EDU.purdue.cs.bloat.editor.InstructionVisitor
See Also:
ArithExpr

visit_land

public void visit_land(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_land in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_ior

public void visit_ior(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_ior in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_lor

public void visit_lor(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_lor in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_ixor

public void visit_ixor(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_ixor in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_lxor

public void visit_lxor(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_lxor in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_iinc

public void visit_iinc(EDU.purdue.cs.bloat.editor.Instruction inst)
Visiting an iinc involves creating a ConstantExpr, LocalExpr, ArithExpr StoreExpr, and a ExprStmt.

Specified by:
visit_iinc in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_i2l

public void visit_i2l(EDU.purdue.cs.bloat.editor.Instruction inst)
All cast visitors push a CastExpr onto the operand stack.

Specified by:
visit_i2l in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_i2f

public void visit_i2f(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_i2f in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_i2d

public void visit_i2d(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_i2d in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_l2i

public void visit_l2i(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_l2i in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_l2f

public void visit_l2f(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_l2f in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_l2d

public void visit_l2d(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_l2d in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_f2i

public void visit_f2i(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_f2i in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_f2l

public void visit_f2l(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_f2l in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_f2d

public void visit_f2d(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_f2d in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_d2i

public void visit_d2i(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_d2i in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_d2l

public void visit_d2l(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_d2l in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_d2f

public void visit_d2f(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_d2f in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_i2b

public void visit_i2b(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_i2b in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_i2c

public void visit_i2c(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_i2c in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_i2s

public void visit_i2s(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_i2s in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_lcmp

public void visit_lcmp(EDU.purdue.cs.bloat.editor.Instruction inst)
All visit_xcmp push an ArithExpr onto the stack.

Specified by:
visit_lcmp in interface EDU.purdue.cs.bloat.editor.InstructionVisitor
See Also:
ArithExpr

visit_fcmpl

public void visit_fcmpl(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_fcmpl in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_fcmpg

public void visit_fcmpg(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_fcmpg in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_dcmpl

public void visit_dcmpl(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_dcmpl in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_dcmpg

public void visit_dcmpg(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_dcmpg in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_ifeq

public void visit_ifeq(EDU.purdue.cs.bloat.editor.Instruction inst)
All visit_xeg add an IfZeroStmt to the statement list.

Specified by:
visit_ifeq in interface EDU.purdue.cs.bloat.editor.InstructionVisitor
See Also:
IfZeroStmt

visit_ifne

public void visit_ifne(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_ifne in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_iflt

public void visit_iflt(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_iflt in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_ifge

public void visit_ifge(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_ifge in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_ifgt

public void visit_ifgt(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_ifgt in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_ifle

public void visit_ifle(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_ifle in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_if_icmpeq

public void visit_if_icmpeq(EDU.purdue.cs.bloat.editor.Instruction inst)
All visit_if_xcmpy add a IfCmpStmt to the statement list.

Specified by:
visit_if_icmpeq in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_if_icmpne

public void visit_if_icmpne(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_if_icmpne in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_if_icmplt

public void visit_if_icmplt(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_if_icmplt in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_if_icmpge

public void visit_if_icmpge(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_if_icmpge in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_if_icmpgt

public void visit_if_icmpgt(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_if_icmpgt in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_if_icmple

public void visit_if_icmple(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_if_icmple in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_if_acmpeq

public void visit_if_acmpeq(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_if_acmpeq in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_if_acmpne

public void visit_if_acmpne(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_if_acmpne in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_goto

public void visit_goto(EDU.purdue.cs.bloat.editor.Instruction inst)
Adds a GotoStmt to the statement list.

Specified by:
visit_goto in interface EDU.purdue.cs.bloat.editor.InstructionVisitor
See Also:
GotoStmt

visit_jsr

public void visit_jsr(EDU.purdue.cs.bloat.editor.Instruction inst)
Adds a JsrStmt to the statement list.

Specified by:
visit_jsr in interface EDU.purdue.cs.bloat.editor.InstructionVisitor
See Also:
JsrStmt

visit_ret

public void visit_ret(EDU.purdue.cs.bloat.editor.Instruction inst)
Adds a RetStmt to the statement list.

Specified by:
visit_ret in interface EDU.purdue.cs.bloat.editor.InstructionVisitor
See Also:
RetStmt

visit_switch

public void visit_switch(EDU.purdue.cs.bloat.editor.Instruction inst)
Add a SwitchStmt to the statement list.

Specified by:
visit_switch in interface EDU.purdue.cs.bloat.editor.InstructionVisitor
See Also:
SwitchStmt

visit_ireturn

public void visit_ireturn(EDU.purdue.cs.bloat.editor.Instruction inst)
All visit_xreturn add a ReturnExprStmt to the statement list.

Specified by:
visit_ireturn in interface EDU.purdue.cs.bloat.editor.InstructionVisitor
See Also:
ReturnExprStmt

visit_lreturn

public void visit_lreturn(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_lreturn in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_freturn

public void visit_freturn(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_freturn in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_dreturn

public void visit_dreturn(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_dreturn in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_areturn

public void visit_areturn(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_areturn in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_return

public void visit_return(EDU.purdue.cs.bloat.editor.Instruction inst)
Adds a ReturnStmt to the statement list.

Specified by:
visit_return in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_getstatic

public void visit_getstatic(EDU.purdue.cs.bloat.editor.Instruction inst)
Pushes a StaticFieldExpr onto the operand stack.

Specified by:
visit_getstatic in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_putstatic

public void visit_putstatic(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_putstatic in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_putstatic_nowb

public void visit_putstatic_nowb(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_putstatic_nowb in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_getfield

public void visit_getfield(EDU.purdue.cs.bloat.editor.Instruction inst)
Pushes a FieldExpr onto the operand stack.

Specified by:
visit_getfield in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_putfield

public void visit_putfield(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_putfield in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_putfield_nowb

public void visit_putfield_nowb(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_putfield_nowb in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_invokevirtual

public void visit_invokevirtual(EDU.purdue.cs.bloat.editor.Instruction inst)
All visit_invokex deal with a CallMethodExpr or a CallStaticExpr.

Specified by:
visit_invokevirtual in interface EDU.purdue.cs.bloat.editor.InstructionVisitor
See Also:
CallMethodExpr, CallStaticExpr

visit_invokespecial

public void visit_invokespecial(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_invokespecial in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_invokestatic

public void visit_invokestatic(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_invokestatic in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_invokeinterface

public void visit_invokeinterface(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_invokeinterface in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_new

public void visit_new(EDU.purdue.cs.bloat.editor.Instruction inst)
Pushes a NewExpr onto the operand stack.

Specified by:
visit_new in interface EDU.purdue.cs.bloat.editor.InstructionVisitor
See Also:
NewExpr

visit_newarray

public void visit_newarray(EDU.purdue.cs.bloat.editor.Instruction inst)
Pushes a NewArrayExpr onto the operand stack.

Specified by:
visit_newarray in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_arraylength

public void visit_arraylength(EDU.purdue.cs.bloat.editor.Instruction inst)
Pushes an ArrayLengthExpr onto the operand stack.

Specified by:
visit_arraylength in interface EDU.purdue.cs.bloat.editor.InstructionVisitor
See Also:
ArrayLengthExpr

visit_athrow

public void visit_athrow(EDU.purdue.cs.bloat.editor.Instruction inst)
Adds a ThrowStmt to the statement list.

Specified by:
visit_athrow in interface EDU.purdue.cs.bloat.editor.InstructionVisitor
See Also:
ThrowStmt

visit_checkcast

public void visit_checkcast(EDU.purdue.cs.bloat.editor.Instruction inst)
Pushes a CastExpr onto the operand stack.

Specified by:
visit_checkcast in interface EDU.purdue.cs.bloat.editor.InstructionVisitor
See Also:
CastExpr

visit_instanceof

public void visit_instanceof(EDU.purdue.cs.bloat.editor.Instruction inst)
Pushes an InstanceOfExpr onto the operand stack.

Specified by:
visit_instanceof in interface EDU.purdue.cs.bloat.editor.InstructionVisitor
See Also:
InstanceOfExpr

visit_monitorenter

public void visit_monitorenter(EDU.purdue.cs.bloat.editor.Instruction inst)
Both monitor visitors add a MonitorStmt to the statement list.

Specified by:
visit_monitorenter in interface EDU.purdue.cs.bloat.editor.InstructionVisitor
See Also:
MonitorStmt

visit_monitorexit

public void visit_monitorexit(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_monitorexit in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_multianewarray

public void visit_multianewarray(EDU.purdue.cs.bloat.editor.Instruction inst)
Push a NewMultiArrayExpr onto the operand stack.

Specified by:
visit_multianewarray in interface EDU.purdue.cs.bloat.editor.InstructionVisitor
See Also:
NewMultiArrayExpr

visit_ifnull

public void visit_ifnull(EDU.purdue.cs.bloat.editor.Instruction inst)
Both visit_xnull add an IfZeroStmt to the statement list. ssee IfZeroStmt

Specified by:
visit_ifnull in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_ifnonnull

public void visit_ifnonnull(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_ifnonnull in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_rc

public void visit_rc(EDU.purdue.cs.bloat.editor.Instruction inst)
Replaces the expression on the top of the stack with an RCExpr.

Specified by:
visit_rc in interface EDU.purdue.cs.bloat.editor.InstructionVisitor
See Also:
RCExpr

visit_aupdate

public void visit_aupdate(EDU.purdue.cs.bloat.editor.Instruction inst)
Specified by:
visit_aupdate in interface EDU.purdue.cs.bloat.editor.InstructionVisitor

visit_supdate

public void visit_supdate(EDU.purdue.cs.bloat.editor.Instruction inst)
Replace the expression at the stack depth specified in the instruction with a UCExpr.

Specified by:
visit_supdate in interface EDU.purdue.cs.bloat.editor.InstructionVisitor
See Also:
UCExpr

visit_aswizzle

public void visit_aswizzle(EDU.purdue.cs.bloat.editor.Instruction inst)
Add a SCStmt to the statement list

Specified by:
visit_aswizzle in interface EDU.purdue.cs.bloat.editor.InstructionVisitor
See Also:
SCStmt

visit_aswrange

public void visit_aswrange(EDU.purdue.cs.bloat.editor.Instruction inst)
Add a SRStmt to the statement list.

Specified by:
visit_aswrange in interface EDU.purdue.cs.bloat.editor.InstructionVisitor
See Also:
SRStmt

visitForceChildren

public void visitForceChildren(TreeVisitor visitor)
Visit all the statements in the statement list.

Specified by:
visitForceChildren in class Node

visit

public void visit(TreeVisitor visitor)
Specified by:
visit in class Node

parent

public Node parent()
Overrides:
parent in class Node

block

public Block block()
Description copied from class: Node
Returns the basic block in which this Node resides.

Overrides:
block in class Node

SandMark version 2.0

Mon Jun 17 12:30:47 MST 2002